
/* ==========================================================================
   LIVE DESTINATION INTERFACES SHOWCASE (Excel / Sheets, Email, COGS, WMS)
   ========================================================================== */

.live-interfaces-suite {
  margin-top: 3.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 24px;
  box-shadow: 0 20px 50px rgba(28, 43, 45, 0.08);
  overflow: hidden;
  transition: all 0.3s ease;
}

.suite-top-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.2rem 1.6rem;
  background: #fbf5ee;
  border-bottom: 1px solid var(--border);
}

.suite-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.suite-title-wrap .beacon-live {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #0F9D58;
  box-shadow: 0 0 10px #0F9D58;
  animation: beacon-pulse 1.8s infinite;
}

.suite-heading {
  font-family: "Sora", sans-serif;
  font-weight: 800;
  font-size: 1.15rem;
  margin: 0;
  color: var(--ink);
}

.suite-sub {
  font-size: 0.8rem;
  color: var(--ink-soft);
  margin: 0;
}

/* Tab Switcher for Interfaces */
.suite-interface-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  background: #ffffff;
  padding: 0.35rem;
  border-radius: 999px;
  border: 1px solid var(--border);
}

.suite-tab-btn {
  background: transparent;
  border: none;
  border-radius: 999px;
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--ink-soft);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
}

.suite-tab-btn:hover {
  color: var(--ink);
  background: rgba(28, 43, 45, 0.05);
}

.suite-tab-btn.active {
  background: var(--ink);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(28, 43, 45, 0.2);
}

.suite-tab-btn.active.tab-sheets {
  background: #0F9D58;
}

.suite-tab-btn.active.tab-emails {
  background: #EA4335;
}

.suite-tab-btn.active.tab-cogs {
  background: #a24f20;
}

.suite-tab-btn.active.tab-inventory {
  background: #2f8f83;
}

.suite-tab-btn.active.tab-accounting {
  background: #1c2b2d;
}

/* Container for active interface view */
.interface-viewport {
  padding: 1.5rem;
  background: #fdfdfd;
  min-height: 520px;
}

.interface-panel {
  display: none;
  animation: panel-fade-in 0.25s ease-out;
}

.interface-panel.active {
  display: block;
}

@keyframes panel-fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   1. EXCEL / GOOGLE SHEETS LIVE SPREADSHEET INTERFACE
   ========================================================================== */
.sheet-window {
  background: #ffffff;
  border: 1px solid #d3d3d3;
  border-radius: 14px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Green Sheets Header Bar */
.sheet-top-header {
  background: #0F9D58;
  color: #ffffff;
  padding: 0.65rem 1.2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.sheet-title-area {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.sheet-app-icon {
  width: 28px;
  height: 28px;
  background: #ffffff;
  color: #0F9D58;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 1.1rem;
}

.sheet-doc-name {
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: -0.01em;
}

.sheet-sync-pill {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  padding: 0.2rem 0.7rem;
  font-size: 0.72rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.sheet-sync-pill .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ffffff;
  animation: beacon-pulse 1.5s infinite;
}

.sheet-actions-right {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.sheet-streaming-badge {
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(4px);
  color: #ffffff;
  border-radius: 999px;
  padding: 0.35rem 1.05rem;
  font-size: 0.78rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.sheet-streaming-badge .dot,
.sheet-live-badge .dot,
.wms-live-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 0 8px #ffffff;
  animation: beacon-pulse 1.4s infinite;
}

.wms-live-badge {
  background: rgba(47, 143, 131, 0.12);
  color: var(--teal);
  border: 1px solid rgba(47, 143, 131, 0.3);
  border-radius: 999px;
  padding: 0.4rem 1.15rem;
  font-size: 0.8rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.wms-live-badge .dot {
  background: var(--teal);
  box-shadow: 0 0 8px var(--teal);
}

.sheet-live-badge {
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(4px);
  color: #ffffff;
  border-radius: 999px;
  padding: 0.35rem 1.05rem;
  font-size: 0.78rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-sheet-action {
  background: #ffffff;
  color: #0F9D58;
  border: none;
  border-radius: 6px;
  padding: 0.3rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.15s ease;
}

.btn-sheet-action:hover {
  background: #e8f5e9;
  transform: translateY(-1px);
}

/* Sheets Menu Bar */
.sheet-menu-bar {
  background: #f8f9fa;
  border-bottom: 1px solid #e0e0e0;
  padding: 0.35rem 1rem;
  display: flex;
  align-items: center;
  gap: 1.1rem;
  font-size: 0.8rem;
  color: #333333;
}

.sheet-menu-item {
  cursor: pointer;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
}

.sheet-menu-item:hover {
  background: #e9ecef;
}

.sheet-menu-item.active-auto {
  color: #0F9D58;
  font-weight: 700;
  background: rgba(15, 157, 88, 0.1);
}

/* Formula Bar */
.sheet-formula-bar {
  background: #ffffff;
  border-bottom: 1px solid #e0e0e0;
  padding: 0.4rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-size: 0.82rem;
}

.sheet-cell-ref {
  font-weight: 700;
  color: #555555;
  background: #f1f3f4;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  min-width: 36px;
  text-align: center;
}

.sheet-fx-icon {
  font-weight: 800;
  font-style: italic;
  color: #888888;
}

.sheet-formula-input {
  flex: 1;
  border: none;
  background: transparent;
  font-family: monospace;
  font-size: 0.84rem;
  color: #1a73e8;
  font-weight: 600;
  outline: none;
}

/* In-Sheet KPI Summary Cards */
.sheet-kpi-bar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

@media (max-width: 991px) {
  .sheet-kpi-bar {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 575px) {
  .sheet-kpi-bar {
    grid-template-columns: 1fr 1fr;
  }
}

.sheet-kpi-cell {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
}

.sheet-kpi-label {
  font-size: 0.7rem;
  color: #64748b;
  text-transform: uppercase;
  font-weight: 700;
  display: block;
}

.sheet-kpi-val {
  font-size: 1.05rem;
  font-weight: 800;
  color: #0f172a;
}

.sheet-kpi-val.green {
  color: #0F9D58;
}

/* Master Data Grid Table */
.sheet-table-wrap {
  overflow-x: auto;
  max-height: 380px;
  background: #ffffff;
}

.sheet-grid-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  white-space: nowrap;
}

.sheet-grid-table th {
  background: #f1f3f4;
  color: #3c4043;
  padding: 0.5rem 0.75rem;
  border: 1px solid #e0e0e0;
  font-weight: 700;
  text-align: left;
  user-select: none;
}

.sheet-grid-table td {
  padding: 0.5rem 0.75rem;
  border: 1px solid #e8eaed;
  color: #202124;
}

.sheet-grid-table tr:hover td {
  background: #f8f9fa;
}

/* Row insertion laser animation */
.sheet-grid-table tr.row-streaming-in td {
  animation: row-stream-glow 2.4s ease-out;
}

@keyframes row-stream-glow {
  0% { background: #bbf7d0; color: #065f46; font-weight: 700; }
  30% { background: #dcfce7; }
  100% { background: #ffffff; }
}

.channel-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.74rem;
}

.channel-amazon { background: #fff4e5; color: #b45309; }
.channel-shopify { background: #f0fdf4; color: #15803d; }
.channel-ebay { background: #eff6ff; color: #1d4ed8; }
.channel-net32 { background: #ecfeff; color: #0e7490; }
.channel-erp { background: #f5f3ff; color: #6d28d9; }

.val-positive {
  color: #0F9D58;
  font-weight: 700;
}

.val-negative {
  color: #dc2626;
}

.status-badge-synced {
  color: #0F9D58;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

/* Sheet bottom tab bar */
.sheet-bottom-tabs {
  background: #f1f3f4;
  border-top: 1px solid #dadce0;
  padding: 0.35rem 0.8rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  overflow-x: auto;
}

.sheet-tab-chip {
  background: #e8eaed;
  border: 1px solid #dadce0;
  border-radius: 4px 4px 0 0;
  padding: 0.35rem 0.85rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #5f6368;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.sheet-tab-chip:hover {
  background: #ffffff;
  color: #202124;
}

.sheet-tab-chip.active {
  background: #ffffff;
  color: #0F9D58;
  font-weight: 700;
  border-bottom-color: #ffffff;
}

/* ==========================================================================
   2. AUTOMATED EMAIL & ALERT DIGEST INTERFACE
   ========================================================================== */
.email-client-mockup {
  display: grid;
  grid-template-columns: 320px 1fr;
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

@media (max-width: 860px) {
  .email-client-mockup {
    grid-template-columns: 1fr;
  }
}

.email-inbox-pane {
  background: #f8fafc;
  border-right: 1px solid #e2e8f0;
  overflow-y: auto;
  max-height: 480px;
}

.email-inbox-header {
  padding: 0.9rem 1.1rem;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  font-size: 0.88rem;
  color: #1e293b;
}

.email-inbox-count {
  background: #EA4335;
  color: #fff;
  border-radius: 999px;
  padding: 0.15rem 0.5rem;
  font-size: 0.7rem;
}

.email-list-item {
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid #f1f5f9;
  cursor: pointer;
  transition: background 0.15s ease;
}

.email-list-item:hover {
  background: #f1f5f9;
}

.email-list-item.active {
  background: #ffffff;
  border-left: 3px solid #EA4335;
}

.email-item-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.25rem;
  font-size: 0.74rem;
}

.email-item-sender {
  font-weight: 700;
  color: #0f172a;
}

.email-item-time {
  color: #64748b;
}

.email-item-sub {
  font-size: 0.8rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 0.2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.email-item-snippet {
  font-size: 0.74rem;
  color: #64748b;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Email preview pane */
.email-preview-pane {
  padding: 1.5rem 1.8rem;
  overflow-y: auto;
  max-height: 480px;
  background: #ffffff;
}

.email-full-header {
  padding-bottom: 1.1rem;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 1.2rem;
}

.email-full-title {
  font-family: "Sora", sans-serif;
  font-weight: 800;
  font-size: 1.15rem;
  color: #0f172a;
  margin-bottom: 0.5rem;
}

.email-sender-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.email-avatar-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #EA4335;
  color: #ffffff;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.9rem;
}

.email-sender-meta strong {
  display: block;
  font-size: 0.85rem;
  color: #1e293b;
}

.email-sender-meta span {
  font-size: 0.75rem;
  color: #64748b;
}

/* Styled HTML Email Digest Content */
.email-digest-body {
  font-size: 0.86rem;
  line-height: 1.6;
  color: #334155;
}

.digest-metrics-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.8rem;
  margin: 1.2rem 0;
}

@media (max-width: 650px) {
  .digest-metrics-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

.digest-kpi-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.75rem;
  text-align: center;
}

.digest-kpi-box span {
  display: block;
  font-size: 0.7rem;
  color: #64748b;
  text-transform: uppercase;
  font-weight: 700;
}

.digest-kpi-box strong {
  font-size: 1.1rem;
  font-weight: 800;
  color: #0f172a;
}

.digest-kpi-box strong.profit {
  color: #0F9D58;
}

.digest-attachment-card {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-top: 1.2rem;
}

.digest-attachment-icon {
  font-size: 1.5rem;
  color: #EA4335;
}

.digest-attachment-meta strong {
  display: block;
  font-size: 0.82rem;
  color: #0f172a;
}

.digest-attachment-meta span {
  font-size: 0.72rem;
  color: #64748b;
}

/* ==========================================================================
   3. TRUE COGS & PROFITABILITY WATERFALL INTERFACE
   ========================================================================== */
.cogs-waterfall-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.8rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

.cogs-interactive-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 2rem;
  align-items: center;
}

@media (max-width: 860px) {
  .cogs-interactive-grid {
    grid-template-columns: 1fr;
  }
}

.cogs-sliders-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 1.4rem;
}

.cogs-slider-group {
  margin-bottom: 1.1rem;
}

.cogs-slider-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.35rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
}

.cogs-slider-input {
  width: 100%;
  accent-color: #a24f20;
}

/* Waterfall visual bars */
.cogs-bars-box {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.waterfall-bar-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.waterfall-bar-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  font-weight: 600;
}

.waterfall-progress-bg {
  height: 14px;
  border-radius: 999px;
  background: #e2e8f0;
  overflow: hidden;
}

.waterfall-progress-fill {
  height: 100%;
  border-radius: 999px;
  transition: width 0.3s ease;
}

.fill-gross { background: #3b82f6; }
.fill-fee { background: #f59e0b; }
.fill-cogs { background: #ef4444; }
.fill-ads { background: #ec4899; }
.fill-profit { background: #10b981; }

.cogs-final-profit-box {
  margin-top: 1.2rem;
  background: #f0fdf4;
  border: 2px solid #86efac;
  border-radius: 12px;
  padding: 1.1rem 1.4rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cogs-final-profit-box strong {
  font-size: 1.6rem;
  font-family: "Sora", sans-serif;
  color: #15803d;
}

/* ==========================================================================
   4. WMS INVENTORY & 2-WAY MULTI-STORE SYNC INTERFACE
   ========================================================================== */
.wms-matrix-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.5rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

.wms-matrix-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.btn-wms-action {
  background: #2f8f83;
  color: #ffffff;
  border: none;
  border-radius: 999px;
  padding: 0.45rem 1.2rem;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: all 0.2s ease;
}

.btn-wms-action:hover {
  background: #1f6b61;
  transform: translateY(-1px);
}

.stock-meter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stock-bar {
  flex: 1;
  height: 8px;
  background: #e2e8f0;
  border-radius: 999px;
  overflow: hidden;
  min-width: 60px;
}

.stock-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: #2f8f83;
}

.stock-bar-fill.warning {
  background: #f59e0b;
}

.stock-bar-fill.danger {
  background: #ef4444;
}

/* ==========================================================================
   5. QUICKBOOKS & GENERAL LEDGER ACCOUNTING SYNC INTERFACE
   ========================================================================== */
.ledger-sync-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  padding: 1.5rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

.ledger-top-banner {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.9rem 1.2rem;
  margin-bottom: 1.2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.84rem;
}

.ledger-balance-tag {
  color: #0F9D58;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
