/* ==========================================================
   MERI LAST WISH - Brand Design System & Stylesheet
   Theme: Mint Sage Grid & Deep Pine Forest (From Brand Reference)
   ========================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
  /* Brand Palette from Image Reference */
  --bg-primary: #edf6f2;
  --bg-secondary: #e2efe9;
  --bg-surface: #ffffff;
  --bg-card: rgba(255, 255, 255, 0.88);
  --bg-card-hover: rgba(255, 255, 255, 0.98);
  
  --border-color: rgba(33, 84, 73, 0.14);
  --border-focus: rgba(63, 163, 135, 0.5);
  --border-brand: rgba(63, 163, 135, 0.35);

  --text-primary: #15342e;
  --text-secondary: #426760;
  --text-muted: #6f938b;
  --text-brand: #2b7d68;

  /* Primary Brand Accent (Mint / Teal Emerald) */
  --accent-brand: #3fa387;
  --accent-brand-hover: #2f866e;
  --accent-brand-light: #d8efe6;
  --accent-brand-glow: rgba(63, 163, 135, 0.25);

  /* Status Colors */
  --accent-emerald: #10b981;
  --accent-emerald-glow: rgba(16, 185, 129, 0.2);
  --accent-rose: #e11d48;
  --accent-rose-glow: rgba(225, 29, 72, 0.2);
  --accent-amber: #d97706;

  --shadow-subtle: 0 4px 20px -2px rgba(21, 52, 46, 0.06);
  --shadow-elevated: 0 12px 32px -4px rgba(21, 52, 46, 0.12);
  --shadow-brand: 0 0 25px rgba(63, 163, 135, 0.25);
  
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  overflow-x: hidden;
  max-width: 100vw;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  /* Brand Geometric Grid Pattern from Reference */
  background-image: 
    linear-gradient(to right, rgba(63, 163, 135, 0.08) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(63, 163, 135, 0.08) 1px, transparent 1px),
    radial-gradient(circle at 15% 15%, rgba(63, 163, 135, 0.12) 0%, transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(47, 134, 110, 0.1) 0%, transparent 50%);
  background-size: 32px 32px, 32px 32px, 100% 100%, 100% 100%;
  background-attachment: fixed;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Outfit', sans-serif;
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.25;
}

a {
  color: var(--accent-brand-hover);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--accent-brand);
}

/* Container */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-sm {
  max-width: 580px;
}

.container-md {
  max-width: 900px;
}

/* Navigation Bar */
.navbar {
  background: rgba(237, 246, 242, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 16px 0;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Outfit', sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.5px;
}

.logo-icon {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--accent-brand), #216152);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(63, 163, 135, 0.35);
  color: #fff;
  font-size: 1.2rem;
}

.logo-highlight {
  color: var(--accent-brand);
  position: relative;
  display: inline-block;
}

.logo-highlight::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 100%;
  height: 3px;
  background: var(--accent-brand);
  border-radius: 2px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  list-style: none;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 22px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 110;
}

.nav-toggle span {
  display: block;
  height: 3px;
  width: 100%;
  background: var(--text-primary);
  border-radius: 3px;
  transition: all 0.3s ease;
}

.nav-toggle.active span:nth-child(1) {
  transform: translateY(9.5px) rotate(45deg);
}

.nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
  transform: translateY(-9.5px) rotate(-45deg);
}

.dashboard-wallet-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 24px;
  margin-bottom: 30px;
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 8px 14px;
  border-radius: 9999px;
  transition: var(--transition);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
  background: var(--accent-brand-light);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 9999px;
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-brand), #276e5d);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(63, 163, 135, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #4ab798, #2e7e6a);
  box-shadow: 0 6px 20px rgba(63, 163, 135, 0.45);
  transform: translateY(-1px);
  color: #ffffff;
}

.btn-secondary {
  background: #ffffff;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  box-shadow: 0 2px 6px rgba(21, 52, 46, 0.04);
}

.btn-secondary:hover {
  background: var(--accent-brand-light);
  border-color: var(--border-brand);
  color: var(--text-primary);
}

.btn-danger {
  background: linear-gradient(135deg, var(--accent-rose), #9f1239);
  color: #fff;
  box-shadow: 0 4px 14px var(--accent-rose-glow);
}

.btn-danger:hover {
  background: linear-gradient(135deg, #f43f5e, #be123c);
  transform: translateY(-1px);
}

.btn-emerald {
  background: linear-gradient(135deg, var(--accent-brand), #1b5346);
  color: #fff;
  box-shadow: 0 4px 14px var(--accent-brand-glow);
}

.btn-emerald:hover {
  background: linear-gradient(135deg, #4bb999, #266b5b);
  transform: translateY(-1px);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1.05rem;
}

.btn-sm {
  padding: 6px 16px;
  font-size: 0.85rem;
}

.btn-block {
  width: 100%;
}

/* Hero Section */
.hero {
  padding: 80px 0 60px;
  text-align: center;
  position: relative;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 18px;
  background: var(--accent-brand-light);
  border: 1px solid var(--border-brand);
  border-radius: 9999px;
  color: var(--text-brand);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  margin-bottom: 24px;
}

.hero-title {
  font-size: 3.5rem;
  letter-spacing: -1.5px;
  margin-bottom: 20px;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  color: var(--text-primary);
}

.hero-title span {
  color: var(--accent-brand);
  position: relative;
  display: inline-block;
}

.hero-title span::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 6px;
  width: 100%;
  height: 6px;
  background: var(--accent-brand);
  border-radius: 3px;
  opacity: 0.85;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 650px;
  margin: 0 auto 36px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 50px;
  flex-wrap: wrap;
}

/* Cards & Glassmorphism */
.glass-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 30px;
  box-shadow: var(--shadow-subtle);
  transition: var(--transition);
}

.glass-card-interactive:hover {
  border-color: var(--border-brand);
  transform: translateY(-3px);
  box-shadow: var(--shadow-elevated);
  background: var(--bg-card-hover);
}

/* Feature Grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin: 40px 0;
}

.feature-icon {
  width: 52px;
  height: 52px;
  background: var(--accent-brand-light);
  border: 1px solid var(--border-brand);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--text-brand);
  margin-bottom: 20px;
}

/* Step Workflow */
.step-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin: 50px 0;
}

.step-card {
  position: relative;
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 34px 26px;
  text-align: left;
  box-shadow: var(--shadow-subtle);
}

.step-number {
  position: absolute;
  top: -15px;
  left: 24px;
  width: 32px;
  height: 32px;
  background: var(--accent-brand);
  color: #ffffff;
  font-weight: 800;
  font-size: 0.95rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(63, 163, 135, 0.4);
}

/* Dashboard UI */
.dashboard-header {
  padding: 32px 0 20px;
}

.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.stat-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 22px;
  display: flex;
  align-items: center;
  gap: 18px;
  box-shadow: var(--shadow-subtle);
}

.stat-icon-wrapper {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
}

.stat-gold, .stat-brand {
  background: var(--accent-brand-light);
  color: var(--text-brand);
  border: 1px solid var(--border-brand);
}

.stat-emerald {
  background: #e6f9f3;
  color: #0d9488;
  border: 1px solid rgba(13, 148, 136, 0.25);
}

.stat-indigo {
  background: #eef2ff;
  color: #4f46e5;
  border: 1px solid rgba(79, 70, 229, 0.25);
}

.stat-value {
  font-size: 1.6rem;
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  color: var(--text-primary);
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* Tab Navigation */
.tabs-nav {
  display: flex;
  gap: 12px;
  border-bottom: 2px solid var(--border-color);
  margin-bottom: 30px;
  padding-bottom: 2px;
}

.tab-btn {
  background: transparent;
  border: none;
  padding: 12px 24px;
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  border-bottom: 3px solid transparent;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition);
}

.tab-btn:hover {
  color: var(--text-primary);
}

.tab-btn.active {
  color: var(--accent-brand-hover);
  border-bottom-color: var(--accent-brand);
}

.tab-content {
  display: none;
  animation: fadeIn 0.3s ease-in-out;
}

.tab-content.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================
   THE WHITE CANVAS (Strict One-Time Editor)
   ========================================================== */
.canvas-wrapper {
  background: #ffffff;
  color: #1e293b;
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-elevated);
  border: 3px solid var(--accent-brand-light);
  position: relative;
}

.canvas-header {
  border-bottom: 2px dashed #d1e7dd;
  padding-bottom: 20px;
  margin-bottom: 30px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.canvas-title {
  color: #15342e;
  font-size: 1.8rem;
}

.canvas-subtitle {
  color: #557972;
  font-size: 0.95rem;
}

.canvas-counter {
  background: var(--accent-brand-light);
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-brand);
}

.canvas-textarea {
  width: 100%;
  min-height: 280px;
  border: 1.5px solid #cce3db;
  border-radius: var(--radius-md);
  padding: 20px;
  font-family: 'Inter', Georgia, serif;
  font-size: 1.1rem;
  line-height: 1.8;
  color: #15342e;
  background: #f7fbf9;
  resize: vertical;
  outline: none;
  transition: var(--transition);
}

.canvas-textarea:focus {
  background: #ffffff;
  border-color: var(--accent-brand);
  box-shadow: 0 0 0 4px var(--accent-brand-glow);
}

.canvas-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 24px;
}

.canvas-label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.canvas-input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #cce3db;
  border-radius: var(--radius-sm);
  background: #f7fbf9;
  font-size: 0.95rem;
  color: #15342e;
  outline: none;
}

.canvas-input:focus {
  background: #fff;
  border-color: var(--accent-brand);
  box-shadow: 0 0 0 3px var(--accent-brand-glow);
}

.canvas-footer {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid #d1e7dd;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.canvas-warning {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #9f1239;
  font-size: 0.85rem;
  font-weight: 600;
  background: #ffe4e6;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
}

/* Vaulted / Locked Card */
.vault-locked-card {
  text-align: center;
  padding: 60px 30px;
  background: #ffffff;
  border: 2px solid var(--border-brand);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-elevated);
}

.vault-lock-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 24px;
  background: var(--accent-brand-light);
  border: 2px solid var(--accent-brand);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  color: var(--text-brand);
  box-shadow: 0 0 30px rgba(63, 163, 135, 0.3);
  animation: pulse 2.5s infinite;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(63, 163, 135, 0.4); }
  70% { box-shadow: 0 0 0 15px rgba(63, 163, 135, 0); }
  100% { box-shadow: 0 0 0 0 rgba(63, 163, 135, 0); }
}

/* Forms & Inputs */
.form-group {
  margin-bottom: 20px;
  text-align: left;
}

.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  background: #ffffff;
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}

.form-control:focus {
  border-color: var(--accent-brand);
  box-shadow: 0 0 0 3px var(--accent-brand-glow);
}

/* Referral Box */
.referral-box {
  background: #ffffff;
  border: 1.5px dashed var(--accent-brand);
  border-radius: var(--radius-md);
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 20px 0;
}

.referral-link-display {
  font-family: monospace;
  font-size: 0.95rem;
  color: var(--text-brand);
  font-weight: 700;
  word-break: break-all;
}

/* Tables */
.table-responsive {
  width: 100%;
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: #ffffff;
}

.custom-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.custom-table th {
  background: #f1f8f5;
  color: var(--text-secondary);
  font-weight: 700;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.5px;
}

.custom-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
}

.custom-table tbody tr:hover {
  background: rgba(63, 163, 135, 0.04);
}

/* Status Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-paid, .badge-credit, .badge-active {
  background: var(--accent-brand-light);
  color: var(--text-brand);
  border: 1px solid var(--border-brand);
}

.badge-pending, .badge-warning {
  background: #fef3c7;
  color: #b45309;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-debit, .badge-rejected, .badge-danger {
  background: #ffe4e6;
  color: #e11d48;
  border: 1px solid rgba(225, 29, 72, 0.3);
}

.badge-locked {
  background: #e0e7ff;
  color: #4338ca;
  border: 1px solid rgba(99, 102, 241, 0.3);
}

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(21, 52, 46, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

.modal-overlay.active {
  display: flex;
}

.modal-box {
  background: #ffffff;
  border: 1px solid var(--border-brand);
  border-radius: var(--radius-lg);
  padding: 30px;
  max-width: 520px;
  width: 100%;
  box-shadow: var(--shadow-elevated);
  position: relative;
}

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

.modal-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
}

.modal-close:hover {
  color: var(--text-primary);
}

/* Toast Notifications */
#toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.toast {
  background: #ffffff;
  color: var(--text-primary);
  border: 1px solid var(--border-brand);
  border-radius: var(--radius-md);
  padding: 14px 20px;
  box-shadow: var(--shadow-elevated);
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
  animation: slideIn 0.3s ease;
}

.toast-success { border-left: 5px solid var(--accent-brand); }
.toast-error { border-left: 5px solid var(--accent-rose); }
.toast-info { border-left: 5px solid var(--text-brand); }

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Footer */
.footer {
  margin-top: auto;
  border-top: 1px solid var(--border-color);
  padding: 40px 0 20px;
  background: #e2efe9;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  margin-top: 30px;
  padding-top: 20px;
  text-align: center;
  font-size: 0.85rem;
}

/* ==========================================================
   MOBILE & TABLET RESPONSIVE RULES (Comprehensive Touch Support)
   ========================================================== */

/* Tablets & Mobile Devices (<= 992px) */
@media (max-width: 992px) {
  .dashboard-wallet-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* Containers & Spacing */
  .container {
    padding-left: 16px;
    padding-right: 16px;
  }

  /* Mobile Navbar */
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #edf6f2;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 2px solid var(--border-brand);
    box-shadow: 0 16px 30px rgba(21, 52, 46, 0.15);
    flex-direction: column;
    align-items: stretch;
    padding: 20px 20px 24px;
    gap: 12px;
    z-index: 100;
  }

  .nav-links.open {
    display: flex;
    animation: fadeIn 0.25s ease-in-out;
  }

  .nav-link {
    display: block;
    padding: 12px 18px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    background: #ffffff;
    border: 1px solid var(--border-brand);
  }

  /* Landing Hero */
  .hero {
    padding: 50px 0 40px;
  }

  .hero-title {
    font-size: 2.1rem;
    line-height: 1.25;
  }

  .hero-subtitle {
    font-size: 1rem;
    margin-bottom: 26px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  .hero-actions .btn {
    width: 100%;
    text-align: center;
  }

  /* Dashboard Header & Controls */
  .dashboard-header > div:first-child {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 16px;
  }

  .dashboard-header > div:first-child > div:last-child {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .dashboard-header > div:first-child > div:last-child .btn {
    width: 100%;
    justify-content: center;
  }

  /* Stats Grid */
  .dashboard-stats {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .stat-card {
    padding: 18px 16px;
  }

  /* Tabs Switcher */
  .tabs-nav {
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    border-bottom: 2px solid var(--border-brand);
    gap: 8px;
  }

  .tabs-nav::-webkit-scrollbar {
    display: none;
  }

  .tab-btn {
    padding: 12px 16px;
    font-size: 0.95rem;
    flex-shrink: 0;
  }

  /* The Canvas Editor on Mobile */
  .canvas-wrapper {
    padding: 22px 16px;
    border-radius: var(--radius-md);
  }

  .canvas-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 20px;
  }

  .canvas-title {
    font-size: 1.5rem;
  }

  .canvas-textarea {
    font-size: 1rem;
    padding: 16px;
    min-height: 220px;
  }

  .canvas-form-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .canvas-footer {
    flex-direction: column;
    gap: 16px;
    align-items: stretch;
  }

  .canvas-footer .btn {
    width: 100%;
  }

  /* Referral Card */
  .referral-box {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .referral-link-display {
    font-size: 0.85rem;
    padding: 12px 14px;
    word-break: break-all;
    white-space: normal;
  }

  .referral-box .btn {
    width: 100%;
  }

  /* Cards & Forms */
  .glass-card {
    padding: 24px 18px;
    border-radius: var(--radius-md);
  }

  /* Modals */
  .modal-box {
    width: 95%;
    padding: 24px 18px;
    max-height: 90vh;
    overflow-y: auto;
  }

  /* Tables */
  .table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-sm);
  }

  .custom-table th,
  .custom-table td {
    padding: 10px 12px;
    font-size: 0.85rem;
    white-space: nowrap;
  }
}

/* Small Phones (<= 480px) */
@media (max-width: 480px) {
  .hero-title {
    font-size: 1.85rem;
  }

  .glass-card {
    padding: 20px 14px;
  }

  .btn {
    padding: 12px 18px;
    font-size: 0.9rem;
  }

  .canvas-wrapper {
    padding: 18px 12px;
  }
}
