/* ============================================================================
   RETURNIA MERCHANT ADMIN DASHBOARD — STYLESHEET
   ============================================================================ */

:root {
  --primary: #10b981;
  --primary-dark: #059669;
  --primary-light: #d1fae5;
  --primary-subtle: #ecfdf5;

  --sidebar-bg: #0f172a;
  --sidebar-text: #94a3b8;
  --sidebar-hover: #1e293b;
  --sidebar-active: #10b981;

  --bg-main: #f8fafc;
  --bg-surface: #ffffff;
  --border-light: #e2e8f0;
  --border-medium: #cbd5e1;

  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-dim: #94a3b8;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.06);
  --shadow-lg: 0 12px 28px rgba(0,0,0,0.08);

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Bricolage Grotesque', 'Inter', sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
}

/* ============================================================================
   APP SHELL LAYOUT
   ============================================================================ */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  width: 270px;
  background-color: var(--sidebar-bg);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; bottom: 0; left: 0;
  z-index: 50;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.25s ease;
}

.sidebar-header {
  padding: 24px 20px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.brand-icon {
  width: 38px;
  height: 38px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.35);
}

.brand-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.5px;
  line-height: 1.1;
}

.brand-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Merchant Switcher */
.merchant-switch-wrap {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.switch-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.merchant-select-dropdown {
  width: 100%;
  background-color: var(--sidebar-hover);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-sm);
  color: #ffffff;
  padding: 8px 12px;
  font-size: 0.85rem;
  font-weight: 600;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.merchant-select-dropdown:focus {
  border-color: var(--primary);
}

/* Sidebar Nav */
.sidebar-nav {
  padding: 16px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  overflow-y: auto;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  color: var(--sidebar-text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  transition: all 0.2s ease;
}

.nav-item:hover {
  background-color: var(--sidebar-hover);
  color: #ffffff;
}

.nav-item.active {
  background-color: rgba(16, 185, 129, 0.15);
  color: var(--primary);
}

.nav-icon {
  font-size: 1.15rem;
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 16px 14px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-shortcuts-label {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
  padding-left: 4px;
}

.shortcut-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 600;
  transition: all 0.2s ease;
}

.shortcut-scanner {
  background-color: rgba(16, 185, 129, 0.15);
  color: #34d399;
}
.shortcut-scanner:hover {
  background-color: rgba(16, 185, 129, 0.25);
}

.shortcut-onboard {
  background-color: rgba(255, 255, 255, 0.06);
  color: #cbd5e1;
}
.shortcut-onboard:hover {
  background-color: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.shortcut-arrow {
  opacity: 0.7;
}

/* ============================================================================
   MAIN CONTENT
   ============================================================================ */
.main-content {
  margin-left: 270px;
  flex: 1;
  padding: 24px 32px 60px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

/* Topbar */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-light);
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.mobile-toggle-btn {
  display: none;
  background: none;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  font-size: 1.2rem;
  cursor: pointer;
}

.page-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.5px;
}

.page-subtitle {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.status-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  background-color: var(--primary-subtle);
  border: 1px solid var(--primary-light);
  color: var(--primary-dark);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
}

.status-dot {
  width: 7px;
  height: 7px;
  background-color: var(--primary);
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.8); opacity: 0.5; }
}

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background-color: #0f172a;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: all 0.25s ease;
}

.toast.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

/* View Navigation Switching */
.content-view {
  display: none;
}
.content-view.active {
  display: block;
}

/* ============================================================================
   BUTTONS & FORM CONTROLS
   ============================================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 10px 18px;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.btn-secondary {
  background-color: var(--bg-surface);
  border: 1.5px solid var(--border-light);
  color: var(--text-main);
}
.btn-secondary:hover {
  border-color: var(--border-medium);
  background-color: var(--bg-main);
}

.btn-sm {
  padding: 7px 12px;
  font-size: 0.82rem;
}

.btn-lg {
  padding: 14px 24px;
  font-size: 1rem;
}

.w-full {
  width: 100%;
}

/* Cards */
.card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.card-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
}

.card-sub {
  font-size: 0.83rem;
  color: var(--text-muted);
}

/* ============================================================================
   VIEW 1: DASHBOARD OVERVIEW
   ============================================================================ */
.welcome-card {
  background: linear-gradient(135deg, #064e3b, #047857);
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  box-shadow: 0 8px 24px rgba(6, 78, 59, 0.25);
}

.welcome-text h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.welcome-text p {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  max-width: 580px;
}

/* KPI Cards */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 24px;
}

.kpi-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.kpi-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.kpi-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.kpi-icon-wrap {
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.bg-emerald { background-color: var(--primary-subtle); color: var(--primary-dark); }
.bg-blue { background-color: #eff6ff; color: #2563eb; }
.bg-amber { background-color: #fffbeb; color: #d97706; }
.bg-purple { background-color: #faf5ff; color: #9333ea; }

.text-emerald { color: #059669; }
.text-amber { color: #d97706; }
.text-purple { color: #9333ea; }

.kpi-value {
  font-family: var(--font-display);
  font-size: 2.1rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1;
  margin-bottom: 8px;
}

.kpi-footer {
  font-size: 0.77rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
}

.kpi-period {
  color: var(--text-dim);
  font-weight: 500;
}

/* Dashboard Grid: Chart + Live Feed */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 24px;
}

/* Chart */
.chart-container {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  height: 200px;
  padding-top: 20px;
  border-bottom: 1px solid var(--border-light);
}

.chart-bar-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
  justify-content: flex-end;
}

.chart-bar {
  width: 100%;
  max-width: 42px;
  background: linear-gradient(180deg, var(--primary), var(--primary-dark));
  border-radius: 6px 6px 0 0;
  transition: height 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  min-height: 6px;
  position: relative;
}

.chart-bar:hover::after {
  content: attr(data-count);
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #0f172a;
  color: #fff;
  font-size: 0.7rem;
  padding: 2px 6px;
  border-radius: 4px;
  white-space: nowrap;
}

.chart-day-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-top: 8px;
}

/* Live Feed */
.activity-feed {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.feed-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  background-color: var(--bg-main);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
}

.feed-customer {
  display: flex;
  align-items: center;
  gap: 10px;
}

.avatar-sm {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
}

.feed-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-main);
}

.feed-time {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.feed-badge {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary-dark);
  background-color: var(--primary-light);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}

/* ============================================================================
   VIEW 2 & 3: TABLES (CUSTOMERS & TRANSACTIONS)
   ============================================================================ */
.table-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.search-icon {
  position: absolute;
  left: 12px;
  font-size: 0.85rem;
  pointer-events: none;
}

.search-box input {
  padding: 8px 12px 8px 34px;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  font-family: var(--font-sans);
  outline: none;
  width: 240px;
  transition: all 0.2s ease;
}

.search-box input:focus {
  border-color: var(--primary);
  width: 280px;
}

.table-responsive {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.data-table th {
  padding: 12px 16px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-light);
  background-color: var(--bg-main);
}

.data-table td {
  padding: 14px 16px;
  font-size: 0.88rem;
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}

.data-table tbody tr:hover {
  background-color: rgba(248, 250, 252, 0.8);
}

.cust-cell {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cust-name {
  font-weight: 700;
  color: var(--text-main);
}

.cust-email {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
}

.badge-emerald { background-color: var(--primary-subtle); color: var(--primary-dark); }
.badge-amber { background-color: #fffbeb; color: #b45309; }
.badge-gray { background-color: #f1f5f9; color: #475569; }

/* ============================================================================
   VIEW 4: PROGRAM SETTINGS & LIVE CARD DESIGNER
   ============================================================================ */
.designer-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 24px;
  align-items: start;
}

.settings-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.83rem;
  font-weight: 700;
  color: var(--text-main);
}

.form-control {
  padding: 11px 14px;
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  font-family: var(--font-sans);
  outline: none;
  transition: border-color 0.2s ease;
}

.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12);
}

.form-help {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

/* Radio Mode Selectors */
.mode-selector-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.mode-card-radio {
  cursor: pointer;
  position: relative;
}

.mode-card-radio input {
  position: absolute;
  top: 14px;
  right: 14px;
  accent-color: var(--primary);
}

.mode-card-content {
  border: 2px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 16px;
  background-color: var(--bg-main);
  transition: all 0.2s ease;
  height: 100%;
}

.mode-card-radio input:checked + .mode-card-content {
  border-color: var(--primary);
  background-color: var(--primary-subtle);
}

.mode-emoji {
  font-size: 1.6rem;
  margin-bottom: 6px;
}

.mode-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.mode-desc {
  font-size: 0.77rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Color pickers */
.colors-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 8px;
}

.color-picker-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.color-input-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-main);
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 6px 12px;
}

.color-input-wrapper input[type="color"] {
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  background: none;
}

.hex-label {
  font-size: 0.85rem;
  font-weight: 700;
  font-family: monospace;
}

.color-presets {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.preset-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.preset-pill {
  border: none;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.15s ease;
}

.preset-pill:hover {
  transform: scale(1.05);
}

/* Phone Simulator */
.preview-card {
  position: sticky;
  top: 24px;
}

.phone-simulator {
  display: flex;
  justify-content: center;
  padding: 10px 0;
}

.phone-frame {
  width: 300px;
  background-color: #1e293b;
  border-radius: 36px;
  padding: 16px 12px 20px;
  box-shadow: 0 20px 40px rgba(0,0,0,0.25);
}

.phone-header-notch {
  width: 80px;
  height: 16px;
  background-color: #0f172a;
  border-radius: 10px;
  margin: 0 auto 14px;
}

/* Simulated Pass Card */
.sim-pass {
  background-color: #064e3b;
  color: #ffffff;
  border-radius: 18px;
  padding: 16px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.sim-pass-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.sim-logo-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.sim-logo-badge {
  width: 26px;
  height: 26px;
  background-color: var(--primary);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.8rem;
  color: #fff;
}

.sim-biz-name {
  font-size: 0.82rem;
  font-weight: 800;
}

.sim-pass-type {
  font-size: 0.55rem;
  opacity: 0.7;
  letter-spacing: 0.5px;
}

.sim-wallet-pill {
  font-size: 0.65rem;
  opacity: 0.75;
  font-weight: 600;
}

.sim-stamps-box {
  margin-bottom: 14px;
}

.sim-stamps-grid {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.sim-stamp {
  font-size: 1.25rem;
  opacity: 0.35;
  transition: all 0.2s ease;
}

.sim-stamp.filled {
  opacity: 1;
}

.sim-stamps-status {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
}

.sim-label {
  font-size: 0.58rem;
  opacity: 0.65;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.sim-value {
  font-weight: 700;
}

/* Points Simulation Box */
.sim-points-box {
  text-align: center;
  margin-bottom: 14px;
}

.sim-points-val {
  font-size: 2.2rem;
  font-weight: 900;
  line-height: 1;
}

.sim-points-lbl {
  font-size: 0.65rem;
  opacity: 0.7;
  margin-bottom: 6px;
}

.sim-points-bar-bg {
  height: 6px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 4px;
}

.sim-points-bar-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 3px;
}

.sim-points-help {
  font-size: 0.65rem;
  opacity: 0.75;
}

.sim-pass-member {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  margin-bottom: 12px;
}

.sim-member-name {
  font-weight: 700;
}

.sim-qr-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 4px;
}

.sim-qr-box {
  background: #fff;
  padding: 6px;
  border-radius: 8px;
  display: inline-flex;
}

.sim-qr-box img {
  width: 75px;
  height: 75px;
}

.sim-qr-serial {
  font-size: 0.6rem;
  opacity: 0.6;
  font-family: monospace;
  margin-top: 4px;
}

.sim-hint {
  text-align: center;
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-top: 14px;
}

/* ============================================================================
   VIEW 5: MARKETING KIT (POSTER & PRINT READY)
   ============================================================================ */
.marketing-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 28px;
  align-items: start;
}

.marketing-instructions {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 24px;
}

.instruction-step {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.step-badge {
  width: 28px;
  height: 28px;
  background-color: var(--primary-subtle);
  color: var(--primary-dark);
  font-weight: 800;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.instruction-step h4 {
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 2px;
}

.instruction-step p {
  font-size: 0.83rem;
  color: var(--text-muted);
}

.marketing-links-box {
  margin-top: 16px;
  background-color: var(--bg-main);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 14px;
}

.marketing-links-box label {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.copy-link-wrap {
  display: flex;
  gap: 8px;
}

.copy-link-wrap input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--border-medium);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  background: #fff;
}

/* Poster Preview Card */
.poster-preview-wrapper {
  background: #fff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: var(--shadow-md);
  display: flex;
  justify-content: center;
}

.printable-poster {
  width: 100%;
  max-width: 380px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 2px solid var(--border-light);
  border-radius: 24px;
  padding: 36px 28px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.poster-header {
  margin-bottom: 20px;
}

.poster-brand-logo {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.5rem;
  margin: 0 auto 12px;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.35);
}

.poster-biz-name {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.1;
  margin-bottom: 4px;
}

.poster-tagline {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.poster-incentive {
  background: var(--primary-subtle);
  border: 1.5px dashed var(--primary);
  color: var(--primary-dark);
  font-size: 0.95rem;
  font-weight: 800;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  margin-bottom: 24px;
}

.poster-qr-container {
  margin-bottom: 24px;
}

.poster-qr-box {
  background: #ffffff;
  border: 2px solid var(--border-light);
  border-radius: 20px;
  padding: 16px;
  width: 200px;
  height: 200px;
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
}

.poster-qr-box img {
  width: 100%;
  height: 100%;
}

.poster-scan-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-main);
}

.poster-steps-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 24px;
  padding: 12px 0;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
}

.pstep {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.pstep-num {
  width: 22px;
  height: 22px;
  background-color: var(--text-main);
  color: #fff;
  border-radius: 50%;
  font-size: 0.72rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pstep-txt {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-muted);
}

.poster-wallets {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.pw-badge {
  background: #f1f5f9;
  padding: 3px 8px;
  border-radius: 6px;
  font-weight: 700;
  color: var(--text-main);
}

.poster-footer {
  font-size: 0.7rem;
  color: var(--text-dim);
}

/* ============================================================================
   RESPONSIVE DESIGN (TABLETS & MOBILE)
   ============================================================================ */
@media (max-width: 1024px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .designer-grid {
    grid-template-columns: 1fr;
  }
  .preview-card {
    position: static;
  }
  .marketing-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .main-content {
    margin-left: 0;
    padding: 16px;
  }
  .mobile-toggle-btn {
    display: block;
  }
  .welcome-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
  .kpi-grid {
    grid-template-columns: 1fr;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
  .mode-selector-grid {
    grid-template-columns: 1fr;
  }
  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
/* ============================================================================
   VIEW 6: CAMPAÑAS & MENSAJERÍA (BREVO, VACACIONES, HORARIOS)
   ============================================================================ */
.vacation-banner-box {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  border: 1.5px solid #a7f3d0;
  border-radius: var(--radius-xl);
  padding: 20px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  transition: all 0.3s ease;
}

.vacation-banner-box.vacation-active {
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
  border-color: #f59e0b;
}

.v-banner-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.v-banner-icon {
  font-size: 2.2rem;
}

.v-banner-left h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 2px;
}

.v-banner-left p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.v-banner-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Toggle Switch (iOS-like) */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
  flex-shrink: 0;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: #cbd5e1;
  transition: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius: 34px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.toggle-switch input:checked + .toggle-slider {
  background-color: var(--primary);
}

.toggle-switch input:checked + .toggle-slider:before {
  transform: translateX(22px);
}

.toggle-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
}

/* Campaigns Grid */
.campaigns-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: start;
}

.automation-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background-color: var(--bg-main);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
}

.auto-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.auto-info strong {
  font-size: 0.88rem;
  color: var(--text-main);
}

.auto-info span {
  font-size: 0.77rem;
  color: var(--text-muted);
}

.test-send-row {
  display: flex;
  gap: 8px;
  margin-top: 4px;
  margin-bottom: 4px;
}

@media (max-width: 1024px) {
  .campaigns-grid {
    grid-template-columns: 1fr;
  }
  .vacation-banner-box {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}

/* ============================================================================
   PRINT STYLES FOR THE POSTER (A4 / A5 PRINTING)
   ============================================================================ */
@media print {
  body {
    background: #ffffff !important;
  }
  .sidebar, .topbar, .no-print, .btn, .sidebar-footer, .welcome-card, .toast {
    display: none !important;
  }
  .main-content {
    margin-left: 0 !important;
    padding: 0 !important;
  }
  .content-view {
    display: none !important;
  }
  #view-marketing {
    display: block !important;
  }
  .poster-preview-wrapper {
    box-shadow: none !important;
    border: none !important;
    padding: 0 !important;
  }
  .printable-poster {
    max-width: 100% !important;
    width: 100% !important;
    box-shadow: none !important;
    border: 2px solid #000000 !important;
    page-break-inside: avoid;
    margin: 0 auto;
    padding: 40px;
  }
}
