:root { 
  --fg: #1d1d1f; 
  --bg: #f5f5f7; 
  --muted: #86868b; 
  --primary: #F47600; 
  --danger: #ff3b30; 
  --success: #34c759;
  --surface: #ffffff;
  --border: #788084;
  --shadow: rgba(0, 0, 0, 0.1);
  /* Smooth transitions for CSS variables */
  transition: background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), 
              color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark theme variables - apply to html element when it has data-theme="dark" */
html[data-theme="dark"],
[data-theme="dark"] {
  --fg: #f5f5f7;
  --bg: #1d1d1f;
  --muted: #86868b;
  --primary: #F47600;
  --danger: #ff453a;
  --success: #30d158;
  --surface: #2c2c2e;
  --border: #788084;
  --shadow: rgba(0, 0, 0, 0.3);
}

/* Ensure body background changes in dark theme - instant change */
html[data-theme="dark"] body {
  background-color: var(--bg);
  color: var(--fg);
}

/* Form input text color for dark theme */
[data-theme="dark"] input[type="text"],
[data-theme="dark"] input[type="email"],
[data-theme="dark"] input[type="password"],
[data-theme="dark"] input[type="number"],
[data-theme="dark"] input[type="date"],
[data-theme="dark"] input[type="tel"],
[data-theme="dark"] input[type="url"],
[data-theme="dark"] textarea,
[data-theme="dark"] select {
  color: #ffffff !important;
}

/* Form input text color for light theme */
[data-theme="light"] input[type="text"],
[data-theme="light"] input[type="email"],
[data-theme="light"] input[type="password"],
[data-theme="light"] input[type="number"],
[data-theme="light"] input[type="date"],
[data-theme="light"] input[type="tel"],
[data-theme="light"] input[type="url"],
[data-theme="light"] textarea,
[data-theme="light"] select {
  color: #000000 !important;
}

/* Placeholder text styling for dark theme */
[data-theme="dark"] input::placeholder,
[data-theme="dark"] textarea::placeholder {
  color: #8e8e93 !important;
  opacity: 1;
}

/* Placeholder text styling for light theme */
[data-theme="light"] input::placeholder,
[data-theme="light"] textarea::placeholder {
  color: #8e8e93 !important;
  opacity: 1;
}

*, *::before, *::after { 
  box-sizing: border-box; 
  margin: 0;
  padding: 0;
}

html {
  overflow-x: hidden !important;
  max-width: 100vw !important;
}

body { 
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif; 
  color: var(--fg); 
  background-color: var(--bg); 
  line-height: 1.5;
  font-size: 17px;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden !important;
  max-width: 100vw !important;
  width: 100%;
  /* Performance optimizations */
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* NO transitions - instant theme changes */
}


.container { 
  width: 100%; 
  max-width: 1200px; 
  margin: 0 auto; 
  padding: 20px;
  overflow-x: hidden !important;
}

main.container {
  flex: 1;
  padding-top: 80px; /* Fixed navbar height is 60px + 20px buffer */
  padding-bottom: 0;
  overflow-x: hidden !important;
  max-width: 100vw !important;
  width: 100%;
  min-height: calc(100vh - 72px);
}

.navbar { 
  background: rgba(245, 245, 247, 0.15) !important;
  border-bottom: none;
  backdrop-filter: blur(40px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(40px) saturate(180%) !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 1000 !important;
  min-height: 72px !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  width: 100% !important;
  border-top-left-radius: 20px !important;
  border-top-right-radius: 20px !important;
  border-bottom-left-radius: 20px !important;
  border-bottom-right-radius: 20px !important;
}

[data-theme="dark"] .navbar {
  background: rgba(29, 29, 31, 0.15);
  border-bottom: none;
  box-shadow: none;
}

.navbar .container { 
  display: flex; 
  align-items: center; 
  justify-content: space-between; 
  padding: 16px 20px;
  min-height: 72px;
  margin: 0;
  max-width: none;
}

.brand { 
  font-weight: 600; 
  font-size: 20px;
  color: var(--fg);
  display: flex;
  align-items: center;
  gap: 8px;
  transition: opacity 0.2s ease;
  text-decoration: none;
}

.brand:hover {
  opacity: 0.8;
}

.brand img {
  height: 32px;
  width: auto;
  display: block;
  flex-shrink: 0;
}

nav a { 
  margin-left: 24px; 
  text-decoration: none; 
  color: var(--fg);
  font-weight: 500;
  transition: color 0.2s ease;
}

nav a:hover {
  color: var(--primary);
}

/* Nav group styling for better alignment */
nav {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  position: relative !important;
  flex-shrink: 0 !important;
  contain: layout style paint !important;
  width: auto !important;
  min-width: 0 !important;
}

.nav-group {
  display: flex;
  align-items: center;
  gap: 0;
}

.nav-group a {
  margin-left: 24px;
}

.nav-group a:first-child {
  margin-left: 0;
}

nav .theme-toggle.ios-toggle {
  width: auto !important;
  min-width: 91px !important;
  height: 31px !important;
  border-radius: 0 !important;
  border: none !important;
  background: transparent !important;
  cursor: pointer !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  padding: 0 !important;
  margin: 0 !important;
  margin-right: 16px !important;
  margin-left: 0 !important;
  align-self: center !important;
  pointer-events: auto !important;
  z-index: 10 !important;
  -webkit-tap-highlight-color: transparent !important;
  touch-action: manipulation !important;
  position: relative !important;
  overflow: visible !important;
  -webkit-user-select: none !important;
  user-select: none !important;
  flex-shrink: 0 !important;
  contain: layout style paint !important;
  will-change: auto !important;
  transition: none !important;
  transform: none !important;
}

.toggle-track {
  width: 51px !important;
  height: 31px !important;
  min-width: 51px !important;
  min-height: 31px !important;
  max-width: 51px !important;
  max-height: 31px !important;
  border-radius: 15.5px !important;
  background: #c7c7cc !important;
  position: relative !important;
  transition: none !important;
  display: block !important;
  flex-shrink: 0 !important;
  flex-grow: 0 !important;
  contain: strict !important;
}

[data-theme="dark"] .toggle-track {
  background: #34c759;
}

.toggle-icon {
  position: relative;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.3s ease, color 0.3s ease;
  pointer-events: none;
  flex-shrink: 0;
  color: var(--fg);
}

.toggle-icon svg {
  width: 20px;
  height: 20px;
  stroke: currentColor;
}

.toggle-icon-sun {
  opacity: 1;
  margin-right: 0;
}

.toggle-icon-moon {
  opacity: 0.4;
  margin-left: 0;
}

[data-theme="dark"] .toggle-icon-sun {
  opacity: 0.4;
}

[data-theme="dark"] .toggle-icon-moon {
  opacity: 1;
}

.toggle-thumb {
  width: 27px !important;
  height: 27px !important;
  min-width: 27px !important;
  min-height: 27px !important;
  max-width: 27px !important;
  max-height: 27px !important;
  border-radius: 50% !important;
  background: white !important;
  position: absolute !important;
  top: 2px !important;
  left: 2px !important;
  transition: none !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2) !important;
  z-index: 2 !important;
  will-change: auto !important;
  -webkit-tap-highlight-color: transparent !important;
  contain: strict !important;
  transform: translateX(0) translateZ(0) !important;
  -webkit-transform: translateX(0) translateZ(0) !important;
}

[data-theme="dark"] .toggle-thumb {
  transform: translateX(20px) translateZ(0) !important;
  -webkit-transform: translateX(20px) translateZ(0) !important;
}

nav .theme-toggle.ios-toggle:hover .toggle-track {
  background: #b0b0b5;
}

[data-theme="dark"] nav .theme-toggle.ios-toggle:hover .toggle-track {
  background: #30d158;
}

nav .theme-toggle.ios-toggle:active .toggle-thumb {
  transform: scale(0.98);
  transition: transform 0.1s ease;
}

[data-theme="dark"] nav .theme-toggle.ios-toggle:active .toggle-thumb {
  transform: translateX(20px) scale(0.98);
  transition: transform 0.1s ease;
}

.hero { 
  padding: 80px 0; 
  text-align: center; 
  background: transparent !important;
}

.hero h1,
.hero .hero-title {
  font-size: 4rem;
  font-weight: 400;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .hero h1,
[data-theme="dark"] .hero .hero-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@media (max-width: 768px) {
  .hero h1,
  .hero .hero-title {
    font-size: 2.25rem !important;
  }
  
  .hero p,
  .hero .hero-description {
    font-size: 1.5rem !important;
  }
}

.hero p,
.hero .hero-description {
  font-size: 1.5rem;
  color: var(--muted);
  margin-bottom: 32px;
  line-height: 1.4;
  font-weight: 400;
}

.btn { 
  display: inline-block; 
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%); 
  color: white; 
  padding: 14px 28px; 
  border-radius: 50px; 
  text-decoration: none; 
  border: 2px solid transparent; 
  cursor: pointer; 
  font-weight: 600;
  font-size: 17px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
}

.btn:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  border-color: #F47600;
}

.btn-secondary { 
  background: var(--muted);
  box-shadow: 0 4px 16px rgba(134, 134, 139, 0.3);
}

.btn-danger { 
  background: #FF8000;
  color: white;
  border: 2px solid transparent;
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
}

.btn-danger:hover {
  background: #FF8000;
  border-color: #F47600;
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
}

/* Liquid Glass Buttons - Hero Section Only */
.btn-liquid-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 1.125rem 2.75rem;
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  border-radius: 50px;
  font-size: 1.125rem;
  font-weight: 700;
  text-decoration: none;
  position: relative;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  z-index: 1;
  text-align: center;
  white-space: nowrap;
}

.btn-liquid-shine {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.6s;
}

.btn-liquid-primary:hover .btn-liquid-shine {
  left: 100%;
}

.btn-liquid-primary:hover {
  transform: translateY(-3px) scale(1.02);
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  border-color: rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 
    0 12px 40px rgba(244, 118, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    0 8px 32px rgba(0, 0, 0, 0.2);
}

.btn-liquid-primary svg {
  transition: transform 0.3s ease;
  position: relative;
  z-index: 2;
}

.btn-liquid-primary:hover svg {
  transform: translateX(6px);
}

.btn-liquid-primary span {
  position: relative;
  z-index: 2;
}

.btn-liquid-secondary {
  display: inline-flex;
  align-items: center;
  padding: 1.125rem 2.75rem;
  background: var(--muted);
  color: white;
  border: 2px solid transparent;
  border-radius: 50px;
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 16px rgba(134, 134, 139, 0.3);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.btn-liquid-secondary:hover {
  background: var(--muted);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 
    0 8px 24px rgba(134, 134, 139, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-liquid-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 1.125rem 2.75rem;
  background: #FF8000;
  color: white;
  border: 2px solid transparent;
  border-radius: 50px;
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.btn-liquid-danger:hover {
  background: #FF8000;
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px) scale(1.02);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 
    0 12px 40px rgba(255, 128, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    0 8px 32px rgba(0, 0, 0, 0.2);
}

/* Mobile: Always show liquid glass effect and stack buttons */
@media (max-width: 768px) {
  .hero-actions {
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
  }
  
  /* Hero buttons only - not subscription form buttons */
  .hero-actions .btn-liquid-primary,
  .hero-actions .btn-liquid-secondary {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }
  
  /* Always show liquid glass effect on mobile (no hover needed) */
  .btn-liquid-primary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    box-shadow: 
      0 12px 40px rgba(244, 118, 0, 0.4),
      inset 0 1px 0 rgba(255, 255, 255, 0.3),
      0 8px 32px rgba(0, 0, 0, 0.2);
  }
  
  /* Show shine effect on mobile by default */
  .btn-liquid-primary .btn-liquid-shine {
    left: 0;
    animation: shineMobile 3s ease-in-out infinite;
  }
  
  @keyframes shineMobile {
    0%, 100% {
      left: -100%;
    }
    50% {
      left: 100%;
    }
  }
  
  .btn-liquid-secondary {
    background: var(--muted);
    border-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 
      0 8px 24px rgba(134, 134, 139, 0.4),
      inset 0 1px 0 rgba(255, 255, 255, 0.2);
  }
  
  /* Active state for touch feedback */
  .btn-liquid-primary:active {
    transform: scale(0.98);
  }
  
  .btn-liquid-secondary:active {
    transform: scale(0.98);
  }
  
  .btn-liquid-danger {
    border-color: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    box-shadow: 
      0 12px 40px rgba(255, 128, 0, 0.4),
      inset 0 1px 0 rgba(255, 255, 255, 0.3),
      0 8px 32px rgba(0, 0, 0, 0.2);
  }
  
  .btn-liquid-danger:active {
    transform: scale(0.98);
  }
}

.form { 
  display: grid; 
  gap: 20px; 
  max-width: 400px; 
  width: 100%;
}

label { 
  display: grid; 
  gap: 8px; 
  font-size: 16px; 
  color: var(--fg);
  font-weight: 500;
}

input, select { 
  padding: 16px; 
  border: 2px solid var(--border); 
  border-radius: 12px; 
  font-size: 17px; 
  background: var(--surface);
  transition: all 0.2s ease;
  font-family: inherit;
}

input:focus, select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
}

/* Number input wrapper with custom arrows */
.number-input-wrapper {
  position: relative;
  display: inline-block;
  width: 100%;
}

.number-input {
  width: 100%;
  padding-right: 50px;
  -webkit-appearance: none;
  -moz-appearance: textfield;
  appearance: none;
}

.number-input::-webkit-outer-spin-button,
.number-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.number-arrows {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 2px;
  z-index: 10;
}

.arrow-btn {
  background: none;
  border: none;
  padding: 0;
  margin: 0;
  width: 20px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 12px;
  color: #333333;
  transition: color 0.2s ease;
  user-select: none;
}

.arrow-btn:hover {
  color: #000000;
}

.arrow-btn:active {
  color: #007aff;
}

/* Dark theme arrow adjustments */
[data-theme="dark"] .arrow-btn {
  color: #cccccc;
}

[data-theme="dark"] .arrow-btn:hover {
  color: #ffffff;
}

[data-theme="dark"] .arrow-btn:active {
  color: #007aff;
}

.table { 
  width: 100%; 
  max-width: 100%;
  border-collapse: collapse; 
  margin: 2rem auto; 
  background: var(--surface);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: none;
  border: 1px solid var(--border);
  max-width: 1200px;
}

/* Default: Show single-row layout, hide two-row layout */
.category-subscriptions-table .table-header-single {
  display: table-row;
}

.category-subscriptions-table .table-header-two-row {
  display: none;
}

.category-subscriptions-table .subscription-row-single {
  display: table-row;
}

.category-subscriptions-table .subscription-row-two-row {
  display: none;
}

.table th, .table td { 
  padding: 1.5rem 1.25rem; 
  border-bottom: 1px solid var(--border); 
  text-align: left; 
  vertical-align: middle;
}

/* Ensure consistent spacing between columns */
.table th {
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
}

.table td {
  padding-top: 1.25rem;
  padding-bottom: 1.25rem;
}

/* Column-specific widths and alignment */
.table th:nth-child(1),
.table td:nth-child(1) {
  /* Service column */
  width: 25%;
  min-width: 180px;
  text-align: left;
  padding-right: 2rem;
}

.table th:nth-child(2),
.table td:nth-child(2) {
  /* Amount column */
  width: 12%;
  min-width: 100px;
  text-align: right;
  white-space: nowrap;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.table th:nth-child(3),
.table td:nth-child(3) {
  /* Due Date column */
  width: 18%;
  min-width: 130px;
  text-align: center;
  white-space: nowrap;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.table th:nth-child(4),
.table td:nth-child(4) {
  /* Remind Before column */
  width: 15%;
  min-width: 120px;
  text-align: center;
  white-space: nowrap;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.table th:nth-child(6),
.table td:nth-child(6) {
  /* Actions column */
  width: 30%;
  min-width: 200px;
  text-align: right;
  white-space: nowrap;
  padding-left: 2rem;
  padding-right: 1.25rem;
  position: relative;
  z-index: 10;
}

/* Remove borders from table cells containing buttons */
.table td .btn-group,
.table td .btn-liquid-secondary,
.table td .btn-liquid-danger {
  position: relative;
  z-index: 1;
  display: inline-flex !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* Actions column styling - keep border-bottom to extend divider lines */
.table td:last-child {
  border-bottom: 1px solid var(--border) !important;
  border-left: none !important;
  border-right: none !important;
  background: transparent !important;
  padding-top: 1.25rem !important;
  padding-bottom: 1.25rem !important;
  padding-left: 2rem !important;
  padding-right: 1.25rem !important;
}

/* Due date cell alignment */
.due-date-cell {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

/* Amount column - ensure right alignment */
.table td:nth-child(2) {
  font-weight: 500;
  color: var(--fg);
}

/* Remind Before column - center alignment */
.table td:nth-child(4) {
  color: var(--muted);
}

.table td:nth-child(4) .reminder-off {
  color: var(--muted);
  font-style: italic;
}

.table th:last-child {
  border-bottom: 1px solid var(--border);
}

/* Ensure Actions column is always visible */
.table th:nth-child(6),
.table td:nth-child(6) {
  display: table-cell !important;
  visibility: visible !important;
}

/* Ensure buttons in Actions column are visible */
.table td:nth-child(6) .btn-group,
.table td:nth-child(6) .btn-liquid-secondary,
.table td:nth-child(6) .btn-liquid-danger,
.table td:nth-child(6) .edit-link,
.table td:nth-child(6) .delete-form {
  display: inline-flex !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.table th {
  background: var(--bg);
  font-weight: 400;
  color: var(--fg);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.table td {
  font-size: 1rem;
  font-weight: 400;
}

.table tr:hover {
  background: transparent;
}

/* Specific column widths for better spacing */
.table th:nth-child(1), .table td:nth-child(1) { min-width: 150px; } /* Service */
.table th:nth-child(2), .table td:nth-child(2) { min-width: 100px; } /* Category */
.table th:nth-child(3), .table td:nth-child(3) { min-width: 100px; } /* Amount */
.table th:nth-child(4), .table td:nth-child(4) { min-width: 120px; text-align: center; } /* Due Date */
.table th:nth-child(5), .table td:nth-child(5) { min-width: 140px; text-align: center; } /* Remind Before */
.table th:nth-child(6), .table td:nth-child(6) { min-width: 200px; text-align: right; } /* Actions */

.flash-list { 
  list-style: none; 
  padding: 0; 
}

.flash { 
  padding: 1.5rem 2rem; 
  border-radius: 0; 
  background: var(--surface);
  margin-bottom: 1.5rem; 
  border-left: 1px solid var(--primary);
  border: 1px solid var(--border);
  border-left-width: 4px;
  box-shadow: none;
}

/* Center helpers */
.centered { 
  max-width: 1200px; 
  margin: 0 auto; 
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2rem; 
  padding: 48px 2rem 6rem 2rem;
  box-sizing: border-box;
}

.centered h2 {
  font-size: 3rem;
  font-weight: 400;
  margin-bottom: 3rem;
  letter-spacing: -0.02em;
  text-align: center;
  width: 100%;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .centered h2 {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Account page specific styling */
/* Account Page - 2 Column Grid Layout */
.account-page {
  max-width: 1200px !important; /* Wider for 2 columns */
  padding: 48px 2rem 6rem 2rem;
}

/* Email Settings - Close gaps between elements */
.account-page .auth-card:nth-child(4) .info-text {
  margin-bottom: 0px !important;
  margin-top: 0px !important;
  padding: 8px 16px !important;
  line-height: 1.3 !important;
}

.account-page .auth-card:nth-child(4) .form {
  margin-top: 4px !important;
  gap: 4px !important;
}

/* Mobile spacing for email settings */
@media (max-width: 768px) {
  .account-page .auth-card:nth-child(4) .info-text {
    margin-bottom: 8px !important;
    padding: 12px 16px !important;
    line-height: 1.4 !important;
  }
  
  .account-page .auth-card:nth-child(4) .form {
    margin-top: 12px !important;
    gap: 8px !important;
  }
}

.account-page .account-grid {
  display: grid;
  grid-template-columns: 1fr 1fr; /* 2 columns on desktop */
  gap: 3rem;
  margin-top: 0;
}

.account-page .auth-card {
  max-width: 100%;
  margin: 0; /* Remove margin since grid handles spacing */
}

.account-page h2 {
  font-size: 3rem;
  font-weight: 400;
  margin-bottom: 3rem;
  letter-spacing: -0.02em;
  text-align: center;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .account-page h2 {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.account-page h3 {
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--fg);
  letter-spacing: -0.01em;
}

.dashboard-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 2rem 6rem 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 3rem;
  width: 100%;
  box-sizing: border-box;
  min-height: calc(100vh - 72px);
  position: relative;
}

/* Dashboard Header with Clock */
.dashboard-header-with-clock {
  position: relative;
  width: 100%;
  margin-bottom: 1.5rem;
}

.dashboard-header-with-clock .section-title {
  text-align: center;
  margin-bottom: 0;
}

.dashboard-header-with-clock .pilot-clock-container {
  position: absolute;
  left: 88%;
  top: 50%;
  transform: translateX(-50%) translateY(-50%);
}

/* IWC Pilot Watch Inspired Clock */
.pilot-clock-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

.pilot-clock {
  width: 180px;
  height: 180px;
  position: relative;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid #788084;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1), inset 0 0 20px rgba(0, 0, 0, 0.05);
  flex-shrink: 0;
}

[data-theme="dark"] .pilot-clock {
  background: #000000;
  border-color: #788084;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6), inset 0 0 20px rgba(255, 255, 255, 0.05);
}

.clock-face {
  width: 100%;
  height: 100%;
  position: relative;
  border-radius: 50%;
}

.clock-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 10px;
  height: 10px;
  background: #000000;
  border-radius: 50%;
  z-index: 10;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .clock-center {
  background: #ffffff;
  box-shadow: 0 0 4px rgba(255, 255, 255, 0.5);
}

/* Clock Hands */
.hour-hand,
.minute-hand,
.second-hand {
  position: absolute;
  top: 50%;
  left: 50%;
  transform-origin: bottom center;
  background: #000000;
  border-radius: 2px;
  box-shadow: 0 0 2px rgba(0, 0, 0, 0.3);
}

[data-theme="dark"] .hour-hand,
[data-theme="dark"] .minute-hand {
  background: #ffffff;
  box-shadow: 0 0 2px rgba(255, 255, 255, 0.3);
}

.hour-hand {
  width: 4px;
  height: 52px;
  margin-left: -2px;
  margin-top: -52px;
  z-index: 3;
}

.minute-hand {
  width: 3px;
  height: 68px;
  margin-left: -1.5px;
  margin-top: -68px;
  z-index: 2;
}

.second-hand {
  width: 1.5px;
  height: 72px;
  margin-left: -0.75px;
  margin-top: -72px;
  background: #ff3b30;
  z-index: 1;
  box-shadow: none;
}

/* Hour Markers - IWC Pilot Watch Style */
.hour-marker {
  position: absolute;
  top: 50%;
  left: 50%;
  transform-origin: center center;
  color: #000000;
  font-weight: 600;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  text-align: center;
  line-height: 1;
  z-index: 5;
  width: 40px;
  height: 40px;
  margin-left: -20px;
  margin-top: -20px;
  font-size: 18px;
  letter-spacing: 0.5px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

[data-theme="dark"] .hour-marker {
  color: #ffffff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

/* Position hour markers around the clock (radius ~70px from center for 180px clock, near the outline) */
/* Standard clock: 12 top, 3 right, 6 bottom, 9 left */
/* CSS: rotate then translate, then counter-rotate to keep text upright */
.hour-12 {
  transform: rotate(0deg) translateY(-70px) rotate(0deg);
  font-size: 24px;
  font-weight: 700;
  color: #F47600 !important;
}

.hour-1 {
  transform: rotate(30deg) translateY(-70px) rotate(-30deg);
  font-size: 20px;
}

.hour-2 {
  transform: rotate(60deg) translateY(-70px) rotate(-60deg);
  font-size: 20px;
}

.hour-3 {
  transform: rotate(90deg) translateY(-70px) rotate(-90deg);
  font-size: 24px;
  font-weight: 700;
  color: #F47600 !important;
}

.hour-4 {
  transform: rotate(120deg) translateY(-70px) rotate(-120deg);
  font-size: 20px;
}

.hour-5 {
  transform: rotate(150deg) translateY(-70px) rotate(-150deg);
  font-size: 20px;
}

.hour-6 {
  transform: rotate(180deg) translateY(-70px) rotate(180deg);
  font-size: 24px;
  font-weight: 700;
  color: #F47600 !important;
}

.hour-7 {
  transform: rotate(210deg) translateY(-70px) rotate(-210deg);
  font-size: 20px;
}

.hour-8 {
  transform: rotate(240deg) translateY(-70px) rotate(-240deg);
  font-size: 20px;
}

.hour-9 {
  transform: rotate(270deg) translateY(-70px) rotate(-270deg);
  font-size: 24px;
  font-weight: 700;
  color: #F47600 !important;
}

.hour-10 {
  transform: rotate(300deg) translateY(-70px) rotate(-300deg);
  font-size: 20px;
}

.hour-11 {
  transform: rotate(330deg) translateY(-70px) rotate(-330deg);
  font-size: 20px;
}

[data-theme="dark"] .hour-12,
[data-theme="dark"] .hour-3,
[data-theme="dark"] .hour-6,
[data-theme="dark"] .hour-9 {
  color: #F47600 !important;
}

/* Mobile: Hide clock */
@media (max-width: 768px) {
  .pilot-clock-container {
    display: none;
  }
  
  .dashboard-header-with-clock {
    position: relative;
  }
}

/* Desktop: Dashboard and analytics titles with gradient like landing page */
.dashboard-container h2.section-title,
.analytics-header h2.section-title {
  font-size: 3rem;
  font-weight: 400;
  margin-bottom: 3rem;
  letter-spacing: -0.02em;
  text-align: center;
  width: 100%;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .dashboard-container h2.section-title,
[data-theme="dark"] .analytics-header h2.section-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.dashboard-container h2:not(.section-title) {
  font-size: 3rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 3rem;
  letter-spacing: -0.02em;
  text-align: center;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

.analytics-header h2:not(.section-title) {
  font-size: 3rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 0;
  letter-spacing: -0.02em;
  text-align: center;
  width: 100%;
}

/* Mobile and Tablet Responsive Design */
@media (max-width: 1024px) and (orientation: portrait) {
  .dashboard-container h2.section-title,
  .analytics-header h2.section-title {
    font-size: 2.25rem !important;
    font-weight: 400 !important;
    margin-bottom: 0 !important;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #F47600 0%, #000000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .dashboard-container h2:not(.section-title),
  .analytics-header h2:not(.section-title) {
    text-align: center;
    font-size: 26px;
    font-weight: 700;
    color: var(--fg);
    margin-bottom: 2rem;
    width: 100%;
  }
  
  /* Tablet cards layout */
  .cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 24px;
    padding: 0 12px;
    width: 100%;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
  }
  
  /* Tablet dashboard and analytics circles - 2x2 grid */
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 180px) !important;
    grid-template-rows: repeat(2, 180px) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    padding: 0 12px !important;
    justify-content: center !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    padding: 0 12px !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .card {
    padding: 18px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--border);
    background: var(--surface);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }
  
  .card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
  }
  
  .card-title {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--muted);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
  }
  
  .card-value {
    font-size: 2.5rem;
    font-weight: 400;
    color: var(--fg);
    line-height: 1.2;
  }
  
  /* Mobile: Force dashboard cards to be square like analytics */
  .dashboard-container .card {
    width: 180px !important;
    height: 180px !important;
    min-width: 180px !important;
    min-height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
  }
}

@media (max-width: 768px) and (orientation: portrait) {
  /* Dashboard and analytics titles with gradient */
  .dashboard-container h2.section-title,
  .analytics-header h2.section-title {
    background: linear-gradient(135deg, #F47600 0%, #000000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
  }
  
  .dashboard-container h2:not(.section-title),
  .analytics-header h2:not(.section-title) {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    color: var(--fg);
    margin-bottom: 2rem;
    width: 100%;
  }
  
  /* Mobile cards layout - 2x2 grid for dashboard */
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 180px) !important;
    grid-template-rows: repeat(2, 180px) !important;
    gap: 12px !important;
    margin-bottom: 20px !important;
    padding: 0 4px !important;
    width: 100% !important;
    justify-content: center !important;
    justify-items: center !important;
  }
  
  .dashboard-container .card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    min-width: 180px !important;
    min-height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    flex-shrink: 0 !important;
  }
  
  .dashboard-container .card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  .dashboard-container .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  /* Ensure dashboard and analytics cards match exactly on mobile portrait */
  .dashboard-container .card,
  .summary-card.card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  }
  
  .dashboard-container .card-title,
  .summary-card.card .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value,
  .summary-card.card .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  /* FAQ section spacing for mobile portrait */
  .faq-section {
    padding: 0.5rem 1.5rem 1rem 1.5rem !important;
    margin-top: -1rem !important;
  }
  
  .faq-section .section-header {
    margin-bottom: 1.5rem !important;
  }
}

@media (max-width: 480px) {
  /* Dashboard and analytics titles inherit from .section-title - no overrides needed */
  
  .dashboard-container h2:not(.section-title),
  .analytics-header h2:not(.section-title) {
    text-align: center;
    font-size: 22px;
    font-weight: 700;
    color: var(--fg);
    margin-bottom: 2rem;
    width: 100%;
  }
  
  /* Small mobile cards layout - 2x2 grid for dashboard */
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 180px) !important;
    grid-template-rows: repeat(2, 180px) !important;
    gap: 12px !important;
    margin-bottom: 20px !important;
    padding: 0 4px !important;
    width: 100% !important;
    justify-content: center !important;
    justify-items: center !important;
  }
  
  .dashboard-container .card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    min-width: 180px !important;
    min-height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    flex-shrink: 0 !important;
  }
  
  .dashboard-container .card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  .dashboard-container .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  /* Ensure dashboard and analytics cards match exactly on small mobile */
  .dashboard-container .card,
  .summary-card.card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  }
  
  .dashboard-container .card-title,
  .summary-card.card .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value,
  .summary-card.card .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
}

@media (max-width: 320px) {
  /* Dashboard and analytics titles inherit from .section-title - no overrides needed */
  
  .dashboard-container h2:not(.section-title),
  .analytics-header h2:not(.section-title) {
    text-align: center;
    font-size: 20px;
    font-weight: 700;
    color: var(--fg);
    margin-bottom: 2rem;
    width: 100%;
  }
  
  /* Very small mobile cards layout - 2x2 grid for dashboard */
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 180px) !important;
    grid-template-rows: repeat(2, 180px) !important;
    gap: 12px !important;
    margin-bottom: 20px !important;
    padding: 0 4px !important;
    width: 100% !important;
    justify-content: center !important;
    justify-items: center !important;
  }
  
  .dashboard-container .card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    min-width: 180px !important;
    min-height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    flex-shrink: 0 !important;
  }
  
  .dashboard-container .card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  .dashboard-container .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  /* Ensure dashboard and analytics cards match exactly on very small mobile */
  .dashboard-container .card,
  .summary-card.card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  }
  
  .dashboard-container .card-title,
  .summary-card.card .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value,
  .summary-card.card .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
}

.table-container {
  width: 100%;
  display: flex;
  justify-content: center;
  background: var(--surface);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 8px 32px var(--shadow);
  border: 1px solid var(--border);
  box-sizing: border-box;
}

.actions { 
  display: flex; 
  gap: 12px; 
  justify-content: center; 
  margin: 0; /* Remove bottom margin */
}

/* iOS-Inspired Pill Buttons for Dashboard */
.btn-group {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  border: none;
  background: transparent;
  padding: 0;
  margin: 0;
}

.btn-group .btn-liquid-secondary,
.btn-group .btn-liquid-danger {
  padding: 0.875rem 1.5rem;
  font-size: 0.95rem;
  position: relative;
  overflow: hidden;
  border: 2px solid transparent !important;
  outline: none !important;
  box-shadow: 0 4px 16px rgba(134, 134, 139, 0.3) !important;
}

.btn-group .btn-liquid-secondary {
  box-shadow: 0 4px 16px rgba(134, 134, 139, 0.3) !important;
}

.btn-group .btn-liquid-danger {
  box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3) !important;
}

.btn-group .btn-liquid-secondary:focus,
.btn-group .btn-liquid-danger:focus {
  outline: none !important;
}

.btn-group form {
  border: none;
  background: transparent;
  padding: 0;
  margin: 0;
  display: inline-block;
}

.btn-group .btn-liquid-secondary:hover {
  background: var(--muted);
  border-color: rgba(255, 255, 255, 0.3) !important;
  transform: translateY(-3px) scale(1.02);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 
    0 8px 24px rgba(134, 134, 139, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

.btn-group .btn-liquid-danger:hover {
  background: #FF8000;
  border-color: rgba(255, 255, 255, 0.3) !important;
  transform: translateY(-3px) scale(1.02);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 
    0 12px 40px rgba(255, 128, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    0 8px 32px rgba(0, 0, 0, 0.2) !important;
}

.btn-group .btn-secondary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  border-radius: 50px;
  padding: 14px 32px;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  min-width: auto;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-group .btn-secondary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  border-color: #F47600;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
}

.btn-group .btn-danger {
  background: #FF8000;
  color: white;
  border: 2px solid transparent;
  border-radius: 50px;
  padding: 14px 32px;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  min-width: auto;
  white-space: nowrap;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-group .btn-danger:hover {
  background: #FF8000;
  border-color: #F47600;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
}

/* Dark theme adjustments */
[data-theme="dark"] .btn-group .btn-secondary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border-color: transparent;
}

[data-theme="dark"] .btn-group .btn-secondary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  border-color: #F47600;
}

[data-theme="dark"] .btn-group .btn-danger {
  background: #FF8000;
  color: white;
  border-color: transparent;
}

[data-theme="dark"] .btn-group .btn-danger:hover {
  background: #FF8000;
  border-color: #F47600;
}

.auth-card { 
  padding: 3rem 2.5rem; 
  border: 1px solid var(--border); 
  border-radius: 0; 
  width: 100%; 
  max-width: 100%; 
  background: var(--surface);
  box-shadow: none;
  backdrop-filter: none;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Mobile: Override auth-card - REMOVED, handled in specific media queries above */

.auth-links {
  margin-top: 20px;
  text-align: center;
}

.forgot-password-link, .back-to-login-link {
  color: var(--primary);
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.forgot-password-link:hover, .back-to-login-link:hover {
  color: #0056b3;
  text-decoration: underline;
}

.forgot-password-text, .reset-password-text {
  color: var(--muted);
  text-align: center;
  margin-bottom: 24px;
  font-size: 16px;
  line-height: 1.4;
}

/* iOS-style hint bar */
.hint-bar {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 16px;
  background: linear-gradient(135deg, #f8f9ff 0%, #f0f4ff 100%);
  border: 1px solid #e1e8ff;
  border-radius: 12px;
  margin-bottom: 24px;
  box-shadow: 0 2px 8px rgba(0, 122, 255, 0.08);
}

.hint-icon {
  font-size: 20px;
  flex-shrink: 0;
  margin-top: 2px;
}

.hint-content {
  flex: 1;
}

.hint-title {
  font-weight: 600;
  font-size: 15px;
  color: var(--primary);
  margin-bottom: 4px;
}

.hint-text {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.4;
}

/* Password hint field styling */
.hint-label {
  opacity: 0.8;
  font-style: italic;
}

.hint-label input {
  background-color: #fafafa;
  border: 1px solid #e0e0e0;
  font-style: normal;
}

.hint-label input:focus {
  background-color: var(--surface);
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

/* Desktop only - 4 in one row (1025px+) - MUST override tablet 2x2 - MUST BE AFTER TABLET */
@media (min-width: 1025px) {
  .dashboard-container .cards { 
    display: grid !important; 
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important; 
    width: 100% !important; 
    max-width: 100% !important;
    margin: 0 auto 32px auto !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
  }
  
  .dashboard-container .cards .card {
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(3) {
    grid-column: 3 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(4) {
    grid-column: 4 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    margin: 0 auto 32px auto !important;
    width: 100% !important;
    max-width: 100% !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
  }
  
  .analytics-summary .summary-card.card {
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(3) {
    grid-column: 3 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(4) {
    grid-column: 4 !important;
    grid-row: 1 !important;
  }
}

.dashboard-container .card {
  border: 3px solid var(--border) !important;
  border-radius: 24px !important;
  padding: 2.5rem !important;
  background: var(--surface) !important;
  width: 300px !important;
  min-height: 300px !important;
  height: auto !important;
  box-shadow: 0 4px 12px var(--shadow) !important;
  transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  margin: 0 !important;
}

/* Mobile: Force square cards to match analytics exactly */
@media (max-width: 768px) {
  .dashboard-container .card {
    width: 180px !important;
    height: 180px !important;
    min-width: 180px !important;
    min-height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
    padding: 1.25rem !important;
    border-radius: 20px !important;
    flex-shrink: 0 !important;
  }
}

/* Mobile override: Force square cards on mobile to match analytics */
@media (max-width: 768px) {
  .dashboard-container .card {
    width: 180px !important;
    height: 180px !important;
    min-width: 180px !important;
    min-height: 180px !important;
    max-width: 180px !important;
    max-height: 180px !important;
    padding: 1.25rem !important;
    border-radius: 20px !important;
  }
}

.dashboard-container .card:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 6px 20px var(--shadow) !important;
}

.dashboard-container .card-title { 
  color: var(--muted) !important; 
  font-size: 1.1rem !important;
  text-transform: uppercase !important; 
  letter-spacing: 0.5px !important; 
  font-weight: 500 !important;
  margin-bottom: 0.75rem !important;
}

.dashboard-container .card-value { 
  font-size: 2.4rem !important; 
  font-weight: 600 !important; 
  color: var(--fg) !important;
  line-height: 1.2 !important;
}

/* Card border colors - Total Subscriptions and Total Monthly */
.dashboard-container .cards .card:nth-child(1),
.dashboard-container .cards .card:nth-child(2) {
  border-color: #788084 !important;
}

/* Paid and Remaining card styles */
.dashboard-container .paid-card {
  border-color: #28a745 !important;
}

.dashboard-container .paid-card .card-title {
  color: #28a745 !important;
}

.dashboard-container .paid-amount {
  color: #28a745 !important;
}

.dashboard-container .remaining-card {
  border-color: #F47600 !important;
}

.dashboard-container .remaining-card .card-title {
  color: #F47600 !important;
}

.dashboard-container .remaining-amount {
  color: #F47600 !important;
}

/* Due date cell styling */
.due-date-cell {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.passed-indicator {
  color: #28a745;
  font-weight: bold;
  font-size: 16px;
  background: rgba(40, 167, 69, 0.1);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #28a745;
  animation: checkmark-pulse 2s ease-in-out infinite;
}

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

/* Dark theme adjustments for paid indicator */
[data-theme="dark"] .passed-indicator {
  background: rgba(40, 167, 69, 0.2);
  border-color: #34ce57;
  color: #34ce57;
}

/* Calendar checkmark animation */
@keyframes checkmark-pulse {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.8;
  }
}

/* Landing page iOS-inspired container */
.ios-text-container {
  background: var(--surface);
  border-radius: 24px;
  padding: 40px 36px;
  text-align: center;
  max-width: 600px;
  width: 100%;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  border: 1px solid var(--border);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  margin: 0 auto 40px auto;
}

.ios-title {
  font-size: 36px;
  font-weight: 800;
  color: var(--fg);
  margin: 0 0 20px 0;
  line-height: 1.1;
  letter-spacing: -1px;
}

.ios-description {
  font-size: 18px;
  font-weight: 400;
  color: var(--muted);
  margin: 0;
  line-height: 1.6;
  letter-spacing: 0.3px;
}

/* Dark theme adjustments for iOS container */
[data-theme="dark"] .ios-text-container {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .ios-title {
  color: var(--fg);
}

[data-theme="dark"] .ios-description {
  color: var(--muted);
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
  .ios-text-container {
    padding: 32px 24px;
    border-radius: 20px;
    margin: 0 auto 32px auto;
    max-width: 100%;
  }
  
  .ios-title {
    font-size: 28px;
    margin-bottom: 16px;
  }
  
  .ios-description {
    font-size: 16px;
  }
}

/* ========================================
   RESPONSIVE DESIGN SYSTEM
   Breakpoints: 320px, 768px, 1024px, 1440px
   ======================================== */

/* Base styles for all devices */
* {
  box-sizing: border-box;
}


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

/* Navigation - Responsive */
.navbar {
  background: rgba(245, 245, 247, 0.15) !important;
  border-bottom: none;
  backdrop-filter: blur(40px) saturate(180%) !important;
  -webkit-backdrop-filter: blur(40px) saturate(180%) !important;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 1000 !important;
  min-height: 72px !important;
  padding: 0 !important;
  margin: 0 !important;
  box-shadow: none !important;
  width: 100% !important;
  border-top-left-radius: 20px !important;
  border-top-right-radius: 20px !important;
  border-bottom-left-radius: 20px !important;
  border-bottom-right-radius: 20px !important;
}

[data-theme="dark"] .navbar {
  background: rgba(29, 29, 31, 0.15);
  border-bottom: none;
  box-shadow: none;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px !important;
  min-height: 72px !important;
  margin: 0 !important;
  max-width: none !important;
}

.brand {
  font-size: 20px;
  font-weight: 700;
  color: var(--fg);
  text-decoration: none;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.brand img {
  height: 32px;
  width: auto;
  margin-right: 3px;
}

.nav-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-group a {
  color: var(--fg);
  text-decoration: none;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.nav-group a:hover {
  background: #F47600;
  color: white;
}

.theme-toggle {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.theme-toggle:hover {
  background: var(--border);
}

.theme-icon {
  font-size: 18px;
  transition: transform 0.2s ease;
}

.theme-toggle:hover .theme-icon {
  transform: rotate(180deg);
}

/* Hamburger menu - Mobile only */
/* Hamburger menu - hidden on desktop, shown on mobile */
@media (min-width: 769px) {
.hamburger-menu {
  display: none;
  }
}

.hamburger-menu {
  flex-direction: column;
  justify-content: space-around;
  width: 24px;
  height: 24px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
}

.hamburger-menu span {
  width: 100%;
  height: 2px;
  background: var(--fg);
  border-radius: 1px;
  transition: all 0.3s ease;
  transform-origin: center;
}

.hamburger-menu.hamburger-active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger-menu.hamburger-active span:nth-child(2) {
  opacity: 0;
}

.hamburger-menu.hamburger-active span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}


.centered {
  max-width: 100%;
  margin: 0 auto;
  padding: 6rem 2rem;
}

/* Cards - Responsive Grid */
.cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
  margin-bottom: 3rem;
  width: 100%;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0;
  padding: 3rem 2.5rem;
  box-shadow: none;
  transition: border-color 0.2s ease;
}

.card:hover {
  border-color: var(--fg);
}

.card-title {
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--muted);
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.card-value {
  font-size: 3rem;
  font-weight: 400;
  color: var(--fg);
  line-height: 1.2;
}

/* Forms - Responsive */
.form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 100%;
}

.form label {
  font-size: 14px;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 6px;
  display: block;
}

.form input,
.form textarea,
.form select {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--background);
  color: var(--fg);
  font-size: 16px;
  transition: all 0.2s ease;
}

.form input:focus,
.form textarea:focus,
.form select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

/* Buttons - Responsive */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border: 2px solid transparent;
  border-radius: 50px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  min-height: 44px;
  width: 100%;
  max-width: 100%;
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
}

.btn:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  border-color: #F47600;
}

/* Auth card button centering */
.auth-card .btn {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  display: block;
  text-align: center;
}

/* Auth card liquid glass buttons */
.auth-card .btn-liquid-primary {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
}

/* Account page liquid glass buttons */
.account-page .btn-liquid-primary,
.account-page .btn-liquid-secondary,
.account-page .btn-liquid-danger {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
}

.btn-primary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  border-radius: 50px;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  border-color: #F47600;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  color: white;
}

.btn-secondary {
  background: var(--surface);
  color: var(--fg);
  border: 2px solid var(--border);
  border-radius: 50px;
}

.btn-secondary:hover {
  background: var(--border);
  border-color: #F47600;
}

/* Auth cards */
.auth-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
  max-width: 100%;
  margin: 20px auto;
}

.auth-card h2 {
  font-size: 24px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 20px;
  text-align: center;
}

/* Subscription cards - Responsive */
.subscription-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: none;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

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

.subscription-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--fg);
  flex: 1;
  min-width: 0;
  word-wrap: break-word;
}

.subscription-amount {
  font-size: 18px;
  font-weight: 800;
  color: var(--primary);
}

.subscription-details {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.subscription-detail {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.subscription-detail:last-child {
  border-bottom: none;
}

.subscription-detail-label {
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

.subscription-detail-value {
  font-size: 13px;
  font-weight: 700;
  color: var(--fg);
}

.subscription-actions {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}

.subscription-actions .btn {
  flex: 1;
  padding: 10px 16px;
  font-size: 13px;
  min-height: 40px;
  border-radius: 50px;
  border: 2px solid transparent;
  transition: all 0.3s ease;
}

.subscription-actions .btn-liquid-secondary,
.subscription-actions .btn-liquid-danger {
  flex: 1 1 0;
  padding: 0.875rem 1.25rem;
  font-size: 0.9rem;
  min-height: 44px;
  max-height: 44px;
  height: 44px;
  position: relative;
  overflow: hidden;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  border: 2px solid transparent !important;
  outline: none !important;
  display: flex;
  align-items: center;
  justify-content: center;
}

.subscription-actions .btn-liquid-secondary:focus,
.subscription-actions .btn-liquid-danger:focus {
  outline: none !important;
  box-shadow: none;
}

.subscription-actions .delete-form {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  margin: 0;
  padding: 0;
}

.subscription-actions .delete-form .btn-liquid-danger {
  flex: 1 1 0;
  width: 100%;
  height: 44px;
  min-height: 44px;
  max-height: 44px;
  min-width: 0;
}

.subscription-actions .btn-liquid-secondary:hover {
  background: var(--muted);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px) scale(1.02);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 
    0 8px 24px rgba(134, 134, 139, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.subscription-actions .btn-liquid-danger:hover {
  background: #FF8000;
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-3px) scale(1.02);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 
    0 12px 40px rgba(255, 128, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    0 8px 32px rgba(0, 0, 0, 0.2);
}

.subscription-actions .btn-secondary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
}

.subscription-actions .btn-secondary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  border-color: #F47600;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
}

.subscription-actions .btn-danger {
  background: #FF8000;
  color: white;
  box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
}

.subscription-actions .btn-danger:hover {
  background: #FF8000;
  border-color: #F47600;
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
}

/* Table - Responsive */
.table-container {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 0 auto 20px auto;
  width: 100%;
  max-width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.table {
  width: 100%;
  min-width: 600px;
  border-collapse: collapse;
  font-size: 13px;
}

.table th,
.table td {
  padding: 8px 6px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.table th {
  background: var(--surface);
  font-weight: 600;
  color: var(--fg);
}

.table td {
  color: var(--fg);
}


.copyright {
  font-size: 12px;
  color: var(--muted);
  margin: 0;
}

/* ========================================
   RESPONSIVE BREAKPOINTS
   ======================================== */

/* Mobile Small (320px - 479px) */
@media (max-width: 479px) {
  .container {
    padding: 0 12px;
  }
  
  .navbar .container {
    padding: 10px 12px;
    min-height: 56px;
  }
  
  .brand {
    font-size: 18px;
    gap: 6px;
  }
  
  .brand img {
    height: 28px;
  }
  
  .nav-group {
    gap: 8px;
  }
  
  .nav-group a {
    padding: 6px 8px;
    font-size: 13px;
  }
  
  main.container {
    flex: 1;
    padding: 16px 12px;
    padding-top: 80px; /* Keep top padding for fixed navbar */
  }
  
  .centered {
    padding: 16px 12px;
  }
  
  .card {
    padding: 12px;
  }
  
  .card-title {
    font-size: 13px;
  }
  
  .card-value {
    font-size: 18px;
  }
  
  .auth-card {
    padding: 20px;
    margin: 16px auto;
  }
  
  .auth-card h2 {
    font-size: 20px;
  }
  
  .form input,
  .form textarea,
  .form select {
    padding: 10px 12px;
    font-size: 16px;
  }
  
  .btn {
    padding: 10px 16px;
    font-size: 13px;
    min-height: 40px;
  }
  
  .subscription-card {
    padding: 12px;
  }
  
  .subscription-name {
    font-size: 14px;
  }
  
  .subscription-amount {
    font-size: 16px;
  }
  
  .subscription-detail-label,
  .subscription-detail-value {
    font-size: 12px;
  }
  
  .subscription-actions .btn {
    padding: 8px 12px;
    font-size: 12px;
    min-height: 36px;
  }
  
  .table {
    font-size: 11px;
  }
  
  .table th,
  .table td {
    padding: 6px 4px;
  }
}

/* Mobile Large (480px - 767px) */
@media (min-width: 480px) and (max-width: 767px) {
  /* Keep section titles same size on all mobile screens */
  .section-title {
    font-size: 2.25rem !important;
  }
  
  .how-it-works .section-title,
  .features .section-title,
  .plans .section-title,
  .testimonials-showcase .section-title,
  .faq-section .section-title {
    font-size: 2.25rem !important;
  }
  
  .container {
    padding: 0 16px;
  }
  
  .navbar .container {
    padding: 12px 16px;
    min-height: 60px;
  }
  
  .brand {
    font-size: 20px;
  }
  
  .brand img {
    height: 30px;
    margin-right: 3px;
  }
  
  .nav-group {
    gap: 12px;
  }
  
  .nav-group a {
    padding: 8px 12px;
    font-size: 14px;
  }
  
  main.container {
    flex: 1;
    padding: 20px 16px;
    padding-top: 80px; /* Keep top padding for fixed navbar */
  }
  
  .centered {
    padding: 20px 16px;
  }
  
  .card {
    padding: 16px;
  }
  
  .card-title {
    font-size: 14px;
  }
  
  .card-value {
    font-size: 20px;
  }
  
  .auth-card {
    padding: 24px;
    margin: 20px auto;
  }
  
  .auth-card h2 {
    font-size: 24px;
  }
  
  .form input,
  .form textarea,
  .form select {
    padding: 12px 16px;
    font-size: 16px;
  }
  
  .btn {
    padding: 12px 20px;
    font-size: 14px;
    min-height: 44px;
  }
  
  .subscription-card {
    padding: 16px;
  }
  
  .subscription-name {
    font-size: 16px;
  }
  
  .subscription-amount {
    font-size: 18px;
  }
  
  .subscription-detail-label,
  .subscription-detail-value {
    font-size: 13px;
  }
  
  .subscription-actions .btn {
    padding: 10px 16px;
    font-size: 13px;
    min-height: 40px;
  }
  
  .table {
    font-size: 13px;
  }
  
  .table th,
  .table td {
    padding: 8px 6px;
  }
  
}

/* Tablet (768px - 1023px) - Use mobile card view, hide table */
@media (min-width: 768px) and (max-width: 1023px) {
  /* Hide desktop table on tablet, show mobile cards */
  .table-container.desktop-only {
    display: none !important;
  }
  
  .mobile-subscriptions.mobile-only {
    display: block !important;
  }
  
  .container {
    padding: 0 16px;
    max-width: 480px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
  }
  
  .category-modal {
    max-width: 480px !important;
    width: 100% !important;
    margin: 0 auto !important;
  }
  
  .category-modal-content {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 24px 16px !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }
  
  .mobile-subscriptions {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 24px 16px !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }
  
  /* Match passed indicator size to smaller screens */
  .passed-indicator {
    font-size: 12px !important;
    width: 16px !important;
    height: 16px !important;
    border: 1px solid var(--success) !important;
    border-radius: 8px !important;
  }
  
  /* Have check mark in same row with the date, on the left side */
  .due-date-cell {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
  }
  
  /* Wrap text nodes in a span for proper flexbox handling */
  .due-date-cell {
    white-space: nowrap !important;
  }
  
  .due-date-cell .passed-indicator {
    order: -1 !important;
    flex-shrink: 0 !important;
    display: inline-flex !important;
    align-self: center !important;
    margin: 0 !important;
  }
  
  /* For mobile subscription cards */
  .subscription-detail-value .due-date-cell {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
  }
  
  .subscription-detail-value .due-date-cell .passed-indicator {
    order: -1 !important;
    flex-shrink: 0 !important;
    display: inline-flex !important;
    align-self: center !important;
    margin: 0 !important;
  }
  
  .navbar .container {
    padding: 16px 24px;
    min-height: 64px;
  }
  
  .brand {
    font-size: 22px;
  }
  
  .brand img {
    height: 32px;
    margin-right: 3px;
  }
  
  .nav-group {
    gap: 16px;
  }
  
  .nav-group a {
    padding: 8px 16px;
    font-size: 15px;
  }
  
  main.container {
    flex: 1;
    padding: 24px 24px;
    padding-top: 80px; /* Keep top padding for fixed navbar */
  }
  
  .centered {
    padding: 24px 24px;
  }
  
  /* 2x2 grid for cards */
  .cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  
  .card {
    padding: 20px;
  }
  
  .card-title {
    font-size: 15px;
  }
  
  .card-value {
    font-size: 22px;
  }
  
  .auth-card {
    padding: 32px;
    margin: 32px auto;
    max-width: 500px;
  }
  
  .auth-card h2 {
    font-size: 26px;
  }
  
  .form input,
  .form textarea,
  .form select {
    padding: 14px 18px;
    font-size: 16px;
  }
  
  .btn {
    padding: 14px 24px;
    font-size: 15px;
    min-height: 48px;
    max-width: 300px;
  }
  
  .subscription-card {
    padding: 20px;
  }
  
  .subscription-name {
    font-size: 17px;
  }
  
  .subscription-amount {
    font-size: 19px;
  }
  
  .subscription-detail-label,
  .subscription-detail-value {
    font-size: 14px;
  }
  
  .subscription-actions .btn {
    padding: 12px 20px;
    font-size: 14px;
    min-height: 44px;
  }
  
  .table {
    font-size: 14px;
  }
  
  .table th,
  .table td {
    padding: 10px 8px;
  }
  
}

/* Desktop Small (1024px - 1439px) - Revert to single-row table layout */
@media (min-width: 1024px) and (max-width: 1439px) {
  /* Show single-row header and rows, hide two-row layout */
  .category-subscriptions-table .table-header-single {
    display: table-row !important;
  }
  
  .category-subscriptions-table .table-header-two-row {
    display: none !important;
  }
  
  .category-subscriptions-table .subscription-row-single {
    display: table-row !important;
  }
  
  .category-subscriptions-table .subscription-row-two-row {
    display: none !important;
  }
  
  /* Desktop: Show check mark below the date */
  .due-date-cell {
    flex-direction: column !important;
    align-items: center !important;
    gap: 4px !important;
  }
  
  .due-date-cell .passed-indicator {
    order: 1 !important;
  }
  
  .container {
    padding: 0 32px;
    max-width: 1024px;
  }
  
  .navbar .container {
    padding: 16px 32px;
    min-height: 68px;
  }
  
  .brand {
    font-size: 24px;
  }
  
  .brand img {
    height: 36px;
    margin-right: 4px;
  }
  
  .nav-group {
    gap: 20px;
  }
  
  .nav-group a {
    padding: 8px 16px;
    font-size: 16px;
  }
  
  main.container {
    flex: 1;
    padding: 32px 32px;
    padding-top: 80px; /* Keep top padding for fixed navbar */
  }
  
  .centered {
    padding: 32px 32px;
  }
  
  /* 2x2 grid for cards */
  .cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
  
  .card {
    padding: 24px;
  }
  
  .card-title {
    font-size: 16px;
  }
  
  .card-value {
    font-size: 24px;
  }
  
  .auth-card {
    padding: 40px;
    margin: 40px auto;
    max-width: 500px;
  }
  
  .auth-card h2 {
    font-size: 28px;
  }
  
  .form input,
  .form textarea,
  .form select {
    padding: 16px 20px;
    font-size: 16px;
  }
  
  .btn {
    padding: 16px 32px;
    font-size: 16px;
    min-height: 52px;
    max-width: 300px;
  }
  
  .subscription-card {
    padding: 24px;
  }
  
  .subscription-name {
    font-size: 18px;
  }
  
  .subscription-amount {
    font-size: 20px;
  }
  
  .subscription-detail-label,
  .subscription-detail-value {
    font-size: 15px;
  }
  
  .subscription-actions .btn {
    padding: 14px 24px;
    font-size: 15px;
    min-height: 48px;
  }
  
  .table {
    font-size: 15px;
  }
  
  .table th,
  .table td {
    padding: 12px 10px;
  }
  
}

/* Desktop Large (1440px+) - Single-row table layout */
@media (min-width: 1440px) {
  /* Show single-row header and rows, hide two-row layout */
  .category-subscriptions-table .table-header-single {
    display: table-row !important;
  }
  
  .category-subscriptions-table .table-header-two-row {
    display: none !important;
  }
  
  .category-subscriptions-table .subscription-row-single {
    display: table-row !important;
  }
  
  .category-subscriptions-table .subscription-row-two-row {
    display: none !important;
  }
  
  /* Desktop: Show check mark below the date */
  .due-date-cell {
    flex-direction: column !important;
    align-items: center !important;
    gap: 4px !important;
  }
  
  .due-date-cell .passed-indicator {
    order: 1 !important;
  }
  .container {
    padding: 0 40px;
    max-width: 1440px;
  }
  
  .navbar .container {
    padding: 20px 40px;
    min-height: 72px;
  }
  
  .brand {
    font-size: 26px;
  }
  
  .brand img {
    height: 40px;
    margin-right: 4px;
  }
  
  .nav-group {
    gap: 24px;
  }
  
  .nav-group a {
    padding: 10px 20px;
    font-size: 17px;
  }
  
  main.container {
    flex: 1;
    padding: 40px 40px;
    padding-top: 80px; /* Keep top padding for fixed navbar */
  }
  
  .centered {
    padding: 40px 40px;
  }
  
  /* 2x2 grid for cards */
  .cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }
  
  .card {
    padding: 32px;
  }
  
  .card-title {
    font-size: 18px;
  }
  
  .card-value {
    font-size: 28px;
  }
  
  .auth-card {
    padding: 48px;
    margin: 48px auto;
    max-width: 600px;
  }
  
  .auth-card h2 {
    font-size: 32px;
  }
  
  .form input,
  .form textarea,
  .form select {
    padding: 20px 24px;
    font-size: 17px;
  }
  
  .btn {
    padding: 20px 40px;
    font-size: 17px;
    min-height: 56px;
    max-width: 350px;
  }
  
  .subscription-card {
    padding: 32px;
  }
  
  .subscription-name {
    font-size: 20px;
  }
  
  .subscription-amount {
    font-size: 22px;
  }
  
  .subscription-detail-label,
  .subscription-detail-value {
    font-size: 16px;
  }
  
  .subscription-actions .btn {
    padding: 16px 28px;
    font-size: 16px;
    min-height: 52px;
  }
  
  .table {
    font-size: 16px;
  }
  
  .table th,
  .table td {
    padding: 16px 12px;
  }
  
}

/* Mobile Navigation Overlay */
@media (max-width: 767px) {
  .hamburger-menu {
    display: flex;
  }
  
  .nav-group {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: var(--surface);
    border-left: 1px solid var(--border);
    padding: 80px 20px 20px;
    flex-direction: column;
    gap: 12px;
    transition: right 0.3s ease;
    z-index: 1000;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
  }
  
  .nav-group.mobile-menu-open {
    right: 0;
  }
  
  .nav-group a {
    padding: 16px 20px;
    text-align: left;
    border-radius: 12px;
    background: var(--background);
    border: 1px solid var(--border);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    color: var(--fg);
    transition: all 0.2s ease;
    width: 100%;
  }
  
  .nav-group a:hover {
    background: var(--primary);
    color: white;
    transform: translateX(4px);
  }
  
  .theme-toggle {
    position: fixed;
    top: 16px;
    right: 60px;
    z-index: 1001;
  }
}

/* Utility classes */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }

.p-0 { padding: 0; }
.p-1 { padding: 8px; }
.p-2 { padding: 16px; }
.p-3 { padding: 24px; }
.p-4 { padding: 32px; }

.w-full { width: 100%; }
.h-full { height: 100%; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }

.hidden { display: none; }
.block { display: block; }
.inline-block { display: inline-block; }

/* Dark theme adjustments */
[data-theme="dark"] {
  --background: #1a1a1a;
  --surface: #2d2d2d;
  --fg: #ffffff;
  --muted: #888888;
  --border: #788084;
  --primary: #F47600;
}

/* Light theme */
[data-theme="light"] {
  --background: #ffffff;
  --surface: #f8f9fa;
  --fg: #000000;
  --muted: #666666;
  --border: #788084;
  --primary: #F47600;
}

/* Dark theme footer */
[data-theme="dark"] .footer {
  border-top-color: #333;
}

[data-theme="dark"] .copyright {
  color: #888;
}

/* Footer - Fixed at bottom, container just big enough for text */
.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 8px 20px;
  text-align: center;
  border-top: 1px solid var(--border);
  background: var(--bg);
  z-index: 1000;
}

.footer .container {
  text-align: center;
  width: 100%;
}

.copyright {
  font-size: 12px;
  color: var(--text);
  margin: 0;
}

/* Copyright footer - Shows at bottom of page */
.copyright-footer {
  padding: 8px 20px;
  text-align: center;
  background: var(--bg);
  border-top: none;
  font-size: 12px;
  color: var(--text);
  margin-top: auto;
}

.copyright-footer a {
  color: var(--text);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

.copyright-footer a:hover {
  opacity: 0.7;
  text-decoration: underline;
}

/* Social Media Icons - Matching How It Works Style */
.social-media-icons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 0.5rem;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: var(--fg);
  text-decoration: none;
  transition: all 0.3s ease;
  border-radius: 8px;
}

.social-icon img,
.social-icon-img {
  width: 36px;
  height: 36px;
  transition: all 0.3s ease;
  object-fit: contain;
  opacity: 0.9;
  filter: brightness(0);
}

/* Dark theme social icons - invert to white */
[data-theme="dark"] .social-icon img,
[data-theme="dark"] .social-icon-img {
  filter: brightness(0) invert(1);
}

.social-icon:hover {
  transform: translateY(-2px);
}

.social-icon:hover img,
.social-icon:hover .social-icon-img {
  transform: scale(1.1);
  opacity: 1;
}

/* Dark theme hover - maintain white color */
[data-theme="dark"] .social-icon:hover img,
[data-theme="dark"] .social-icon:hover .social-icon-img {
  filter: brightness(0) invert(1);
  opacity: 1;
}

/* Mobile responsive for social icons */
@media (max-width: 768px) {
  .social-media-icons {
    gap: 1.25rem;
  }
  
  .social-icon {
    width: 32px;
    height: 32px;
  }
  
  .social-icon img {
    width: 32px;
    height: 32px;
  }
}

.muted {
  color: var(--muted);
  text-align: center;
  font-size: 18px;
}

h2 {
  font-size: 32px;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 8px;
}

h3 {
  font-size: 24px;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 16px;
}


.danger-section h3 {
  color: #FF8000;
}

.danger-card {
  border-color: #FF8000;
  background: rgba(255, 128, 0, 0.05);
}

.warning-text {
  color: #FF8000;
  font-weight: 500;
  margin-bottom: 20px;
  padding: 16px;
  background: rgba(255, 128, 0, 0.1);
  border-radius: 12px;
  border-left: 4px solid #FF8000;
}

.info-text {
  color: var(--primary);
  font-weight: 500;
  margin-bottom: 20px;
  padding: 16px;
  background: rgba(0, 122, 255, 0.1);
  border-radius: 12px;
  border-left: 4px solid var(--primary);
}


.search-input {
  width: 100%;
  max-width: 400px;
  padding: 16px 20px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 17px;
  background: var(--surface);
  transition: all 0.2s ease;
  font-family: inherit;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
}

/* Color picker */
.color-section {
  display: grid;
  gap: 12px;
  text-align: center;
}

.color-options {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
  margin-bottom: 16px;
  justify-content: center;
  max-width: 300px;
  margin-left: auto;
  margin-right: auto;
}

.color-option {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  border: 3px solid transparent;
  transition: all 0.2s ease;
  position: relative;
}

.color-option:hover {
  transform: scale(1.1);
  border-color: var(--fg);
}

.color-option.selected {
  border-color: var(--fg);
  transform: scale(1.1);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.8);
}

.custom-color-section {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.custom-color-section label {
  margin-bottom: 8px;
  font-size: 14px;
  color: var(--muted);
}

.custom-color-container {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 2px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  transition: all 0.2s ease;
  cursor: pointer;
}

.custom-color-container:hover {
  border-color: var(--primary);
  box-shadow: 0 2px 8px rgba(0, 122, 255, 0.1);
}

.custom-color-container.custom-selected {
  border-color: var(--primary);
  background: rgba(0, 122, 255, 0.05);
  box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.2);
}

.custom-color-input {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  opacity: 0;
  position: absolute;
  z-index: 2;
}

.custom-color-preview {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: #ff0000;
  cursor: pointer;
  transition: all 0.2s ease;
}

.custom-color-container:hover .custom-color-preview {
  transform: scale(1.05);
  border-color: var(--primary);
}

.custom-color-label {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
  cursor: pointer;
}

.custom-color-container.custom-selected .custom-color-label {
  color: var(--primary);
  font-weight: 600;
}

.custom-color-container.custom-selected .custom-color-preview::after {
  content: "✓";
  position: absolute;
  top: -6px;
  right: -6px;
  background: var(--primary);
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: bold;
  border: 2px solid white;
}

/* Service cell with color indicator */
.service-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.service-cell .color-indicator {
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Desktop table color indicators */
.table .service-cell .color-indicator {
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  border-radius: 50%;
  flex-shrink: 0;
}

/* General color indicator for desktop */
.color-indicator {
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Desktop media query to ensure larger dots - Updated 2024 */
@media (min-width: 769px) {
  .color-indicator {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
  }
  
  .service-cell .color-indicator {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
  }
  
  .table .service-cell .color-indicator {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
  }
  
  /* Target the exact HTML structure */
  .table tbody tr td .service-cell .color-indicator {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
  }
  
  /* Nuclear option - target any color-indicator with inline styles */
  .color-indicator[style*="background-color"] {
    width: 20px !important;
    height: 20px !important;
    min-width: 20px !important;
    min-height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
  }
}

/* Hide rows and cards during search */
.subscription-row.hidden,
.subscription-card.hidden {
  display: none;
}

/* Search and filter container */
.search-filter-container {
  display: flex;
  gap: 20px;
  align-items: center;
  margin-bottom: 0; /* Remove bottom margin */
  justify-content: center;
  flex-wrap: wrap;
}

.search-section {
  flex: 1;
  min-width: 200px;
  max-width: 400px;
}

.filter-section {
  display: flex;
  gap: 12px;
  align-items: center;
}

.search-input {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 16px;
  background: var(--surface);
  color: var(--fg);
  transition: all 0.2s ease;
}

.search-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

.filter-section label {
  font-weight: 500;
  color: var(--fg);
  white-space: nowrap;
}

.filter-section select {
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  font-size: 16px;
  color: var(--fg);
  transition: all 0.2s ease;
  min-width: 150px;
}

.filter-section select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

/* Other Reminders Section */
.other-reminders-section {
  margin-top: 40px;
  width: 100%;
  max-width: 1200px;
  margin: 40px auto 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.other-reminders-section h3 {
  text-align: center;
  margin-bottom: 24px;
  font-weight: 400;
  font-size: 3rem;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-theme="dark"] .other-reminders-section h3 {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.other-reminders-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: auto;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto 24px auto;
  padding: 0 12px;
  justify-items: center;
  place-items: center;
  box-sizing: border-box;
  grid-auto-flow: row;
  grid-auto-rows: auto;
}

.reminder-circle {
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: var(--surface);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px var(--shadow);
  position: relative;
  overflow: hidden;
  padding: 2.5rem;
}

.reminder-circle:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px var(--shadow);
}

.reminder-circle:active {
  transform: translateY(-2px) scale(0.98);
}

.reminder-circle-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  z-index: 2;
}

.reminder-type {
  color: var(--muted) !important;
  font-size: 1.1rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  font-weight: 500 !important;
  margin-bottom: 0.75rem !important;
}

.reminder-count {
  font-size: 2.4rem !important;
  font-weight: 600 !important;
  color: var(--fg) !important;
  line-height: 1.2 !important;
}

/* Other Reminders Modal */
.other-reminders-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  animation: fadeIn 0.3s ease-out;
  overflow-y: auto;
}

.other-reminders-modal {
  background: var(--surface);
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease-out;
  overflow: hidden;
}

.other-reminders-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  border-bottom: 1px solid var(--border);
}

.other-reminders-modal-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.other-reminders-modal-close {
  background: none;
  border: none;
  font-size: 32px;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.other-reminders-modal-close:hover {
  background: var(--bg);
  color: var(--fg);
}

.other-reminders-modal-content {
  padding: 24px;
  overflow-y: auto;
}

.other-reminders-modal-content form label {
  display: block;
  margin-bottom: 16px;
  font-weight: 500;
  color: var(--fg);
}

.other-reminders-modal-content form input[type="text"],
.other-reminders-modal-content form input[type="date"],
.other-reminders-modal-content form select {
  width: 100%;
  padding: 14px 18px;
  border: 2px solid var(--border);
  border-radius: 12px;
  font-size: 18px;
  background: var(--surface);
  color: var(--fg);
  margin-top: 8px;
  transition: all 0.2s ease;
  min-height: 52px;
}

/* Make date inputs even more visible */
.other-reminders-modal-content form input[type="date"] {
  font-size: 18px;
  padding: 16px 20px;
  min-height: 56px;
  font-weight: 500;
  cursor: pointer;
}

.other-reminders-modal-content form input[type="date"]:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

/* Mobile: Make date inputs even bigger and more visible */
@media (max-width: 768px) {
  .other-reminders-modal-content form input[type="date"] {
    font-size: 20px;
    padding: 18px 22px;
    min-height: 60px;
    font-weight: 600;
  }
  
  .other-reminders-modal-content form input[type="text"],
  .other-reminders-modal-content form select {
    font-size: 18px;
    padding: 16px 20px;
    min-height: 56px;
  }
}

@media (max-width: 480px) {
  .other-reminders-modal-content form input[type="date"] {
    font-size: 18px;
    padding: 16px 20px;
    min-height: 56px;
  }
  
  .other-reminders-modal-content form input[type="text"],
  .other-reminders-modal-content form select {
    font-size: 16px;
    padding: 14px 18px;
    min-height: 52px;
  }
}

.other-reminders-modal-content form input:focus,
.other-reminders-modal-content form select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

.other-reminders-modal-footer {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  padding: 24px;
  border-top: 1px solid var(--border);
}

/* Ensure delete button text is centered when visible */
.other-reminders-modal-footer #delete-reminder-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  width: auto !important;
  min-width: 120px !important;
}

/* Keep hidden state when display: none is set */
.other-reminders-modal-footer #delete-reminder-btn[style*="display: none"] {
  display: none !important;
}

/* Reminders List Modal */
.reminders-list-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  animation: fadeIn 0.3s ease-out;
  overflow-y: auto;
}

.reminders-list-modal {
  background: var(--surface);
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease-out;
  overflow: hidden;
}

.reminders-list-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  border-bottom: 1px solid var(--border);
}

.reminders-list-modal-title {
  font-size: 24px;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.reminders-list-modal-close {
  background: none;
  border: none;
  font-size: 32px;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.reminders-list-modal-close:hover {
  background: var(--bg);
  color: var(--fg);
}

.reminders-list-modal-content {
  padding: 24px;
  overflow-y: auto;
}

.reminder-item {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-bottom: 12px;
  background: var(--bg);
}

.reminder-item-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.reminder-item-name {
  font-weight: 600;
  color: var(--fg);
  font-size: 18px;
}

.reminder-item-actions {
  display: flex;
  gap: 8px;
}

.reminder-item-details {
  font-size: 14px;
  color: var(--muted);
  margin-top: 8px;
}

/* Desktop - 4 in one row (1025px+) - Match category circles exactly */
@media (min-width: 1025px) {
  .other-reminders-container {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 32px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    grid-auto-flow: row !important;
    grid-auto-rows: auto !important;
  }
  
  .reminder-circle {
    width: 300px !important;
    height: 300px !important;
    min-width: 300px !important;
    min-height: 300px !important;
    max-width: 300px !important;
    max-height: 300px !important;
  }
  
  .reminder-type {
    color: var(--muted) !important;
    font-size: 1.1rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    font-weight: 500 !important;
    margin-bottom: 0.75rem !important;
  }
  
  .reminder-count {
    font-size: 2.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
}

/* Small mobile screens (up to 480px) */
@media (max-width: 480px) {
  .other-reminders-container {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 2rem auto 24px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    box-sizing: border-box !important;
  }
  
  .reminder-circle {
    width: 180px !important;
    height: 180px !important;
    padding: 1.25rem !important;
    border: 3px solid var(--border) !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
  }
  
  .reminder-type {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .reminder-count {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .other-reminders-section h3 {
    font-size: 1.8rem;
  }
}

/* Large mobile screens (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
  .other-reminders-container {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 2rem auto 24px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    box-sizing: border-box !important;
  }
  
  .reminder-circle {
    width: 180px !important;
    height: 180px !important;
    padding: 1.25rem !important;
    border: 3px solid var(--border) !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
  }
  
  .reminder-type {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .reminder-count {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .other-reminders-section h3 {
    font-size: 2rem;
  }
}

/* All mobile screens (up to 768px) - fallback */
@media (max-width: 768px) {
  .other-reminders-container {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 2rem auto 24px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    box-sizing: border-box !important;
  }
  
  .reminder-circle {
    width: 180px !important;
    height: 180px !important;
    padding: 1.25rem !important;
    border: 3px solid var(--border) !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
  }
  
  .reminder-type {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .reminder-count {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .other-reminders-section h3 {
    font-size: 2rem;
  }
}

/* iOS-inspired Calendar */
.calendar-section {
  margin-top: 40px;
  width: 100%;
  max-width: 1200px;
  margin: 40px auto 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.calendar-section h3 {
  text-align: center;
  margin-bottom: 8px;
  font-weight: 400;
  font-size: 3rem;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.calendar-instruction {
  font-size: 1.4rem;
  color: #FF8000;
  margin: 0 0 16px 0;
  font-style: italic;
  text-align: center;
  font-weight: 500;
}

[data-theme="dark"] .calendar-instruction {
  color: #FF8000;
}

/* Mobile: Adjust instruction text */
@media (max-width: 768px) {
  .calendar-instruction {
    font-size: 1.2rem;
    margin-bottom: 12px;
  }
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .calendar-section h3 {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.calendar-container {
  background: var(--surface);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 8px 32px var(--shadow);
  border: 1px solid var(--border);
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

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

.calendar-header h4 {
  font-size: 26px;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.calendar-nav {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: none;
  border-radius: 20px;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.3);
  padding: 0;
  margin: 0;
  line-height: 48px;
  text-align: center;
  vertical-align: middle;
}

.calendar-nav:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  transform: translateY(-2px) scale(1.05);
  box-shadow: 0 12px 32px rgba(244, 118, 0, 0.4);
}

.calendar-grid {
  width: 100%;
}

.calendar-weekdays {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 8px;
}

.weekday {
  text-align: center;
  font-size: 16px;
  font-weight: 600;
  color: var(--muted);
  padding: 12px 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.calendar-days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.calendar-day {
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  font-weight: 600;
  color: var(--fg);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  min-height: 80px;
  background: var(--surface);
  padding: 4px;
  border: 1px solid var(--border);
}


.calendar-day:hover {
  background: var(--bg);
}

.calendar-day.other-month {
  color: var(--muted);
  opacity: 0.4;
}

.calendar-day.other-month .calendar-day-number {
  opacity: 0.5;
  color: var(--muted);
}

.calendar-day.today {
  background: var(--surface);
  color: var(--fg);
  font-weight: 800;
  font-size: 42px;
  border: 3px solid #F47600 !important;
  position: relative;
}

.calendar-day.today::before {
  display: none;
}

[data-theme="dark"] .calendar-day.today::before {
  display: none;
}

.calendar-day.today .calendar-day-number {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  color: #F47600;
}

[data-theme="dark"] .calendar-day.today .calendar-day-number {
  color: #F47600;
}

/* Ensure subscription colors show on today's date */
.calendar-day.today.has-subscription .subscription-donut-chart {
  z-index: 1;
}

.calendar-day.has-subscription {
  background: var(--surface);
}

.calendar-day.has-subscription::before {
  display: none;
}

[data-theme="dark"] .calendar-day.has-subscription::before {
  display: none;
}

.calendar-day.has-subscription:hover::before {
  display: none;
}

.calendar-day.has-subscription:hover {
  transform: scale(1.05);
}

.calendar-day.passed {
  border: 2px solid #28a745 !important;
}

/* Mobile: Ensure passed border works on mobile too */
@media (max-width: 768px) {
  .calendar-day.passed {
    border: 2px solid #28a745 !important;
  }
}

/* Date notes - underline dates with notes */
.calendar-day.has-note .calendar-day-number {
  text-decoration: underline !important;
  text-decoration-color: var(--primary, #F47600) !important;
  text-decoration-thickness: 2px !important;
  text-underline-offset: 3px !important;
  /* Keep existing absolute positioning - don't override */
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  z-index: 2 !important;
}

[data-theme="dark"] .calendar-day.has-note .calendar-day-number {
  text-decoration-color: var(--primary, #F47600) !important;
}

/* Ensure underline is visible even on today or passed dates */
.calendar-day.has-note.today .calendar-day-number,
.calendar-day.has-note.passed .calendar-day-number {
  text-decoration: underline !important;
  text-decoration-color: var(--primary, #F47600) !important;
  /* Preserve today/passed positioning */
  position: absolute !important;
  z-index: 2 !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
}

/* Date Note Modal */
.date-note-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

/* Ensure tooltips appear above modal on mobile */
.custom-tooltip.mobile-tooltip {
  z-index: 10002 !important;
  position: fixed !important;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  /* Smooth transitions for orientation changes */
  transition: left 0.3s ease, top 0.3s ease;
}

/* Mobile and Tablet (up to 1024px) - works in portrait, landscape, and all orientations */
@media (max-width: 1024px), (max-height: 1024px) {
  .custom-tooltip.mobile-tooltip {
    z-index: 10002 !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: fixed !important;
    /* Smooth transitions for orientation changes */
    transition: left 0.3s ease, top 0.3s ease;
  }
}

/* Landscape mode support */
@media (orientation: landscape) and (max-width: 1024px) {
  .custom-tooltip.mobile-tooltip {
    z-index: 10002 !important;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: fixed !important;
    /* Smooth transitions for orientation changes */
    transition: left 0.3s ease, top 0.3s ease;
  }
}

.date-note-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
}

.date-note-modal-content {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  z-index: 1;
}

.date-note-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  border-bottom: 1px solid var(--border);
}

.date-note-subscription-info {
  padding: 12px 20px;
  background: rgba(244, 118, 0, 0.1);
  border-bottom: 1px solid var(--border);
  font-size: 14px;
  color: var(--fg);
  text-align: center;
  font-weight: 500;
}

[data-theme="dark"] .date-note-subscription-info {
  background: rgba(244, 118, 0, 0.15);
}

.date-note-modal-header h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--fg);
}

.date-note-modal-close {
  background: none;
  border: none;
  font-size: 28px;
  line-height: 1;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.date-note-modal-close:hover {
  background: var(--surface);
  color: var(--fg);
}

.date-note-modal-body {
  padding: 20px;
  flex: 1;
  overflow-y: auto;
}

#date-note-textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--fg);
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.5;
  resize: vertical;
  min-height: 120px;
  box-sizing: border-box;
}

#date-note-textarea:focus {
  outline: none;
  border-color: var(--primary, #F47600);
  box-shadow: 0 0 0 3px rgba(244, 118, 0, 0.1);
}

.date-note-modal-footer {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  padding: 20px;
  border-top: 1px solid var(--border);
}

.date-note-modal-footer button {
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  min-height: 44px; /* Better touch target on mobile */
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Ensure button styles work in modal */
.date-note-modal-footer .btn-liquid-primary,
.date-note-modal-footer .btn-liquid-secondary,
.date-note-modal-footer .btn-liquid-danger {
  width: auto; /* Override any width constraints */
}

/* Repeat button active state */
.date-note-modal-footer .btn-liquid-secondary.active {
  background: var(--primary, #F47600);
  color: #fff;
  border-color: var(--primary, #F47600);
}

.date-note-modal-footer .btn-liquid-secondary.active:hover {
  background: var(--primary, #F47600);
  opacity: 0.9;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .date-note-modal {
    padding: 10px;
    align-items: flex-end; /* Align to bottom on mobile for better UX */
  }
  
  .date-note-modal-content {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 16px 16px 0 0; /* Rounded top corners only */
    margin-top: auto; /* Push to bottom */
  }
  
  .date-note-modal-header {
    padding: 14px 16px;
    flex-shrink: 0;
  }
  
  .date-note-modal-header h3 {
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.4;
    padding-right: 8px;
  }
  
  .date-note-modal-close {
    width: 36px;
    height: 36px;
    font-size: 24px;
    flex-shrink: 0;
  }
  
  .date-note-modal-body {
    padding: 16px;
    flex: 1;
    min-height: 0; /* Allow shrinking */
  }
  
  #date-note-textarea {
    padding: 14px;
    font-size: 16px; /* Prevent zoom on iOS */
    min-height: 140px;
    max-height: 50vh;
  }
  
  .date-note-modal-footer {
    padding: 12px 16px;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 8px;
    flex-shrink: 0;
    border-top: 1px solid var(--border);
    justify-content: flex-end;
  }
  
  .date-note-modal-footer button {
    flex: 1;
    min-width: 0;
    padding: 12px 16px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 10px;
    min-height: 44px; /* Good touch target on mobile */
    max-width: none;
  }
  
  /* Organize buttons: Repeat Monthly first, then Save, then Delete (mobile) */
  .date-note-modal-footer .btn-liquid-secondary {
    order: 1;
    flex: 1;
  }
  
  .date-note-modal-footer .btn-liquid-primary {
    order: 2;
    flex: 1.2; /* Slightly larger for primary action */
  }
  
  .date-note-modal-footer .btn-liquid-danger {
    order: 3;
    flex: 1;
    margin-top: 0;
  }
  
  /* If only 2 buttons, make them equal width */
  .date-note-modal-footer:has(button:nth-child(2):last-child) button {
    flex: 1;
  }
}

/* Extra small screens */
@media (max-width: 480px) {
  .date-note-modal {
    padding: 0;
  }
  
  .date-note-modal-content {
    max-height: 95vh;
    border-radius: 20px 20px 0 0;
    border-left: none;
    border-right: none;
    border-bottom: none;
  }
  
  .date-note-modal-header {
    padding: 12px 14px;
  }
  
  .date-note-modal-header h3 {
    font-size: 0.95rem;
    line-height: 1.3;
  }
  
  .date-note-modal-close {
    width: 40px;
    height: 40px;
    font-size: 26px;
  }
  
  .date-note-modal-body {
    padding: 14px;
  }
  
  #date-note-textarea {
    padding: 12px;
    font-size: 16px;
    min-height: 120px;
    max-height: 45vh;
    border-radius: 10px;
  }
  
  .date-note-modal-footer {
    padding: 10px 14px 14px;
    gap: 6px;
  }
  
  .date-note-modal-footer button {
    padding: 11px 14px;
    font-size: 0.9rem;
    border-radius: 10px;
    min-height: 42px; /* Good touch target for small screens */
    flex: 1;
  }
  
  .date-note-modal-footer .btn-liquid-primary {
    flex: 1.2;
  }
}

.calendar-indicators {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 2px;
  margin-top: 2px;
}

.calendar-day-number-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

.calendar-day-number {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
}

.subscription-donut-chart {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  overflow: visible;
  /* Ensure SVG fills container exactly to match faded teal circle */
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  /* Ensure perfect alignment - no transforms that could affect sizing */
}

.subscription-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.subscription-checkmark {
  color: #28a745;
  font-weight: bold;
  font-size: 12px;
  background: rgba(40, 167, 69, 0.1);
  border-radius: 50%;
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #28a745;
  margin: 1px auto 0;
  animation: checkmark-pulse 2s ease-in-out infinite;
}

.calendar-indicators {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  gap: 2px;
  margin-top: 2px;
  margin-bottom: 0;
}

.calendar-day-number {
  display: block;
  font-weight: 600;
  margin: 0;
  color: var(--fg);
  line-height: 1;
}

.calendar-day.today .subscription-dot {
  border-color: black;
}

/* Reminder Toggle Section */
.reminder-section {
  margin: 16px 0;
  padding: 16px;
  background: var(--surface);
  border-radius: 12px;
  border: 1px solid var(--border);
}

.reminder-toggle-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.reminder-toggle-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.ios-toggle-container {
  display: flex;
  align-items: center;
}

.ios-toggle {
  display: none;
}

.ios-toggle-label {
  position: relative;
  display: inline-block;
  width: 51px;
  height: 31px;
  cursor: pointer;
}

.ios-toggle-slider {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  border-radius: 31px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

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

.ios-toggle:checked + .ios-toggle-label .ios-toggle-slider {
  background-color: #34c759;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.ios-toggle:checked + .ios-toggle-label .ios-toggle-slider:before {
  transform: translateX(20px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.ios-toggle-label:hover .ios-toggle-slider {
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1), 0 0 0 4px rgba(52, 199, 89, 0.1);
}

.ios-toggle:checked + .ios-toggle-label:hover .ios-toggle-slider {
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1), 0 0 0 4px rgba(52, 199, 89, 0.2);
}

/* Remove outline from iOS toggle and reminder section on mobile */
@media (max-width: 1000px) {
  /* Remove border/outline from reminder section container */
  .reminder-section {
    border: none !important;
    outline: none !important;
    box-shadow: none !important;
  }
  
  /* Remove all outlines from iOS toggle and its containers */
  .ios-toggle:focus,
  .ios-toggle:focus-visible,
  .ios-toggle-label:focus,
  .ios-toggle-label:focus-visible,
  .ios-toggle-container:focus,
  .ios-toggle-container:focus-visible,
  .reminder-toggle-container:focus,
  .reminder-toggle-container:focus-visible,
  .reminder-section:focus,
  .reminder-section:focus-visible {
    outline: none !important;
    box-shadow: none !important;
  }
  
  /* Remove outline from toggle slider on focus */
  .ios-toggle-label:focus .ios-toggle-slider,
  .ios-toggle-label:focus-visible .ios-toggle-slider,
  .ios-toggle:focus + .ios-toggle-label .ios-toggle-slider,
  .ios-toggle:focus-visible + .ios-toggle-label .ios-toggle-slider {
    outline: none !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  }
  
  /* Remove outline from checked toggle slider on focus */
  .ios-toggle:checked + .ios-toggle-label:focus .ios-toggle-slider,
  .ios-toggle:checked + .ios-toggle-label:focus-visible .ios-toggle-slider,
  .ios-toggle:checked:focus + .ios-toggle-label .ios-toggle-slider,
  .ios-toggle:checked:focus-visible + .ios-toggle-label .ios-toggle-slider {
    outline: none !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  }
  
  /* Remove hover box-shadow outline effect on mobile */
  .ios-toggle-label:hover .ios-toggle-slider {
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  }
  
  .ios-toggle:checked + .ios-toggle-label:hover .ios-toggle-slider {
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1) !important;
  }
  
  /* Remove outline from "remind me before days" number input on mobile */
  .reminder-days-container .number-input:focus,
  .reminder-days-container .number-input:focus-visible,
  .reminder-days-container input.number-input:focus,
  .reminder-days-container input.number-input:focus-visible {
    outline: none !important;
    box-shadow: none !important;
    border-color: var(--border) !important;
  }
}

.reminder-days-container {
  transition: all 0.3s ease;
}

.reminder-days-container label {
  font-size: 0.95rem;
  color: var(--fg);
  opacity: 0.9;
}

/* Dark theme adjustments for toggle */
[data-theme="dark"] .ios-toggle-slider {
  background-color: #48484a;
}

[data-theme="dark"] .ios-toggle-slider:before {
  background-color: #f2f2f7;
}

[data-theme="dark"] .ios-toggle:checked + .ios-toggle-label .ios-toggle-slider {
  background-color: #30d158;
}

/* Reminder Off Styling */
.reminder-off {
  color: var(--muted);
  font-style: italic;
  font-weight: 500;
  opacity: 0.8;
}

/* Responsive */
/* Color Customization Section */
.color-customization {
  margin-top: 2rem;
  padding: 3rem 2.5rem;
  background: var(--surface);
  border-radius: 16px;
  border: 1px solid var(--border);
  box-shadow: none;
}

.color-customization h3 {
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 2rem;
  text-align: center;
  letter-spacing: -0.01em;
}

.color-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  justify-items: stretch;
  align-items: center;
}

.color-picker-item {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 16px 20px;
  background: var(--bg);
  border-radius: 12px;
  border: 2px solid var(--border);
  transition: all 0.2s ease;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.color-picker-item:hover {
  background: var(--surface);
  transform: translateY(-1px);
}

.color-picker-label {
  flex: 1;
  font-size: 1.1rem;
  color: var(--fg);
  margin-right: 20px;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.color-picker-input {
  width: 48px;
  height: 48px;
  border: 3px solid var(--border);
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.2s ease;
  background: transparent;
  position: relative;
  overflow: hidden;
  padding: 0;
  flex-shrink: 0;
  margin-left: auto;
  /* Safari-specific fixes - must be applied first */
  -webkit-appearance: none !important;
  appearance: none !important;
  /* Force consistent sizing */
  min-width: 48px !important;
  min-height: 48px !important;
  max-width: 48px !important;
  max-height: 48px !important;
  /* Remove default Safari styling */
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

.color-picker-input:hover {
  transform: scale(1.1);
}

/* WebKit (Safari, Chrome) color swatch wrapper - comprehensive Safari fixes */
.color-picker-input::-webkit-color-swatch-wrapper {
  padding: 0 !important;
  border-radius: 50% !important;
  border: none !important;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
  position: relative !important;
  display: block !important;
  /* Safari-specific */
  -webkit-appearance: none !important;
  appearance: none !important;
}

/* WebKit (Safari, Chrome) color swatch - comprehensive Safari fixes */
.color-picker-input::-webkit-color-swatch {
  border: none !important;
  border-radius: 50% !important;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  /* Safari-specific */
  -webkit-appearance: none !important;
  appearance: none !important;
  /* Ensure it fills the wrapper */
  min-width: 100% !important;
  min-height: 100% !important;
}

/* Firefox color swatch styling */
.color-picker-input::-moz-color-swatch {
  border: none !important;
  border-radius: 50% !important;
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  box-sizing: border-box !important;
}

/* Safari-specific comprehensive fixes - using multiple selectors for maximum compatibility */
@supports (-webkit-appearance: none) {
  .color-picker-input {
    -webkit-appearance: none !important;
    appearance: none !important;
    background: transparent !important;
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    min-height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
  }
  
  .color-picker-input::-webkit-color-swatch-wrapper {
    padding: 0 !important;
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    -webkit-appearance: none !important;
    appearance: none !important;
  }
  
  .color-picker-input::-webkit-color-swatch {
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    -webkit-appearance: none !important;
    appearance: none !important;
  }
}

/* Additional Safari-specific targeting for older/newer versions */
@media screen and (-webkit-min-device-pixel-ratio: 0) {
  .color-picker-input {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    min-height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
    border-radius: 50% !important;
    overflow: hidden !important;
    padding: 0 !important;
    margin: 0 !important;
    outline: none !important;
  }
  
  .color-picker-input::-webkit-color-swatch-wrapper {
    padding: 0 !important;
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    position: relative !important;
    display: block !important;
  }
  
  .color-picker-input::-webkit-color-swatch {
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
  }
}

/* Safari iOS specific fixes */
@supports (-webkit-touch-callout: none) {
  .color-picker-input {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
    min-height: 48px !important;
    max-width: 48px !important;
    max-height: 48px !important;
    border-radius: 50% !important;
    overflow: hidden !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  
  .color-picker-input::-webkit-color-swatch-wrapper {
    padding: 0 !important;
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    -webkit-appearance: none !important;
  }
  
  .color-picker-input::-webkit-color-swatch {
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    -webkit-appearance: none !important;
  }
}

.analytics-container {
  background: var(--bg);
  min-height: auto;
  padding: 48px 2rem 6rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  box-sizing: border-box;
}

.analytics-header {
  text-align: center;
  margin-bottom: 4rem;
}


.analytics-subtitle {
  font-size: 1.25rem;
  color: var(--muted);
  margin: 0;
  font-weight: 400;
}

/* Base analytics-summary - will be overridden by media queries */
.analytics-summary {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto 32px auto;
  justify-items: center;
  place-items: center;
  justify-content: center;
  align-content: center;
}

.summary-card.card {
  border: 3px solid var(--border) !important;
  border-radius: 24px !important;
  padding: 2.5rem !important;
  background: var(--surface) !important;
  width: 300px !important;
  height: 300px !important;
  box-shadow: 0 4px 12px var(--shadow) !important;
  transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  margin: 0 !important;
}

.summary-card.card:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 6px 20px var(--shadow) !important;
}

.summary-card.card .card-title {
  color: var(--muted) !important;
  font-size: 1.1rem !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  font-weight: 500 !important;
  margin-bottom: 0.75rem !important;
}

.summary-card.card .card-value {
  font-size: 2.4rem !important;
  font-weight: 600 !important;
  color: var(--fg) !important;
  line-height: 1.2 !important;
}

.summary-card.card .card-value.insight-positive {
  color: #ff8c00 !important;
}

.summary-card.card .card-value.insight-negative {
  color: #28a745 !important;
}

.summary-card.card .card-value.insight-neutral {
  color: #F47600 !important;
}

.summary-content {
  flex: 1;
}

.summary-label {
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 400;
}

.summary-value {
  font-size: 3rem;
  font-weight: 400;
  color: var(--fg);
  line-height: 1.2;
}

.chart-container {
  background: var(--surface);
  border-radius: 16px;
  padding: 3rem 2.5rem;
  margin-bottom: 3rem;
  box-shadow: none;
  border: 1px solid var(--border);
}

.chart-header {
  text-align: center;
  margin-bottom: 2rem;
}

.chart-header h2 {
  font-size: 2rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}

.total-spending {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
}

.spending-summary {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.spending-circle {
  width: 260px;
  height: 260px;
  border-radius: 24px;
  background: var(--surface);
  border: 3px solid var(--border);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  box-shadow: 0 4px 12px var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.spending-circle:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 20px var(--shadow);
}

/* Category Circles Container - Match dashboard cards styling exactly */
.dashboard-container .category-circles-container {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: auto;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  margin: 0 auto 24px auto;
  padding: 0 12px;
  justify-items: center;
  place-items: center;
  box-sizing: border-box;
  grid-auto-flow: row;
  grid-auto-rows: auto;
}

/* Desktop - 4 in one row (1025px+) - Match dashboard cards exactly */
@media (min-width: 1025px) {
  .dashboard-container .category-circles-container {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 32px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    grid-auto-flow: row !important;
    grid-auto-rows: auto !important;
  }
  
  .dashboard-container .category-circle {
    width: 300px !important;
    height: 300px !important;
    min-width: 300px !important;
    min-height: 300px !important;
    max-width: 300px !important;
    max-height: 300px !important;
  }
  
  /* Match dashboard card font sizes exactly - category-name matches .card-title (1.1rem), category-total matches .card-value (2.4rem) */
  .dashboard-container .category-circle .category-name,
  .dashboard-container .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-name {
    color: var(--muted) !important;
    font-size: 1.1rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    font-weight: 500 !important;
    margin-bottom: 0.75rem !important;
  }
  
  .dashboard-container .category-circle .category-total,
  .dashboard-container .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-total {
    font-size: 2.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .dashboard-container .category-circle .category-count,
  .dashboard-container .category-circle-content .category-count,
  .dashboard-container .category-circles-container .category-circle .category-count,
  .dashboard-container .category-circles-container .category-circle-content .category-count,
  .dashboard-container .category-circles-container .category-count {
    font-size: 0.9rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    margin-bottom: 0.3rem !important;
  }
}

.category-group {
  display: contents; /* Remove wrapper, make children direct grid items */
}

.dashboard-container .category-circle {
  border-radius: 50% !important;
  padding: 2.5rem !important;
  background: var(--surface) !important;
  width: 300px !important;
  height: 300px !important;
  box-shadow: 0 4px 12px var(--shadow) !important;
  transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  margin: 0 !important;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  box-sizing: border-box;
  border: none !important; /* Border is now SVG donut chart */
  overflow: visible !important;
}

.category-donut-chart {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  overflow: visible;
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  opacity: 0;
  transition: opacity 0.2s ease-in;
}

.category-donut-chart.initialized {
  opacity: 1;
}

.category-circle-content {
  position: relative;
  z-index: 2;
}

.dashboard-container .category-circle:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 6px 20px var(--shadow) !important;
}

.category-circle:active {
  transform: translateY(-2px) scale(1.01);
}

.category-circle-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Mobile styles - only apply below 1025px */
/* REMOVED - This was conflicting. Mobile override at end of file handles this correctly. */

/* OVERRIDE: Wider mobile screens (481px-768px) - Force category font sizes to match cards EXACTLY */
@media (min-width: 481px) and (max-width: 768px) {
  /* Target category-circle-content specifically - this is the actual container in HTML */
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name,
  .dashboard-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circle-content .category-name,
  .category-circle-content .category-name,
  .category-circle .category-circle-content .category-name {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total,
  .dashboard-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circle-content .category-total,
  .category-circle-content .category-total,
  .category-circle .category-circle-content .category-total {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
}

/* OVERRIDE: Mobile landscape - Force category font sizes to match cards EXACTLY */
@media (max-width: 768px) and (orientation: landscape) {
  /* Target category-circle-content specifically - this is the actual container in HTML */
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name,
  .dashboard-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circle-content .category-name,
  .category-circle-content .category-name,
  .category-circle .category-circle-content .category-name {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total,
  .dashboard-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circle-content .category-total,
  .category-circle-content .category-total,
  .category-circle .category-circle-content .category-total {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
}


/* Category Subscriptions Data (hidden, used by modal) */
.category-subscriptions-data {
  display: none;
}

/* Category Modal Overlay */
.category-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  animation: fadeIn 0.3s ease-out;
  overflow-y: auto;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.category-modal {
  background: var(--surface);
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  width: 100%;
  max-width: 1200px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  animation: slideUp 0.3s ease-out;
  overflow: hidden;
}

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

.category-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2rem;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  position: sticky;
  top: 0;
  z-index: 10;
}

.category-modal-title {
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.category-modal-close {
  background: transparent;
  border: none;
  font-size: 2rem;
  color: var(--muted);
  cursor: pointer;
  padding: 0;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.2s ease;
  line-height: 1;
}

.category-modal-close:hover {
  background: var(--bg);
  color: var(--fg);
  transform: none;
}

.category-modal-content {
  padding: 2rem;
  overflow-y: auto;
  flex: 1;
}

.category-modal-content .table-container {
  margin-top: 0;
  overflow-x: auto;
}

.category-modal-content .table {
  margin: 0;
  width: 100%;
  table-layout: fixed;
  border-spacing: 0;
}

.category-modal-content .table th,
.category-modal-content .table td {
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.category-modal-content .table th:first-child,
.category-modal-content .table td:first-child {
  padding-left: 0;
  padding-right: 2rem;
}

.category-modal-content .table th:last-child,
.category-modal-content .table td:last-child {
  padding-right: 0;
  padding-left: 2rem;
}

.category-modal-content .mobile-subscriptions {
  margin-top: 0;
}

/* Mobile responsive for modal */
@media (max-width: 768px) {
  .category-modal-overlay {
    padding: 0;
    align-items: flex-end;
  }
  
  .category-modal {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 24px 24px 0 0;
    animation: slideUpMobile 0.3s ease-out;
  }
  
  @keyframes slideUpMobile {
    from {
      opacity: 0;
      transform: translateY(100%);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .category-modal-header {
    padding: 1.5rem;
  }
  
  .category-modal-title {
    font-size: 1.5rem;
  }
  
  .category-modal-content {
    padding: 1.5rem 1rem;
  }
}

/* Small mobile screens (up to 480px) - Match other reminders */
@media (max-width: 480px) {
  .dashboard-container .category-circles-container {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 2rem auto 24px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    box-sizing: border-box !important;
  }
  
  .category-group {
    display: contents;
  }
  
  .dashboard-container .category-circle {
    padding: 1.25rem !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    border: 3px solid var(--border) !important;
    overflow: visible !important;
  }
  
  .dashboard-container .category-circle .category-name,
  .dashboard-container .category-circle-content .category-name {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .category-circle .category-total,
  .dashboard-container .category-circle-content .category-total {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .dashboard-container .category-circle .category-count,
  .dashboard-container .category-circle-content .category-count {
    font-size: 0.65rem !important;
  }
}

/* Large mobile screens (481px - 768px) - Match card container font sizes exactly */
@media (min-width: 481px) and (max-width: 768px) {
  .dashboard-container .category-circles-container {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 2rem auto 24px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    box-sizing: border-box !important;
  }
  
  .category-group {
    display: contents;
  }
  
  .dashboard-container .category-circle {
    padding: 1.25rem !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    border: 3px solid var(--border) !important;
    overflow: visible !important;
  }
  
  /* CRITICAL: Match card-title font size exactly for wider mobile screens */
  .dashboard-container .category-name,
  .dashboard-container .category-circle .category-name,
  .dashboard-container .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-name,
  .dashboard-container .category-circles-container .category-circle .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  /* CRITICAL: Match card-value font size exactly for wider mobile screens */
  .dashboard-container .category-total,
  .dashboard-container .category-circle .category-total,
  .dashboard-container .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-total,
  .dashboard-container .category-circles-container .category-circle .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .dashboard-container .category-circle .category-count,
  .dashboard-container .category-circle-content .category-count {
    font-size: 0.7rem !important;
  }
}

/* All mobile screens (up to 768px) - fallback */
@media (max-width: 768px) {
  .dashboard-container .category-circles-container {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 2rem auto 24px auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
    box-sizing: border-box !important;
  }
  
  .category-group {
    display: contents;
  }
  
  .dashboard-container .category-circle {
    padding: 1.25rem !important;
    border-radius: 50% !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    border: 3px solid var(--border) !important;
    overflow: visible !important;
  }
  
  /* FORCE category font sizes to match cards on wider mobile screens */
  .dashboard-container .category-circle .category-name,
  .dashboard-container .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name,
  .category-circle-content .category-name {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .category-circle .category-total,
  .dashboard-container .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total,
  .category-circle-content .category-total {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .dashboard-container .category-circle .category-count,
  .dashboard-container .category-circle-content .category-count {
    font-size: 0.7rem !important;
  }
}
  
  .category-donut-chart {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    overflow: visible;
  }
  
  .category-circle-content {
    position: relative;
    z-index: 2;
  }
  
  .dashboard-container .category-circle:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  /* FORCE category font sizes to match cards - target ALL selectors */
  .category-name,
  .category-circle-content .category-name,
  .dashboard-container .category-circle .category-name,
  .dashboard-container .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-name,
  .dashboard-container .category-circles-container .category-circle-content .category-name {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .category-count {
    font-size: 0.7rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.3rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .category-total,
  .category-circle-content .category-total,
  .dashboard-container .category-circle .category-total,
  .dashboard-container .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle .category-circle-content .category-total,
  .dashboard-container .category-circles-container .category-circle-content .category-total {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .category-subscriptions {
    width: 100%;
    padding: 0 0.5rem;
  }
}

.circle-label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.circle-value {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--fg);
  line-height: 1.2;
}

.saved-circle {
  border-color: var(--success);
}

.saved-circle .circle-value.saved-value {
  color: var(--success);
}

.saved-circle.zero-saved {
  opacity: 0.6;
}

.saved-circle.zero-saved .circle-value.saved-value {
  color: var(--muted);
}

/* Dark theme saved amount */
[data-theme="dark"] .saved-circle .circle-value.saved-value {
  color: var(--success);
}

.instruction-text {
  font-size: 1.3rem;
  color: var(--muted);
  margin-bottom: 16px;
  font-style: italic;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
  .spending-summary {
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
  }
  
  .spending-circle {
    width: 180px;
    height: 180px;
    padding: 1.25rem;
    margin: 0;
    border-radius: 20px !important;
  }
  
  .circle-label {
    font-size: 0.75rem;
    margin-bottom: 0.4rem;
  }
  
  .circle-value {
    font-size: 1.4rem;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    white-space: nowrap !important;
    overflow: visible !important;
  }
  
  .instruction-text {
    font-size: 1.1rem;
    text-align: center;
    padding: 0 16px;
  }
  
  /* Mobile legend organization */
  .chartjs-legend {
    flex-direction: column;
    align-items: center;
    gap: 6px;
    margin-top: 16px;
    padding: 0 16px;
  }
  
  .chartjs-legend-item {
    width: 100%;
    max-width: 300px;
    justify-content: flex-start;
    padding: 6px 12px;
    margin: 2px 0;
  }
  
  .chartjs-legend-text {
    font-size: 13px;
  }
  
  .chartjs-legend-color {
    width: 10px;
    height: 10px;
  }
  
  /* Mobile custom legend */
  .custom-legend {
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    padding: 0 16px;
  }
  
  .custom-legend-item {
    width: 100%;
    max-width: 280px;
    justify-content: flex-start;
    padding: 6px 10px;
  }
  
  .custom-legend-text {
    font-size: 13px;
  }
  
  .custom-legend-color {
    width: 12px;
    height: 12px;
  }
}

.savings-display {
  background: var(--success);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  margin-top: 16px;
  text-align: center;
  box-shadow: 0 2px 8px rgba(52, 199, 89, 0.3);
}

.savings-amount {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 4px;
}

.savings-description {
  font-size: 0.9rem;
  opacity: 0.9;
}

/* Dark theme savings display */
[data-theme="dark"] .savings-display {
  background: var(--success);
  box-shadow: 0 2px 8px rgba(48, 209, 88, 0.4);
}

.chart-period {
  font-size: 1.5rem;
  color: var(--muted);
}

.chart-wrapper {
  position: relative;
  height: 800px;
  width: 100%;
}

/* Organize legend under pie chart */
.chartjs-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  padding: 0 20px;
}

.chartjs-legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 4px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: background-color 0.2s ease;
}

.chartjs-legend-item:hover {
  background-color: transparent;
}

/* Custom legend donut indicators */
.custom-legend-color.donut-indicator {
  display: inline-block !important;
  width: 20px !important;
  height: 20px !important;
  border-radius: 50% !important;
  border: 4px solid !important;
  background: transparent !important;
  position: relative !important;
  margin-right: 10px !important;
  vertical-align: middle !important;
  box-sizing: border-box !important;
  flex-shrink: 0 !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

/* Donut hole element - center hole */
.donut-hole {
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  width: 7px !important;
  height: 7px !important;
  border-radius: 50% !important;
  background: var(--bg) !important;
  z-index: 2 !important;
  pointer-events: none !important;
  box-sizing: border-box !important;
}

/* Legend item hover animations */
.chartjs-legend-item {
  transition: all 0.2s ease !important;
  padding: 4px 8px !important;
  border-radius: 6px !important;
  display: flex !important;
  align-items: center !important;
}

.chartjs-legend-item:hover {
  background-color: transparent !important;
  transform: none !important;
}

.chartjs-legend-item:hover .custom-legend-color.donut-indicator {
  transform: none !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2) !important;
}

.chartjs-legend-item:active {
  transform: translateY(0) !important;
}

.chartjs-legend-item:active .custom-legend-color.donut-indicator {
  transform: scale(1) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2) !important;
}

/* Prevent hover animation when clicking */
.chartjs-legend-item.clicked .custom-legend-color.donut-indicator {
  transform: scale(1) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2) !important;
  transition: none !important;
}

.chartjs-legend-item.clicked:hover .custom-legend-color.donut-indicator {
  transform: scale(1) !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2) !important;
}

.chartjs-legend-text {
  font-size: 18px;
  font-weight: 600;
  white-space: nowrap;
}

/* Mobile font size for legend text */
@media (max-width: 768px) {
  .chartjs-legend-text {
    font-size: 16px;
  }
}

/* Custom organized legend */
.custom-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding: 0 20px;
}

.custom-legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  background: rgba(0, 0, 0, 0.02);
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.custom-legend-item:hover {
  background: rgba(0, 122, 255, 0.1);
  border-color: rgba(0, 122, 255, 0.3);
  transform: translateY(-1px);
}

.custom-legend-color {
  width: 14px !important;
  height: 14px !important;
  border-radius: 50% !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  position: relative !important;
  box-sizing: border-box !important;
  overflow: visible !important;
  background: transparent !important;
  border: 3px solid !important;
  border-color: inherit !important;
}

/* Create donut shape - remove background, use border only */
.custom-legend-color::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--bg);
  z-index: 2;
  pointer-events: none;
}

.custom-legend-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--fg);
  white-space: nowrap;
}




.analytics-insights {
  margin-bottom: 30px;
}

.analytics-insights h3 {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 16px;
}

.insights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
}

.insight-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  display: flex;
  align-items: center;
  box-shadow: none;
  border: 1px solid var(--border);
}

.insight-content {
  flex: 1;
}

.insight-title {
  font-size: 0.875rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 400;
}

.insight-value {
  font-size: 2rem;
  font-weight: 400;
  color: var(--fg);
  line-height: 1.2;
}

.insight-value.insight-positive {
  color: #ff8c00;
}

.insight-value.insight-negative {
  color: #28a745;
}

@media (max-width: 768px) {
  /* iOS-Inspired Mobile Design System */
  
  /* Dashboard container optimization */
  .dashboard-container {
    padding: 3rem 1.5rem !important;
    gap: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  
  /* Dashboard and analytics titles inherit from .section-title - no overrides needed */
  
  .dashboard-container h2:not(.section-title),
  .analytics-header h2:not(.section-title) {
    font-size: 24px !important;
    margin-bottom: 0;
    text-align: center;
    font-weight: 700 !important;
    letter-spacing: -0.02em;
  }
  
  /* Base container - iOS safe area inspired */
  .container {
    padding: 16px 20px;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    margin: 0 auto;
  }
  
  /* iOS-Inspired Centered Layout */
  .centered {
    padding: 20px;
    gap: 24px;
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 160px);
  }
  
  /* Account Page Mobile - Single Column */
  .account-page {
    max-width: 100% !important;
    padding: 20px 16px;
  }
  
  .account-page .account-grid {
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 20px;
  }
  
  .account-page {
    padding: 3rem 1.5rem !important;
  }
  
  .account-page h2 {
    font-size: 2.25rem !important;
    margin-bottom: 0 !important;
  }
  
  .dashboard-container h2,
  .contact-page h2,
  .upgrade-title {
    margin-bottom: 0 !important;
  }
  
  .account-page .account-grid {
    gap: 2rem;
  }
  
  .account-page .auth-card {
    padding: 2.5rem 2rem;
    margin: 0; /* Remove margin since grid handles spacing */
  }
  
  .account-page h3 {
    text-align: left;
    font-size: 1.35rem;
    margin-bottom: 1.5rem;
    font-weight: 400;
  }
  
  .account-page .centered h2 {
    text-align: center;
    font-size: 2.25rem;
    margin-bottom: 2rem;
    font-weight: 400;
    letter-spacing: -0.02em;
  }
  
  /* iOS-Inspired Cards */
  .auth-card {
    padding: 2.5rem 2rem;
    min-height: auto;
    border-radius: 0;
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: none;
    backdrop-filter: none;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
  }
  
  /* iOS-Inspired Forms */
  .form {
    gap: 20px;
    max-width: 100%;
    width: 100%;
  }
  
  .form label {
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--fg);
    display: block;
  }
  
  .form input,
  .form textarea,
  .form select {
    font-size: 17px;
    padding: 16px 20px;
    border-radius: 16px;
    border: 2px solid var(--border);
    background: var(--background);
    color: var(--fg);
    width: 100%;
    box-sizing: border-box;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    appearance: none;
  }
  
  .form input:focus,
  .form textarea:focus,
  .form select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
    outline: none;
  }
  
  /* iOS-Inspired Buttons */
  .btn {
    font-size: 17px;
    font-weight: 600;
    padding: 16px 32px;
    border-radius: 50px;
    min-height: 56px;
    touch-action: manipulation;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
  }
  
  .btn-primary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .btn-primary:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
    border-color: #F47600;
    color: white;
  }
  
  .btn-secondary {
    background: var(--surface);
    color: var(--fg);
    border: 2px solid var(--border);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  }
  
  .btn-secondary:hover {
    background: var(--background);
    border-color: #F47600;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  }
  
  .hero h1,
  .hero .hero-title {
    font-size: 4rem;
    line-height: 1.2;
    font-weight: 400;
    letter-spacing: -0.02em;
  }
  
  .hero p,
  .hero .hero-description {
    font-size: 1.5rem;
    line-height: 1.4;
    font-weight: 400;
  }
  
  .dashboard-container .cards {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
    margin-bottom: 20px !important;
    padding: 0 4px !important;
    justify-items: center !important;
  }
  
  .dashboard-container .card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    margin: 0 !important;
    width: 180px !important;
    height: 180px !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  }
  
  .dashboard-container .card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  .dashboard-container .card-title {
    font-size: 0.75rem !important;
    margin-bottom: 0.4rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .dashboard-container .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  /* Hide table on mobile, use card layout instead */
  .table-container {
    display: none;
  }
  
  /* Mobile Subscription Cards - Smaller */
  .subscription-card {
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    background: var(--surface);
    border: 1px solid var(--border);
    width: 100%;
    box-sizing: border-box;
  }
  
  .subscription-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 8px;
  }
  
  .subscription-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--fg);
    flex: 1;
    min-width: 0;
  }
  
  .subscription-amount {
    font-size: 18px;
    font-weight: 800;
    color: var(--primary);
    text-shadow: 0 2px 4px rgba(0, 122, 255, 0.2);
  }
  
  .subscription-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
  }
  
  .subscription-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
  }
  
  .subscription-detail:last-child {
    border-bottom: none;
  }
  
  .subscription-detail-label {
    font-size: 13px;
    color: var(--muted);
    font-weight: 600;
  }
  
  .subscription-detail-value {
    font-size: 13px;
    font-weight: 700;
    color: var(--fg);
  }
  
  /* Mobile Action Buttons - Smaller */
  .subscription-actions {
    display: flex;
    gap: 8px;
    margin-top: 16px;
  }
  
  .subscription-actions .btn {
    flex: 1;
    padding: 14px 20px;
    font-size: 16px;
    border-radius: 50px;
    font-weight: 600;
    min-height: 48px;
    transition: all 0.3s ease;
    margin: 0;
    max-width: none;
    border: 2px solid transparent;
  }
  
  .subscription-actions .btn-secondary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .subscription-actions .btn-secondary:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  }
  
  .subscription-actions .btn-danger {
    background: #FF8000;
    color: white;
    box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  }
  
  .subscription-actions .btn-danger:hover {
    background: #FF8000;
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
  }
  
  .btn-edit {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    min-height: 48px;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .btn-edit:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  }
  
  .btn-delete {
    background: #FF8000;
    color: white;
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    min-height: 48px;
    box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  }
  
  .btn-delete:hover {
    background: #FF8000;
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
  }
  
  /* Mobile-friendly subscription cards */
  .subscription-card {
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    background: var(--surface);
    border: 1px solid var(--border);
    max-width: 100%;
    overflow: hidden;
  }
  
  .subscription-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 20px;
  }
  
  .subscription-name {
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--fg);
    word-wrap: break-word;
  }
  
  .subscription-amount {
    font-size: 24px;
    font-weight: 800;
    color: var(--primary);
    text-shadow: 0 2px 4px rgba(0, 122, 255, 0.2);
  }
  
  .subscription-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
  }
  
  .subscription-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
  }
  
  .subscription-detail:last-child {
    border-bottom: none;
  }
  
  .subscription-detail-label {
    font-size: 16px;
    color: var(--muted);
    font-weight: 600;
  }
  
  .subscription-detail-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--fg);
  }
  
  /* Mobile action buttons */
  .subscription-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
  }
  
  .subscription-actions .btn {
    flex: 1;
    padding: 14px 20px;
    font-size: 16px;
    border-radius: 50px;
    font-weight: 600;
    min-height: 48px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
  }
  
  .subscription-actions .btn-secondary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .subscription-actions .btn-secondary:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  }
  
  .subscription-actions .btn-danger {
    background: #FF8000;
    color: white;
    box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  }
  
  .subscription-actions .btn-danger:hover {
    background: #FF8000;
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
  }
  
  .btn-edit {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    min-height: 48px;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .btn-edit:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  }
  
  .btn-delete {
    background: #FF8000;
    color: white;
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    min-height: 48px;
    box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  }
  
  .btn-delete:hover {
    background: #FF8000;
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
  }
  
  
  .card-title {
    font-size: 18px;
    line-height: 1.3;
  }
  
  /* iOS-Inspired Mobile Navigation */
  .navbar .container {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    min-height: 72px;
  }
  
  .brand {
    font-size: 20px;
    font-weight: 700;
    flex-shrink: 0;
    color: var(--fg);
    display: flex;
    align-items: center;
  }
  
  .brand img {
    height: 28px;
    margin-right: 2px;
  }
  
  /* iOS-Inspired Hamburger Menu */
  .hamburger-menu {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    width: 32px;
    height: 32px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    flex-shrink: 0;
    border-radius: 8px;
    transition: background-color 0.3s ease;
  }
  
  .hamburger-menu:hover {
    background: rgba(0, 0, 0, 0.05);
  }
  
  .hamburger-menu span {
    width: 100%;
    height: 2px;
    background: var(--fg);
    border-radius: 1px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
  }
  
  .hamburger-menu.hamburger-active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
  }
  
  .hamburger-menu.hamburger-active span:nth-child(2) {
    opacity: 0;
    transform: scale(0);
  }
  
  .hamburger-menu.hamburger-active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
  }
  
  /* iOS-Inspired Mobile Navigation Menu */
  .nav-group {
    position: fixed;
    top: 0;
    right: -100%;
    width: 320px;
    height: 100vh;
    background: var(--surface);
    border-left: 1px solid var(--border);
    padding: 100px 24px 24px;
    flex-direction: column;
    gap: 12px;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    box-shadow: -8px 0 32px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(20px);
  }
  
  .nav-group.mobile-menu-open {
    right: 0;
  }
  
  /* Hamburger Menu Buttons - All Same Size */
  .nav-group a {
    padding: 16px 20px;
    text-align: center;
    border-radius: 12px;
    background: var(--background);
    border: 1px solid var(--border);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    color: var(--fg);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    min-height: 48px; /* Same height for all buttons */
    width: 100%; /* Same width for all buttons */
  }
  
  .nav-group a:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.3);
    border-color: var(--primary);
  }
  
  /* Theme Toggle - iOS Toggle Style */
  .theme-toggle.ios-toggle {
    position: relative !important;
    top: auto !important;
    right: auto !important;
    transform: none !important;
    z-index: 1001;
    width: auto !important;
    min-width: 91px !important;
    height: 31px !important;
    background: transparent !important;
    border: none !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    transition: none !important;
    padding: 0 !important;
    margin: 0 !important;
    margin-right: 12px !important;
    flex-shrink: 0 !important;
    contain: layout style paint !important;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
  }
  
  .theme-toggle.ios-toggle:hover {
    transform: none !important;
  }
  
  .theme-toggle.ios-toggle:active {
    transform: none !important;
  }
  
  .theme-toggle.ios-toggle .toggle-track {
    width: 51px;
    height: 31px;
  }
  
  .theme-toggle.ios-toggle .toggle-icon {
    width: 20px;
    height: 20px;
    position: relative;
  }
  
  .theme-toggle.ios-toggle .toggle-icon svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
  }
  
  .theme-toggle.ios-toggle .toggle-icon-sun {
    margin-right: 0;
  }
  
  .theme-toggle.ios-toggle .toggle-icon-moon {
    margin-left: 0;
  }
  
  .theme-toggle.ios-toggle .toggle-thumb {
    width: 27px;
    height: 27px;
    will-change: transform;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  [data-theme="dark"] .theme-toggle.ios-toggle .toggle-thumb {
    transform: translateX(20px);
  }
  
  .theme-toggle.ios-toggle:active .toggle-thumb {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }
  
  [data-theme="dark"] .theme-toggle.ios-toggle:active .toggle-thumb {
    transform: translateX(20px) scale(0.98);
    transition: transform 0.1s ease;
  }
  
  /* Login page mobile optimization */
  .auth-card {
    padding: 32px 24px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(20px);
    background: var(--surface);
    border: 1px solid var(--border);
    margin: 40px auto;
    max-width: 400px;
  }
  
  /* Login page spacing */
  .centered {
    padding: 20px 16px;
    gap: 20px;
    max-width: calc(100vw - 32px);
    margin: 0 auto;
    min-height: calc(100vh - 120px);
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  
  .auth-card h2 {
    font-size: 28px;
    text-align: center;
    margin-bottom: 32px;
    font-weight: 700;
    color: var(--fg);
  }
  
  .form {
    gap: 20px;
    max-width: 100%;
  }
  
  .form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--fg);
    font-size: 16px;
  }
  
  .form input,
  .form textarea,
  .form select {
    font-size: 16px;
    padding: 16px 20px;
    border-radius: 16px;
    border: 2px solid var(--border);
    background: var(--background);
    color: var(--fg);
    transition: all 0.2s ease;
    width: 100%;
    box-sizing: border-box;
  }
  
  .form input:focus,
  .form textarea:focus,
  .form select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
    transform: translateY(-1px);
  }
  
  .btn {
    font-size: 18px;
    padding: 18px 32px;
    border-radius: 50px;
    width: 100%;
    max-width: none;
    font-weight: 600;
    transition: all 0.2s ease;
    border: 2px solid transparent;
    cursor: pointer;
  }
  
  .btn-primary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .btn-primary:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
    border-color: #F47600;
    color: white;
  }
  
  .btn-secondary {
    background: transparent;
    color: var(--fg);
    border: 2px solid var(--border);
  }
  
  .btn-secondary:hover {
    background: var(--background);
    border-color: #F47600;
    transform: translateY(-1px);
  }
  
  /* iOS-inspired login/register toggle */
  .auth-toggle {
    display: flex;
    background: var(--background);
    border-radius: 16px;
    padding: 4px;
    margin-bottom: 24px;
    border: 1px solid var(--border);
  }
  
  .auth-toggle a {
    flex: 1;
    padding: 12px 16px;
    text-align: center;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
    color: var(--muted);
  }
  
  .auth-toggle a.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
  }
  
  /* Subscription cards mobile */
  .subscription-card {
    padding: 16px;
    border-radius: 16px;
  }
  
  .subscription-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  
  .subscription-amount {
    font-size: 20px;
    align-self: flex-end;
  }
  
  /* Contact form mobile */
  .contact-form-card {
    padding: 20px;
  }
  
  .contact-intro h3 {
    font-size: 24px;
  }
  
  /* Theme toggle mobile */
  .theme-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    width: 56px;
    height: 56px;
    border-radius: 28px;
    background: var(--primary);
    border: none;
    box-shadow: 0 4px 16px rgba(0, 122, 255, 0.3);
  }
  
  .theme-icon {
    font-size: 24px;
  }
  
  .table {
    font-size: 14px;
    overflow-x: auto;
  }
}

/* Additional mobile optimizations for smaller screens */
@media (max-width: 480px) {
  .container {
    padding: 8px;
  }
  
  .centered {
    padding: 8px;
    max-width: calc(100vw - 16px);
  }
  
  .auth-card {
    padding: 16px;
  }
  
  .form input,
  .form textarea,
  .form select {
    font-size: 16px; /* Prevent zoom on iOS */
    padding: 14px 16px;
  }
  
  .btn {
    padding: 16px 24px;
    font-size: 16px;
  }
  
  .hero h1,
  .hero .hero-title {
    font-size: 2.25rem !important;
    font-weight: 400 !important;
    letter-spacing: -0.02em !important;
    line-height: 1.2 !important;
  }
  
  .hero p,
  .hero .hero-description {
    font-size: 1.5rem !important;
    line-height: 1.4 !important;
    font-weight: 400 !important;
  }
  
  .navbar .brand {
    font-size: 20px;
  }
  
  .subscription-card {
    padding: 12px;
  }
  
  .subscription-amount {
    font-size: 18px;
  }
  
  .contact-form-card {
    padding: 16px;
  }
  
  .contact-intro h3 {
    font-size: 22px;
  }
  
  /* Make sure text is readable on small screens */
  .info-text {
    font-size: 14px;
    line-height: 1.4;
  }
  
  /* Form help text styling */
  .form-text {
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
    display: block;
    line-height: 1.3;
  }
  
  .warning-text {
    font-size: 14px;
    line-height: 1.4;
  }
}
  
  .table th, .table td {
    padding: 12px 8px;
    min-width: 80px;
  }
  
  .auth-card {
    padding: 24px;
    min-height: 150px;
  }
  
  /* Analytics mobile styling */
  .analytics-container {
    padding: 3rem 1.5rem !important;
    overflow: visible !important;
    min-height: auto !important;
    background: transparent !important;
  }
  
  .analytics-header {
    margin-bottom: 3rem !important;
  }
  
  .analytics-subtitle {
    font-size: 1.1rem !important;
    font-weight: 400 !important;
  }
  
  .summary-label {
    font-size: 0.875rem !important;
  }
  
  .chart-period {
    font-size: 1rem !important;
  }
  
  .insight-title {
    font-size: 1rem !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
    margin-bottom: 20px !important;
    padding: 0 4px !important;
    width: 100% !important;
    justify-items: center !important;
  }
  
  .summary-card.card {
    padding: 1.25rem !important;
    border-radius: 20px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    border: 3px solid var(--border) !important;
    background: var(--surface) !important;
    width: 180px !important;
    height: 180px !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
  }
  
  .summary-card.card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  .summary-card.card .card-title {
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    color: var(--muted) !important;
    margin-bottom: 0.4rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
  }
  
  .summary-card.card .card-value {
    font-size: 1.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .summary-card.card .card-value.insight-positive {
    color: #ff8c00 !important;
  }
  
  .summary-card.card .card-value.insight-negative {
    color: #28a745 !important;
  }
  
  .summary-card.card .card-value.insight-neutral {
    color: #F47600 !important;
  }
  
  .summary-card {
    padding: 2.5rem 2rem !important;
    border-radius: 16px !important;
    box-shadow: none !important;
  }
  
  .summary-value {
    font-size: 2.5rem !important;
    font-weight: 400 !important;
  }
  
  .chart-container {
    padding: 1.5rem 1rem !important;
    margin: 0 auto 2rem auto !important;
    border-radius: 16px !important;
    box-shadow: none !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .chart-wrapper {
    height: 400px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 8px auto !important;
  }
  
  .chart-header {
    text-align: center !important;
    width: 100% !important;
    margin: 0 auto 1rem auto !important;
  }
  
  .chart-header h2 {
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    margin-bottom: 8px !important;
    text-align: center !important;
  }
  
  .color-picker-grid {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 12px !important;
    justify-content: center !important;
    max-width: 100% !important;
    margin: 0 !important;
  }
  
  .color-picker-item {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 12px 16px !important;
    background: var(--bg) !important;
    border: 0.5px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 20px !important;
    width: auto !important;
    min-width: 100px !important;
    max-width: 140px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
    position: relative !important;
    overflow: hidden !important;
    gap: 8px !important;
  }
  
  .color-picker-item::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05)) !important;
    opacity: 0 !important;
    transition: opacity 0.3s ease !important;
    pointer-events: none !important;
  }
  
  .color-picker-item:hover {
    background: var(--surface) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1) !important;
    border-color: rgba(0, 0, 0, 0.1) !important;
  }
  
  .color-picker-item:hover::before {
    opacity: 1 !important;
  }
  
  .color-picker-item:active {
    transform: translateY(-1px) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
  }
  
  .color-picker-label {
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    margin: 0 !important;
    text-align: center !important;
    color: var(--fg) !important;
    letter-spacing: -0.01em !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
  }
  
  .color-picker-input {
    width: 20px !important;
    height: 20px !important;
    border-radius: 50% !important;
    border: 2px solid rgba(255, 255, 255, 0.9) !important;
    cursor: pointer !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
    position: relative !important;
    overflow: hidden !important;
    flex-shrink: 0 !important;
    /* Safari-specific fixes for mobile */
    -webkit-appearance: none !important;
    appearance: none !important;
    min-width: 20px !important;
    min-height: 20px !important;
    max-width: 20px !important;
    max-height: 20px !important;
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
  }
  
  /* Safari mobile color swatch fixes - comprehensive */
  .color-picker-input::-webkit-color-swatch-wrapper {
    padding: 0 !important;
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
    position: relative !important;
    display: block !important;
    -webkit-appearance: none !important;
    appearance: none !important;
  }
  
  .color-picker-input::-webkit-color-swatch {
    border: none !important;
    border-radius: 50% !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    min-width: 100% !important;
    min-height: 100% !important;
  }
  
  .color-picker-input::before {
    content: '' !important;
    position: absolute !important;
    top: -1px !important;
    left: -1px !important;
    right: -1px !important;
    bottom: -1px !important;
    background: linear-gradient(45deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.1)) !important;
    border-radius: 50% !important;
    opacity: 0 !important;
    transition: opacity 0.3s ease !important;
    pointer-events: none !important;
  }
  
  .color-picker-input:hover {
    transform: scale(1.2) !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2) !important;
    border-color: rgba(255, 255, 255, 1) !important;
  }
  
  .color-picker-input:hover::before {
    opacity: 1 !important;
  }
  
  .color-picker-input:active {
    transform: scale(1.1) !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25) !important;
  }
  
  .reminder-section {
    margin: 12px 0;
    padding: 12px;
  }
  
  .reminder-toggle-container {
    margin-bottom: 8px;
  }
  
  .reminder-toggle-label {
    font-size: 0.95rem;
  }
  
  .ios-toggle-label {
    width: 47px;
    height: 29px;
  }
  
  .ios-toggle-slider:before {
    height: 25px;
    width: 25px;
  }
  
  .ios-toggle:checked + .ios-toggle-label .ios-toggle-slider:before {
    transform: translateX(18px);
  }
  
  .hint-bar {
    padding: 12px;
    gap: 8px;
  }
  
  .hint-icon {
    font-size: 18px;
  }
  
  .hint-title {
    font-size: 14px;
  }
  
  .hint-text {
    font-size: 13px;
  }
  
  .hint-label {
    font-size: 14px;
  }
  
  .hint-label input {
    font-size: 16px; /* Prevent zoom on iOS */
  }
  
  /* Mobile number input adjustments */
  .number-input {
    padding-right: 40px;
  }
  
  .number-arrows {
    right: 6px;
  }
  
  .arrow-btn {
    width: 18px;
    height: 14px;
    font-size: 10px;
  }
  
  /* Mobile navbar theme toggle */
  nav .theme-toggle.ios-toggle {
    width: auto !important;
    min-width: 91px !important;
    height: 31px !important;
    margin-right: 12px !important;
    margin-left: 0 !important;
    position: relative !important;
    transform: none !important;
    padding: 0 !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    align-self: center !important;
    flex-shrink: 0 !important;
    contain: layout style paint !important;
    transition: none !important;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
  }
  
  nav .theme-toggle.ios-toggle:active {
    transform: none !important;
  }
  
  .toggle-track {
    width: 51px;
    height: 31px;
  }
  
  .toggle-icon {
    width: 20px;
    height: 20px;
    position: relative;
  }
  
  .toggle-icon svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
  }
  
  .toggle-icon-sun {
    margin-right: 0;
  }
  
  .toggle-icon-moon {
    margin-left: 0;
  }
  
  .toggle-thumb {
    width: 27px;
    height: 27px;
    will-change: transform;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  [data-theme="dark"] .toggle-thumb {
    transform: translateX(20px);
  }
  
  nav .theme-toggle.ios-toggle:active .toggle-thumb {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }
  
  [data-theme="dark"] nav .theme-toggle.ios-toggle:active .toggle-thumb {
    transform: translateX(20px) scale(0.98);
    transition: transform 0.1s ease;
  }
  
  .nav-group a {
    margin-left: 16px;
  }
  
  .nav-group a:first-child {
    margin-left: 0;
  }
  
  .calendar-section {
    margin-top: 30px;
  }
  
  .calendar-container {
    padding: 12px;
  }
  
  .calendar-header h4 {
    font-size: 16px;
  }
  
  .calendar-nav {
    width: 40px;
    height: 40px;
    border-radius: 16px;
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border: none;
    color: white;
    font-size: 28px;
    font-weight: bold;
    box-shadow: 0 6px 20px rgba(244, 118, 0, 0.3);
    line-height: 40px;
    padding: 0;
    margin: 0;
    text-align: center;
  }
  
  .calendar-day {
    min-height: 32px;
    font-size: 12px;
  }
  
  .calendar-day.today {
    font-size: 13px;
  }
  
  .weekday {
    font-size: 10px;
    padding: 6px 1px;
  }
  
  .calendar-section h3 {
    font-size: 2.25rem !important;
    font-weight: 400 !important;
    letter-spacing: -0.02em;
  }
  
  .calendar-header h4 {
    font-size: 22px;
  }
  
  .weekday {
    font-size: 14px;
    padding: 10px 4px;
  }
  
  /* Mobile color options adjustments */
  .color-options {
    grid-template-columns: repeat(5, 1fr);
    max-width: 250px;
    gap: 16px;
  }
  
  .color-option {
    width: 36px;
    height: 36px;
  }
}

/* Main page scroll prevention - only when body has main-page class */
body.main-page {
  height: 100vh;
  overflow: hidden;
  margin: 0;
  padding: 0;
  background: transparent;
}

/* Squarespace-Inspired Landing Page - Clean & Modern */
.landing-page {
  min-height: 100vh;
  background: transparent;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: var(--fg);
  line-height: 1.6;
  overflow-x: hidden !important;
  max-width: 100vw !important;
  width: 100%;
}

/* Hero Section - Clean Squarespace Style */
.hero {
  min-height: 85vh;
  display: flex;
  align-items: center;
  padding: 8rem 2rem;
  background: transparent !important;
  position: relative;
  overflow: hidden;
}

/* Hero Background Logos - Removed per user request */

/* Desktop only: Add more spacing between header and hero content */
@media (min-width: 769px) {
  .hero {
    padding-top: 14rem;
  }
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 4rem;
  align-items: center;
  width: 100%;
  text-align: center;
  position: relative;
  z-index: 1;
  background: transparent !important;
}

.hero-content {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 800px;
  background: transparent !important;
}

.hero-title {
  font-size: 4rem;
  font-weight: 400;
  line-height: 1.2;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 2rem;
  letter-spacing: -0.02em;
  width: 100%;
  text-align: center;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .hero-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.highlight {
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 400;
}

/* Dark theme - use white instead of black for highlight */
[data-theme="dark"] .highlight {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.5rem;
  line-height: 1.4;
  color: var(--muted);
  margin-bottom: 3rem;
  font-weight: 400;
  max-width: 700px;
  text-align: center;
  width: 100%;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  margin-bottom: 4rem;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: 100%;
}

/* Hero Button Styles - Matching Take Control Today Button */
.hero-actions .btn-primary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  padding: 1rem 2rem;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
}

.hero-actions .btn-primary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  border-color: #F47600;
  color: white;
}

.hero-actions .btn-secondary {
  background: transparent;
  color: var(--fg);
  border: 2px solid var(--border);
  padding: 1rem 2rem;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
}

.hero-actions .btn-secondary:hover {
  background: var(--surface);
  border-color: #F47600;
  transform: translateY(-2px);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4rem;
  padding-top: 3rem;
  border-top: none;
  width: 100%;
  align-items: start;
}

.stat {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.stat-number {
  font-size: 3rem;
  font-weight: 400;
  color: #F47600;
  margin-bottom: 0.5rem;
  line-height: 1;
  letter-spacing: -0.02em;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--muted);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  line-height: 1.4;
}

/* Hero Visual - Clean Squarespace Style */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero-visual .visual-card {
  background: var(--surface) !important;
  border-radius: 0 !important;
  padding: 3rem 2.5rem !important;
  box-shadow: none !important;
  border: 1px solid var(--border) !important;
  max-width: 400px !important;
  width: 100% !important;
  transition: border-color 0.2s ease !important;
  overflow: hidden !important;
}

.hero-visual .visual-card:hover {
  border-color: var(--fg) !important;
  transform: none !important;
  box-shadow: none !important;
}

.card-header {
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  overflow: visible;
}

.card-title {
  font-size: 1rem;
  font-weight: 400;
  color: var(--fg);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.card-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  border-radius: 0;
  overflow: visible;
}

.subscription-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: var(--bg);
  border-radius: 0;
  border: 1px solid var(--border);
  transition: border-color 0.2s ease;
}

.subscription-item:hover {
  background: var(--bg);
  border-color: var(--fg);
  transform: none;
}

.sub-info {
  flex: 1;
}

.sub-name {
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 0.25rem;
}

.sub-date {
  font-size: 0.9rem;
  color: var(--muted);
}

.sub-amount {
  font-weight: 700;
  color: #667eea;
}

/* Buttons - Matching Take Control Today Style */
.btn-primary, .btn-secondary, .btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 1.1rem;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  border-color: #F47600;
  color: white;
}

.btn-secondary {
  background: transparent;
  color: var(--fg);
  border: 2px solid var(--border);
}

.btn-secondary:hover {
  background: var(--surface);
  border-color: #F47600;
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  color: var(--muted);
  border-color: var(--border);
}

.btn-outline:hover {
  border-color: var(--fg);
  color: var(--fg);
}

.btn-large {
  padding: 1.25rem 2.5rem;
  font-size: 0.875rem;
}

/* How It Works Section - Squarespace Style */
.how-it-works {
  padding: 2rem 2rem 2rem 2rem;
  background: var(--bg);
  border-top: none !important;
  border-bottom: none !important;
  margin-bottom: 0 !important;
}

.how-it-works-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4rem;
  max-width: 1200px;
  margin: 0 auto;
}

.how-it-works-card {
  background: transparent;
  padding: 0;
  text-align: center;
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.how-it-works-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--fg);
  margin-bottom: 0;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out forwards;
  transition: transform 0.3s ease, color 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

/* Staggered animation delays for how-it-works icons */
.how-it-works-card:nth-child(1) .how-it-works-icon {
  animation-delay: 0.1s;
}

.how-it-works-card:nth-child(2) .how-it-works-icon {
  animation-delay: 0.2s;
}

.how-it-works-card:nth-child(3) .how-it-works-icon {
  animation-delay: 0.3s;
}

.how-it-works-icon svg {
  width: 48px;
  height: 48px;
  transition: transform 0.3s ease, color 0.3s ease, stroke 0.3s ease;
}

.how-it-works-card:hover .how-it-works-icon {
  transform: translateY(-5px);
  color: #F47600;
}

.how-it-works-card:hover .how-it-works-icon svg {
  transform: scale(1.1);
  color: #F47600;
  stroke: #F47600;
}

/* Mobile - always show teal color for how-it-works icons */
@media (min-width: 769px) and (max-width: 1024px) {
  .how-it-works-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
  }
}

@media (max-width: 768px) {
  .how-it-works-icon {
    color: #F47600;
  }

  .how-it-works-icon svg {
    color: #F47600;
    stroke: #F47600;
  }
}

.how-it-works-title {
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--fg);
  margin: 0;
  line-height: 1.4;
}

/* Screenshot Showcase Section */
.screenshot-showcase {
  padding: 2rem 2rem 4rem 2rem;
  background: var(--bg) !important;
  border-bottom: none !important;
  border-top: none !important;
  margin-bottom: 0 !important;
  margin-top: 0 !important;
}

section.screenshot-showcase {
  background: var(--bg) !important;
  border: none !important;
  border-top: none !important;
  border-bottom: none !important;
}

section.screenshot-showcase .container {
  border-top: none !important;
  border-bottom: none !important;
}

.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
  justify-items: center;
  align-items: center;
}

.screenshot-item {
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
  cursor: pointer;
}

.screenshot-item:nth-child(1) {
  animation-delay: 0.1s;
}

.screenshot-item:nth-child(2) {
  animation-delay: 0.2s;
}

.screenshot-item:nth-child(3) {
  animation-delay: 0.3s;
}

.screenshot-item:nth-child(4) {
  animation-delay: 0.4s;
}

.screenshot-item:nth-child(5) {
  animation-delay: 0.5s;
}

.screenshot-item:nth-child(6) {
  animation-delay: 0.6s;
}

.screenshot-circle {
  width: 280px;
  height: 280px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
  position: relative;
  padding: 4px;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
}

.screenshot-circle::before {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  right: 4px;
  bottom: 4px;
  border-radius: 50%;
  background: #f5f5f5;
  z-index: 0;
}

.screenshot-circle > * {
  position: relative;
  z-index: 1;
  width: calc(100% - 8px);
  height: calc(100% - 8px);
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.screenshot-circle:hover {
  transform: translateY(-5px) scale(1.05);
}

.screenshot-item:active .screenshot-circle {
  transform: translateY(-5px) scale(1.05);
}

.screenshot-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  border-radius: 50%;
}

/* Responsive styles for screenshot showcase */
@media (max-width: 768px) {
  .screenshot-showcase {
    padding: 4rem 1rem;
    background: transparent !important;
  }

  .screenshot-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 100%;
    padding: 0 1rem;
  }

  .screenshot-circle {
    width: min(280px, 90vw);
    height: min(280px, 90vw);
    max-width: 100%;
  }
  
  .screenshot-circle > * {
    width: calc(100% - 8px) !important;
    height: calc(100% - 8px) !important;
  }
  
  .screenshot-item {
    width: 100%;
    display: flex;
    justify-content: center;
  }
}

/* Tablet styles for screenshot showcase */
@media (min-width: 769px) and (max-width: 1024px) {
  .screenshot-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    max-width: 100%;
    padding: 0 1rem;
  }

  .screenshot-circle {
    width: min(260px, 40vw);
    height: min(260px, 40vw);
    max-width: 100%;
  }
  
  .screenshot-circle > * {
    width: calc(100% - 8px) !important;
    height: calc(100% - 8px) !important;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes zoomIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* Testimonials Showcase Section */
.testimonials-showcase {
  padding: 2rem 2rem 4rem 2rem;
  background: transparent;
  border-bottom: none !important;
  margin-bottom: 0 !important;
  overflow: visible !important;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
  justify-items: center;
  align-items: center;
  overflow: visible !important;
}

.testimonial-item {
  display: flex;
  justify-content: center;
  align-items: center;
  animation: fadeInUp 0.6s ease-out forwards;
  opacity: 0;
  cursor: default;
  overflow: visible !important;
  padding: 20px;
}

.testimonial-item:nth-child(1) {
  animation-delay: 0.1s;
}

.testimonial-item:nth-child(2) {
  animation-delay: 0.2s;
}

.testimonial-item:nth-child(3) {
  animation-delay: 0.3s;
}

.testimonial-circle {
  width: 280px;
  height: 280px;
  border-radius: 50%;
  overflow: visible;
  box-shadow: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
  position: relative;
  padding: 4px;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
}

.testimonial-circle::before {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  right: 4px;
  bottom: 4px;
  border-radius: 50%;
  background: var(--surface);
  z-index: 0;
}

.testimonial-circle > * {
  position: relative;
  z-index: 1;
  padding: 2rem;
}

.testimonial-circle:hover {
  transform: translateY(-5px) scale(1.05);
}

.testimonial-content {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  border-radius: 50%;
}

.testimonial-text {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--fg);
  margin: 0;
  font-style: italic;
}

/* Responsive styles for testimonials */
@media (max-width: 768px) {
  .testimonials-showcase {
    padding: 2rem 1rem 4rem 1rem;
  }

  .testimonials-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
    max-width: 100%;
    padding: 0 1rem;
    overflow: visible !important;
  }

  .testimonial-circle {
    width: min(280px, 90vw);
    height: min(280px, 90vw);
    max-width: 100%;
    padding: 1.5rem;
  }
  
  .testimonial-item {
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .testimonial-text {
    font-size: 0.9rem;
  }
}

/* Tablet styles for testimonials */
@media (min-width: 769px) and (max-width: 1024px) {
  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    max-width: 100%;
    padding: 0 1rem;
    overflow: visible !important;
  }

  .testimonial-circle {
    width: min(260px, 40vw);
    height: min(260px, 40vw);
    max-width: 100%;
    padding: 1.5rem;
  }
}

.features {
  padding: 8rem 2rem;
  background: var(--bg) !important;
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 4rem;
}

section.features {
  background: var(--bg) !important;
  border: none !important;
  border-top: none !important;
}

.features::before,
.features::after {
  display: none !important;
  content: none !important;
  border: none !important;
}

.features .container {
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
}

.features .section-header {
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
}

section.features {
  border: none !important;
  border-top: none !important;
  border-bottom: none !important;
  outline: none !important;
  box-shadow: none !important;
}

/* Remove any black bars or borders between sections */
.screenshot-showcase + .features,
.how-it-works + .screenshot-showcase,
.screenshot-showcase + section.features,
section.screenshot-showcase + section.features {
  border-top: none !important;
  border-bottom: none !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  padding-top: 4rem !important;
}

/* Remove borders from all section elements */
section {
  border-top: none !important;
  overflow-x: hidden !important;
  max-width: 100vw !important;
  width: 100%;
}

section.features,
section.screenshot-showcase,
section.how-it-works {
  border: none !important;
  border-top: none !important;
  border-bottom: none !important;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 5rem;
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
}

.features .section-header {
  margin-bottom: 5rem;
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
}

.section-title {
  font-size: 4rem;
  font-weight: 400;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
  border-top: none !important;
  border-bottom: none !important;
  border-left: none !important;
  border-right: none !important;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .section-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-subtitle {
  font-size: 1.5rem;
  color: var(--muted);
  font-weight: 400;
  line-height: 1.6;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4rem;
}

.feature-card {
  background: transparent;
  padding: 0;
  text-align: center;
  border: none;
  box-shadow: none;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--fg);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out forwards;
  transition: transform 0.3s ease, color 0.3s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

/* Staggered animation delays for feature icons */
.feature-card:nth-child(1) .feature-icon {
  animation-delay: 0.1s;
}

.feature-card:nth-child(2) .feature-icon {
  animation-delay: 0.2s;
}

.feature-card:nth-child(3) .feature-icon {
  animation-delay: 0.3s;
}

.feature-card:nth-child(4) .feature-icon {
  animation-delay: 0.4s;
}

.feature-icon svg {
  width: 48px;
  height: 48px;
  transition: transform 0.3s ease, color 0.3s ease, stroke 0.3s ease;
}

.feature-card:hover .feature-icon {
  transform: translateY(-5px);
  color: #F47600;
}

.feature-card:hover .feature-icon svg {
  transform: scale(1.1);
  color: #F47600;
  stroke: #F47600;
}

/* Mobile - always show teal color for feature icons */
@media (max-width: 768px) {
  .feature-icon {
    color: #F47600;
  }

  .feature-icon svg {
    color: #F47600;
    stroke: #F47600;
  }
}

.feature-title {
  font-size: 1.875rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 1rem;
  line-height: 1.4;
}

.feature-description {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--muted);
}

/* FAQ Section */
.faq-section {
  padding: 2rem 2rem;
  background: var(--bg);
}

.faq-section .section-header {
  margin-bottom: 5rem;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
}

.faq-item {
  background: transparent;
  padding: 0;
  border: none;
  box-shadow: none;
}

.faq-question {
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 1rem;
  line-height: 1.4;
}

.faq-answer {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
}

/* Plans Section - Squarespace Style */
.plans {
  padding: 8rem 2rem;
  background: var(--bg);
  border-top: none;
}

.plans .section-subtitle {
  font-size: 1.5rem;
}

.plans-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 4rem;
  max-width: 900px;
  margin: 0 auto;
}

.plan-card {
  background: transparent;
  padding: 0;
  box-shadow: none;
  border: 1px solid var(--border);
  border-radius: 16px;
  transition: all 0.2s ease;
  text-align: left;
  padding: 3rem;
}

.plan-card:hover {
  border-color: var(--fg);
}

.pro-plan {
  border: 1px solid var(--fg);
}

.plan-badge {
  position: absolute;
  top: -1px;
  right: 2rem;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 0 0 12px 12px;
  font-size: 0.9rem;
  font-weight: 600;
}

.plan-header {
  margin-bottom: 2.5rem;
}

.plan-icon {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  display: block;
}

.plan-title {
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 1.5rem;
  letter-spacing: -0.01em;
}

.plan-price {
  display: flex;
  align-items: baseline;
  justify-content: flex-start;
  gap: 0.25rem;
  margin-bottom: 1rem;
}

.price {
  font-size: 3rem;
  font-weight: 400;
  color: var(--fg);
  line-height: 1.2;
}

.period {
  font-size: 1rem;
  color: var(--muted);
  font-weight: 400;
}

.plan-description {
  font-size: 1rem;
  color: var(--muted);
  margin-bottom: 2.5rem;
  font-weight: 400;
  line-height: 1.6;
  text-align: center;
}

.plan-features {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1rem;
  color: var(--fg);
  font-weight: 400;
}

.feature-item svg {
  color: var(--fg);
  flex-shrink: 0;
}

.plan-cta {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.plan-cta .btn-liquid-primary {
  width: 100%;
  min-width: 200px;
  max-width: 280px;
}

/* Desktop: Ensure plan buttons are same size */
@media (min-width: 769px) {
  .plan-cta .btn-liquid-primary {
    width: 260px;
    min-width: 260px;
    max-width: 260px;
  }
}

.stripe-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  gap: 10px;
  flex-wrap: wrap;
}

.stripe-badge svg {
  color: var(--text-secondary);
  opacity: 0.8;
  flex-shrink: 0;
}

.stripe-badge img {
  opacity: 0.9;
}

.stripe-badge img:nth-of-type(1) {
  width: 32px;
  height: 32px;
}

.stripe-badge img:nth-of-type(2) {
  height: 20px;
  width: auto;
}

.stripe-badge .stripe-text {
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.5;
}

/* CTA Section - Squarespace Style */
.cta {
  padding: 8rem 2rem;
  background: var(--bg);
  border-top: none;
}

.cta-content {
  background: transparent;
  padding: 0;
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  border: none;
  box-shadow: none;
}

.cta-title {
  font-size: 4rem;
  font-weight: 400;
  margin-bottom: 2rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .cta-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.cta-description {
  font-size: 1.5rem;
  margin-bottom: 3rem;
  color: var(--muted);
  line-height: 1.6;
}

.cta-actions {
  margin-bottom: 2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
}

.cta-features {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.cta-feature {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  color: var(--muted);
}

.cta-feature svg {
  color: #28a745;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  /* Landing page - Match dashboard spacing structure */
  .landing-page {
    padding: 20px 16px 0 16px;
    margin: 0;
    gap: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow-x: visible !important;
    overflow-y: visible !important;
    position: relative;
  }
  
  /* Standardize all landing page section padding - match dashboard container pattern */
  .hero {
    padding: 0;
    border-radius: 0;
    min-height: auto;
    margin: 0;
    width: 100%;
    background: transparent;
  }
  
  .hero::before {
    display: none;
  }
  
  /* Hero logos removed */
  
  .hero .container {
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .hero-container {
    grid-template-columns: 1fr;
    gap: 20px;
    text-align: center;
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .hero-content {
    text-align: center;
    padding: 0;
    width: 100%;
  }
  
  .hero-title {
    font-size: 2.75rem;
    line-height: 1.2;
    margin-bottom: 1.25rem;
    letter-spacing: -0.02em;
    font-weight: 400;
  }
  
  .hero-description {
    font-size: 1.75rem;
    margin-bottom: 2rem;
    line-height: 1.4;
    font-weight: 400;
  }
  
  .hero h1,
  .hero .hero-title {
    font-size: 2.75rem !important;
    font-weight: 400 !important;
    line-height: 1.2 !important;
    letter-spacing: -0.02em !important;
  }
  
  .hero p,
  .hero .hero-description {
    font-size: 1.75rem !important;
    line-height: 1.4 !important;
    font-weight: 400 !important;
  }
  
  .hero-actions {
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2.5rem;
  }
  
  .hero-stats {
    justify-content: space-around;
    gap: 1rem;
    padding-top: 1.5rem;
  }
  
  .stat {
    text-align: center;
  }
  
  .stat-number {
    font-size: 2rem;
  }
  
  .stat-label {
    font-size: 0.85rem;
  }
  
  .how-it-works {
    padding: 4rem 1rem 2rem 1rem;
    margin: 0;
    width: 100%;
    background: transparent;
  }
  
  .how-it-works .container {
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .features {
    border-radius: 0;
    margin: 0;
    padding: 0;
    width: 100%;
    background: transparent;
  }
  
  .features .container {
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .plans {
    border-radius: 0;
    margin: 0;
    padding: 0;
    width: 100%;
    background: transparent;
  }
  
  .plans .container {
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .plans-grid {
    margin-bottom: 0;
  }
  
  .section-header {
    margin-bottom: 2.5rem;
  }
  
  .section-title {
    font-size: 2.25rem !important;
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
    line-height: 1.2;
  }
  
  .section-subtitle {
    font-size: 1.5rem;
    margin-bottom: 0;
    line-height: 1.6;
  }
  
  .how-it-works .section-header {
    margin-bottom: 2.5rem;
  }
  
  .features .section-header {
    margin-bottom: 2.5rem;
  }
  
  .how-it-works-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  
  .how-it-works-card {
    padding: 2.5rem 2rem;
    border-radius: 0;
    box-shadow: none;
    text-align: center;
    align-items: center;
  }
  
  .how-it-works-card:hover {
    transform: none;
    box-shadow: none;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .faq-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .faq-section {
    padding: 2rem 1.5rem;
  }
  
  .faq-section .section-header {
    margin-bottom: 2.5rem;
  }
  
  .faq-question {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
  }
  
  .faq-answer {
    font-size: 0.9375rem;
  }
  
  .feature-card {
    padding: 2.5rem 2rem;
    border-radius: 0;
    box-shadow: none;
    text-align: center;
    align-items: center;
  }
  
  .feature-card:hover {
    transform: none;
    box-shadow: none;
  }
  
  .plans-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-bottom: 0;
  }
  
  .plan-card {
    padding: 2.5rem 2rem;
    border-radius: 16px;
    box-shadow: none !important;
  }
  
  .plan-card:hover {
    transform: none;
    box-shadow: none !important;
    border-color: var(--fg);
  }
  
  .free-plan {
    border: 1px solid var(--border) !important;
  }
  
  .free-plan,
  .pro-plan {
    box-shadow: none !important;
  }
  
  .free-plan:hover,
  .pro-plan:hover {
    box-shadow: none !important;
  }
  
  .plan-cta {
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }
  
  .plan-cta .stripe-badge {
    margin-bottom: 16px;
    width: 100%;
  }
  
  .plan-cta .btn-primary {
    margin: 0 auto;
    display: inline-block;
    width: 100%;
  }
  
  .cta {
    padding: 0;
    margin: 0;
    width: 100%;
    background: transparent;
  }
  
  .cta .container {
    padding: 0;
    margin: 0;
    width: 100%;
  }
  
  .cta-content {
    border-radius: 24px;
    padding: 3rem 2rem;
    box-shadow: none;
    border: 1px solid var(--border);
    margin: 0;
    max-width: 100%;
    background: var(--surface);
  }
  
  .cta-content:hover {
    transform: none;
    box-shadow: none;
  }
  
  .cta-title {
    font-size: 2rem;
    margin-bottom: 1rem;
    font-weight: 700;
    letter-spacing: -0.02em;
  }
  
  .cta-description {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    line-height: 1.6;
  }
  
  .cta-actions {
    margin-bottom: 12px;
  }
  
  .cta-features {
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
    margin-top: 0;
  }
  
  .cta-feature {
    justify-content: center;
    font-size: 0.9rem;
    margin: 0;
  }
  
  .btn-primary, .btn-secondary, .btn-outline {
    width: 100%;
    max-width: 280px;
    justify-content: center;
    padding: 0.875rem 1.5rem;
    font-size: 0.95rem;
  }
  
  .hero-visual .visual-card {
    border-radius: 32px !important;
    padding: 1.5rem;
    max-width: 320px;
    box-shadow: none !important;
  }
}

/* Tablet Responsive - Portrait and Landscape */
@media (min-width: 769px) and (max-width: 1024px) {
  .hero {
    padding: 3rem 2rem;
    min-height: 85vh;
  }
  
  .hero-container {
    gap: 3rem;
  }
  
  .hero-title {
    font-size: 2.25rem;
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: -0.02em;
  }
  
  .hero-description {
    font-size: 1.5rem;
    font-weight: 400;
    line-height: 1.4;
  }
  
  .features, .plans, .cta {
    padding: 5rem 2rem;
  }
  
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
  
  .plans-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 900px;
  }
  
  .btn-primary, .btn-secondary, .btn-outline {
    padding: 1rem 2rem;
  }
  
  /* Tablet dashboard and analytics circles - 2x2 grid for all tablets */
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .dashboard-container .cards .card {
    grid-column: auto !important;
    grid-row: auto !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .analytics-summary .summary-card.card {
    grid-column: auto !important;
    grid-row: auto !important;
  }
}

/* Tablet Portrait - 2x2 grid */
@media (min-width: 769px) and (max-width: 1024px) and (orientation: portrait) {
  .dashboard-container {
    padding: 2.5rem 1.5rem !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
  }
  
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    padding: 0 12px !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .analytics-container {
    padding: 2.5rem 1.5rem !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    padding: 0 12px !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .chart-container {
    padding: 2rem 1.5rem !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 2rem auto !important;
  }
  
  .table-container {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 1.5rem auto !important;
  }
  
  .calendar-section {
    width: 100% !important;
    max-width: 100% !important;
    margin: 1.5rem auto 0 auto !important;
  }
}

/* Tablet Landscape - 2x2 grid */
@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {
  .dashboard-container {
    padding: 2rem 1.5rem !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
  }
  
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    padding: 0 12px !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .analytics-container {
    padding: 2rem 1.5rem !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    padding: 0 12px !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .chart-container {
    padding: 2rem 1.5rem !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 2rem auto !important;
  }
  
  /* Fix subscription actions buttons on mobile landscape - ensure delete button is fully visible */
  .subscription-actions {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    padding: 0 !important;
    margin-top: 16px !important;
  }
  
  .subscription-actions .btn,
  .subscription-actions .btn-liquid-secondary,
  .subscription-actions .btn-liquid-danger {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: nowrap !important;
  }
  
  .subscription-actions .delete-form {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
  }
  
  .subscription-actions .delete-form .btn-liquid-danger {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: nowrap !important;
  }
  
  /* Fix category modal subscription actions on mobile landscape */
  .category-modal-content .subscription-actions {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    padding: 0 !important;
    margin-top: 16px !important;
  }
  
  .category-modal-content .subscription-actions .btn,
  .category-modal-content .subscription-actions .btn-liquid-secondary,
  .category-modal-content .subscription-actions .btn-liquid-danger {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: nowrap !important;
  }
  
  .category-modal-content .subscription-actions .delete-form {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
  }
  
  .category-modal-content .subscription-actions .delete-form .btn-liquid-danger {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: nowrap !important;
  }
  
  /* Mobile subscription form styles removed - see new design below */
  
  .centered .auth-card h2 {
    text-align: center !important;
    margin-bottom: 2rem !important;
  }
  
  .centered .auth-card .form {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 2rem !important; /* Better spacing between all form fields (service, amount, due date, remind before) */
    align-items: stretch !important;
  }
  
  .centered .auth-card .form > * {
    margin: 0 !important; /* Remove all margins, use gap instead */
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  /* Fix label structure - make label text appear above inputs */
  .centered .auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) {
    display: block !important;
    width: 100% !important;
    margin: 0 !important; /* Remove margin, use form gap instead */
    padding: 0 !important;
    box-sizing: border-box !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    color: var(--fg) !important;
    line-height: 1.5 !important;
  }
  
  /* Make all direct children of label block-level and aligned */
  .centered .auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) > input,
  .centered .auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) > .number-input-wrapper,
  .centered .auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) > select,
  .centered .auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) > textarea {
    display: block !important;
    width: 100% !important;
    margin: 0.5rem 0 0 0 !important;
    box-sizing: border-box !important;
  }
  
  /* Handle text nodes - make them appear as block by wrapping in span-like behavior */
  .centered .auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) {
    white-space: normal !important;
  }
  
  /* Direct input in label (Service, Category fields) */
  .centered .auth-card .form label > input:not(.number-input):not(.ios-toggle):not(.custom-color-input) {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    padding: 12px 16px !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    font-size: 16px !important;
    background: var(--background) !important;
    color: var(--fg) !important;
  }
  
  /* Number input wrapper (Amount, Due Date, Remind Before) - must be block and full width */
  .centered .auth-card .form label > .number-input-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
    position: relative !important;
  }
  
  /* Number input inside wrapper */
  .centered .auth-card .form .number-input-wrapper .number-input {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    padding: 12px 16px !important;
    padding-right: 50px !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    font-size: 16px !important;
    background: var(--background) !important;
    color: var(--fg) !important;
    -webkit-appearance: none !important;
    -moz-appearance: textfield !important;
    appearance: none !important;
  }
  
  /* Ensure all inputs align at same position */
  .centered .auth-card .form input:not(.ios-toggle):not(.custom-color-input),
  .centered .auth-card .form textarea,
  .centered .auth-card .form select {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    padding: 12px 16px !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    font-size: 16px !important;
    background: var(--background) !important;
    color: var(--fg) !important;
  }
  
  .centered .auth-card .form .reminder-section,
  .centered .auth-card .form .color-section {
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }
  
  /* Button override - removed, handled in mobile subscription form section */
  
  .subscription-actions {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
    padding: 0 !important;
    margin-top: 16px !important;
  }
  
  .subscription-actions .btn,
  .subscription-actions .btn-liquid-secondary,
  .subscription-actions .btn-liquid-danger {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: nowrap !important;
  }
  
  .subscription-actions .delete-form {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    display: flex !important;
  }
  
  .subscription-actions .delete-form .btn-liquid-danger {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    white-space: nowrap !important;
  }
}

/* ============================================
   MOBILE SUBSCRIPTION FORM - COMPLETE REDESIGN
   Perfect for small and wide mobile screens
   HIGHEST PRIORITY - MUST OVERRIDE ALL OTHER RULES
   ============================================ */

/* Base mobile styles (up to 1000px) - HIGHEST PRIORITY */
@media (max-width: 1000px) {
  /* Override ALL conflicting .centered rules for subscription form */
  body .centered.auth-card,
  html body .centered.auth-card {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 auto !important;
    padding: 2rem 1.5rem !important;
    border: 1px solid var(--border) !important;
    border-radius: 16px !important;
    background: var(--surface) !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    box-sizing: border-box !important;
    overflow: visible !important;
    max-height: none !important;
  }
  
  /* Ensure .centered wrapper doesn't stretch */
  body main.container .centered,
  html body main.container .centered {
    max-width: 100% !important;
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
    box-sizing: border-box !important;
  }
  
  /* Override container padding for subscription form page */
  body .centered.auth-card ~ *,
  body > main .centered.auth-card,
  body > main.container .centered.auth-card {
    /* This ensures proper spacing */
  }
  
  /* Set proper container padding */
  body > main.container .centered.auth-card,
  main.container .centered.auth-card {
    margin-top: 2.5rem !important;
  }
  
  .centered.auth-card h2 {
    font-size: 1.75rem !important;
    font-weight: 600 !important;
    margin-bottom: 1.5rem !important;
    text-align: center !important;
    color: var(--fg) !important;
    letter-spacing: -0.01em !important;
    line-height: 1.2 !important;
  }
  
  .centered.auth-card .form {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 1.25rem !important;
    box-sizing: border-box !important;
    overflow: visible !important;
  }
  
  .centered.auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) {
    display: block !important;
    width: 100% !important;
    margin: 0 0 0.5rem 0 !important;
    padding: 0 !important;
    font-weight: 600 !important;
    font-size: 14px !important;
    color: var(--fg) !important;
    box-sizing: border-box !important;
  }
  
  .centered.auth-card .form label > input:not(.number-input):not(.ios-toggle):not(.custom-color-input),
  .centered.auth-card .form label > .number-input-wrapper {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box !important;
  }
  
  .centered.auth-card .form label > input:not(.number-input):not(.ios-toggle):not(.custom-color-input) {
    padding: 12px 16px !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    font-size: 16px !important;
    background: var(--surface) !important;
    color: var(--fg) !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .centered.auth-card .form .number-input-wrapper {
    width: 100% !important;
    position: relative !important;
  }
  
  .centered.auth-card .form .number-input-wrapper .number-input {
    width: 100% !important;
    padding: 12px 16px !important;
    padding-right: 50px !important;
    border: 1px solid var(--border) !important;
    border-radius: 8px !important;
    font-size: 16px !important;
    background: var(--surface) !important;
    color: var(--fg) !important;
    box-sizing: border-box !important;
  }
  
  /* Button - Match desktop exactly - full width */
  .centered.auth-card .form button[type="submit"],
  .centered.auth-card .form .btn-liquid-primary,
  .centered.auth-card .form button.btn-liquid-primary {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    padding: 1.125rem 2.75rem !important;
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    color: white !important;
    border: 2px solid transparent !important;
    border-radius: 50px !important;
    font-size: 1.125rem !important;
    font-weight: 700 !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    margin-top: 0.5rem !important;
    width: auto !important;
    min-width: auto !important;
    max-width: 250px !important;
    min-height: auto !important;
    height: auto !important;
    box-sizing: border-box !important;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
    overflow: hidden !important;
    text-align: center !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    z-index: 1 !important;
  }
  
  /* OVERRIDE: Center contact page button on larger mobile (481px-768px) - MUST come after button rules */
  @media (min-width: 481px) and (max-width: 768px) {
    /* Ensure form uses flexbox for centering */
    .contact-page.centered .auth-card .form,
    .contact-page .centered.auth-card .form,
    .contact-page .auth-card .form {
      display: flex !important;
      flex-direction: column !important;
      align-items: stretch !important;
      justify-content: flex-start !important;
    }
    
    /* Create a wrapper effect for the button using pseudo-element or direct centering */
    .contact-page.centered .auth-card .form::after,
    .contact-page .centered.auth-card .form::after,
    .contact-page .auth-card .form::after {
      content: '';
      flex: 0 0 auto;
    }
    
    /* Center the button - ULTRA SPECIFIC SELECTORS */
    .contact-page.centered .auth-card .form button[type="submit"],
    .contact-page.centered .auth-card .form .btn-liquid-primary,
    .contact-page.centered .auth-card .form button.btn-liquid-primary,
    .contact-page .centered.auth-card .form button[type="submit"],
    .contact-page .centered.auth-card .form .btn-liquid-primary,
    .contact-page .centered.auth-card .form button.btn-liquid-primary,
    .contact-page .auth-card .form button[type="submit"],
    .contact-page .auth-card .form .btn-liquid-primary,
    .contact-page .auth-card .form button.btn-liquid-primary,
    body .contact-page.centered .auth-card .form button,
    body .contact-page .centered.auth-card .form button,
    body .contact-page .auth-card .form button {
      align-self: center !important;
      margin-left: auto !important;
      margin-right: auto !important;
      margin-top: 0.5rem !important;
      margin-bottom: 0 !important;
      width: 100% !important;
      max-width: 300px !important;
      min-width: 0 !important;
      display: flex !important;
      justify-content: center !important;
      align-items: center !important;
      flex-shrink: 0 !important;
    }
    
    /* Force button to be centered - use transform method as primary */
    .contact-page.centered .auth-card .form > button:last-child,
    .contact-page .centered.auth-card .form > button:last-child,
    .contact-page .auth-card .form > button:last-child,
    .contact-page.centered .auth-card .form button.btn-liquid-primary,
    .contact-page .centered.auth-card .form button.btn-liquid-primary,
    .contact-page .auth-card .form button.btn-liquid-primary {
      align-self: center !important;
      margin-left: auto !important;
      margin-right: auto !important;
      position: relative !important;
      left: 50% !important;
      transform: translateX(-50%) !important;
      width: 100% !important;
      max-width: 300px !important;
    }
  }
  
  .centered.auth-card .form .reminder-section,
  .centered.auth-card .form .color-section {
    margin: 0 !important;
    padding: 0 !important;
  }
}

/* Small mobile screens (up to 480px) - HIGHEST PRIORITY */
@media (max-width: 480px) {
  body .centered.auth-card,
  html body .centered.auth-card {
    padding: 1.5rem 1.25rem !important;
    border-radius: 12px !important;
    margin-top: 2rem !important;
  }
  
  body > main.container .centered.auth-card,
  main.container .centered.auth-card {
    margin-top: 2rem !important;
  }
  
  .centered.auth-card h2 {
    font-size: 1.5rem !important;
    margin-bottom: 1.25rem !important;
  }
  
  .centered.auth-card .form {
    gap: 1rem !important;
  }
  
  .centered.auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) {
    font-size: 13px !important;
    margin-bottom: 0.375rem !important;
  }
  
  .centered.auth-card .form label > input:not(.number-input):not(.ios-toggle):not(.custom-color-input),
  .centered.auth-card .form .number-input-wrapper .number-input {
    padding: 10px 14px !important;
    font-size: 15px !important;
  }
  
  .centered.auth-card .form .number-input-wrapper .number-input {
    padding-right: 45px !important;
  }
  
  /* Button - Match desktop exactly */
  .centered.auth-card .form button[type="submit"],
  .centered.auth-card .form .btn-liquid-primary,
  .centered.auth-card .form button.btn-liquid-primary {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    padding: 1.125rem 2.75rem !important;
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    color: white !important;
    border: 2px solid transparent !important;
    border-radius: 50px !important;
    font-size: 1.125rem !important;
    font-weight: 700 !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    margin-top: 0.5rem !important;
    width: auto !important;
    min-width: auto !important;
    max-width: 250px !important;
    min-height: auto !important;
    height: auto !important;
    box-sizing: border-box !important;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
    overflow: hidden !important;
    text-align: center !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    z-index: 1 !important;
  }
}

/* Medium mobile screens (481px - 768px) - HIGHEST PRIORITY */
@media (min-width: 481px) and (max-width: 768px) {
  body .centered.auth-card,
  html body .centered.auth-card {
    max-width: 600px !important;
    padding: 2rem 1.75rem !important;
    margin: 2.5rem auto 0 auto !important;
  }
  
  body > main.container .centered.auth-card,
  main.container .centered.auth-card {
    margin-top: 2.5rem !important;
  }
  
  .centered.auth-card h2 {
    font-size: 1.875rem !important;
    margin-bottom: 1.5rem !important;
  }
  
  .centered.auth-card .form {
    gap: 1.25rem !important;
  }
}

/* Wide mobile screens (769px - 1000px) - HIGHEST PRIORITY */
/* When menu is visible across header (not hamburger), ensure perfect centering */
@media (min-width: 769px) and (max-width: 1000px) {
  /* Override main.container to center content */
  body main.container,
  html body main.container,
  main.container {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    max-width: 100% !important;
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 2rem !important;
    padding-right: 2rem !important;
    box-sizing: border-box !important;
  }
  
  /* Override .centered to center content - MUST override align-items: stretch */
  body main.container .centered,
  html body main.container .centered,
  main.container .centered,
  body .centered,
  html body .centered,
  .centered {
    max-width: 100% !important;
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    align-content: center !important;
    justify-content: flex-start !important;
    padding: 0 !important;
    gap: 0 !important;
    box-sizing: border-box !important;
  }
  
  /* Card should be perfectly centered with max-width */
  body .centered.auth-card,
  html body .centered.auth-card,
  body main.container .centered.auth-card,
  html body main.container .centered.auth-card,
  main.container .centered.auth-card,
  .centered.auth-card {
    max-width: 700px !important;
    width: 100% !important;
    padding: 2.5rem 2rem !important;
    margin-left: auto !important;
    margin-right: auto !important;
    margin-top: 3rem !important;
    margin-bottom: 3rem !important;
    border-radius: 16px !important;
    overflow: visible !important;
    max-height: none !important;
    display: block !important;
    box-sizing: border-box !important;
    position: relative !important;
    left: 0 !important;
    right: 0 !important;
  }
  
  .centered.auth-card h2 {
    font-size: 2.25rem !important;
    margin-bottom: 2rem !important;
  }
  
  .centered.auth-card .form {
    gap: 1.5rem !important;
  }
  
  .centered.auth-card .form label:not(.ios-toggle-label):not(.reminder-toggle-label) {
    font-size: 15px !important;
  }
  
  .centered.auth-card .form label > input:not(.number-input):not(.ios-toggle):not(.custom-color-input),
  .centered.auth-card .form .number-input-wrapper .number-input {
    padding: 14px 18px !important;
    font-size: 16px !important;
  }
  
  /* Button - Match desktop exactly */
  .centered.auth-card .form button[type="submit"],
  .centered.auth-card .form .btn-liquid-primary,
  .centered.auth-card .form button.btn-liquid-primary {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    padding: 1.125rem 2.75rem !important;
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    color: white !important;
    border: 2px solid transparent !important;
    border-radius: 50px !important;
    font-size: 1.125rem !important;
    font-weight: 700 !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif !important;
    margin-top: 0.5rem !important;
    width: auto !important;
    min-width: auto !important;
    max-width: 250px !important;
    min-height: auto !important;
    height: auto !important;
    box-sizing: border-box !important;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative !important;
    overflow: hidden !important;
    text-align: center !important;
    white-space: nowrap !important;
    text-decoration: none !important;
    z-index: 1 !important;
  }
}

/* Mobile Landscape (up to 768px) */
@media (max-width: 768px) and (orientation: landscape) {
  .centered {
    padding: 1.5rem 1rem 2rem 1rem !important;
    padding-top: 2rem !important;
  }
  
  .centered.auth-card {
    max-height: calc(100vh - 3rem) !important;
    overflow-y: auto !important;
    padding: 1.5rem 1.25rem !important;
  }
  
  .centered.auth-card h2 {
    font-size: 1.5rem !important;
    margin-bottom: 1.25rem !important;
  }
  
  .centered.auth-card .form {
    gap: 1rem !important;
  }
}

/* All Tablets (769px-1440px) - 2x2 grid for all orientations */
@media (min-width: 769px) and (max-width: 1440px) {
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .dashboard-container .cards .card {
    grid-row: auto !important;
    grid-column: auto !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    grid-template-rows: repeat(2, auto) !important;
    gap: 20px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 24px auto !important;
    justify-items: center !important;
    place-items: center !important;
  }
  
  .analytics-summary .summary-card.card {
    grid-row: auto !important;
    grid-column: auto !important;
  }
}

/* Desktop only - 4 in one row (1025px+) - MUST override tablet 2x2 - MUST BE AFTER TABLET */
@media (min-width: 1025px) {
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    margin: 0 auto 32px auto !important;
    width: 100% !important;
    max-width: 100% !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
  }
  
  .dashboard-container .cards .card {
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(3) {
    grid-column: 3 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(4) {
    grid-column: 4 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    margin: 0 auto 32px auto !important;
    width: 100% !important;
    max-width: 100% !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
  }
  
  .analytics-summary .summary-card.card {
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(3) {
    grid-column: 3 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(4) {
    grid-column: 4 !important;
    grid-row: 1 !important;
  }
}

/* Landscape Mobile */
@media (max-width: 768px) and (orientation: landscape) {
  .hero {
    min-height: 100vh;
    padding: 1.5rem 1rem;
  }
  
  .hero-title {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
  }
  
  .hero-description {
    font-size: 1.5rem;
    margin-bottom: 1rem;
  }
  
  .hero-actions {
    margin-bottom: 1.5rem;
  }
  
  .hero-stats {
    gap: 1rem;
  }
  
  .features, .plans, .cta {
    padding: 2rem 1rem;
  }
  
  .section-title {
    font-size: 2.25rem !important;
  }
  
  .how-it-works .section-title,
  .features .section-title,
  .plans .section-title,
  .testimonials-showcase .section-title,
  .faq-section .section-title {
    font-size: 2.25rem !important;
  }
  
  /* Force dashboard and analytics titles to match "Choose Your Plan" in landscape */
  .dashboard-container h2.section-title,
  .analytics-header h2.section-title {
    font-size: 2.25rem !important;
    font-weight: 400 !important;
    margin-bottom: 1rem !important;
    letter-spacing: -0.02em !important;
    line-height: 1.2 !important;
  }
  
  .feature-card, .plan-card {
    padding: 1.5rem;
  }
  
  .dashboard-container h2:not(.section-title),
  .analytics-header h2:not(.section-title) {
    font-size: 24px !important;
    font-weight: 700 !important;
  }
  
  /* Chart optimizations for landscape mode */
  .chart-container {
    padding: 1.5rem 1rem !important;
    margin-bottom: 1.5rem !important;
    border-radius: 16px !important;
  }
  
  .chart-wrapper {
    height: 350px !important;
    margin: 4px 0 !important;
  }
  
  .chart-header h2 {
    font-size: 1.1rem !important;
    margin-bottom: 0.5rem !important;
  }
  
  .spending-summary {
    gap: 0.75rem !important;
    margin-bottom: 1rem !important;
  }
  
  .spending-circle {
    width: 180px !important;
    height: 180px !important;
    padding: 1.25rem !important;
    border-radius: 20px !important;
  }
  
  .circle-label {
    font-size: 0.65rem !important;
    margin-bottom: 0.3rem !important;
  }
  
  .circle-value {
    font-size: 1.1rem !important;
  }
  
  .instruction-text {
    font-size: 0.9rem !important;
    margin-bottom: 0.75rem !important;
  }
  
  .color-picker-grid {
    gap: 8px !important;
    margin-top: 1rem !important;
  }
  
  .color-picker-item {
    padding: 8px 12px !important;
    min-width: 80px !important;
    max-width: 110px !important;
    font-size: 0.8rem !important;
  }
  
  /* FAQ section for landscape */
  .faq-section {
    padding: 1.5rem 1rem !important;
  }
  
  .faq-section .section-header {
    margin-bottom: 1.5rem !important;
  }
  
  /* Navbar optimization for landscape mode */
  .navbar {
    padding: 0 !important;
  }
  
  .navbar .container {
    padding: 10px 12px !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .brand {
    font-size: 16px !important;
  }
  
  .brand img {
    height: 24px !important;
    width: auto !important;
  }
  
  nav a {
    font-size: 14px !important;
    margin-left: 12px !important;
  }
  
  .nav-group a {
    font-size: 14px !important;
    margin-left: 12px !important;
  }
  
  nav .theme-toggle.ios-toggle {
    margin-right: 8px !important;
    height: 31px !important;
    min-width: 91px !important;
    position: relative !important;
    transform: none !important;
    flex-shrink: 0 !important;
    contain: layout style paint !important;
  }
  
  /* Hamburger menu optimization for landscape mode */
  .hamburger-menu {
    width: 20px !important;
    height: 20px !important;
  }
  
  .hamburger-menu span {
    height: 2px !important;
  }
  
  /* Footer optimization for landscape mode */
  .footer {
    padding: 6px 12px !important;
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .footer .container {
    padding: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  
  .copyright {
    font-size: 10px !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  
  /* Adjust main container padding to account for fixed footer */
  main.container {
    padding-bottom: 40px !important;
  }
  
  /* Force 2x2 grid for dashboard circles in landscape - override all desktop styles */
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(140px, 1fr)) !important;
    grid-template-rows: repeat(2, minmax(140px, auto)) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 1.5rem auto !important;
    padding: 0 !important;
    justify-items: center !important;
    place-items: center !important;
    grid-auto-flow: row !important;
    grid-auto-rows: auto !important;
    grid-auto-columns: minmax(140px, 1fr) !important;
  }
  
  .dashboard-container .cards .card:nth-child(1),
  .dashboard-container .cards .card:nth-child(2) {
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(3),
  .dashboard-container .cards .card:nth-child(4) {
    grid-row: 2 !important;
  }
  
  .dashboard-container .cards .card:nth-child(1),
  .dashboard-container .cards .card:nth-child(3) {
    grid-column: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(2),
  .dashboard-container .cards .card:nth-child(4) {
    grid-column: 2 !important;
  }
  
  /* Force 2x2 grid for analytics circles in landscape - override all desktop styles */
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(140px, 1fr)) !important;
    grid-template-rows: repeat(2, minmax(140px, auto)) !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto 1.5rem auto !important;
    padding: 0 4px !important;
    justify-items: center !important;
    place-items: center !important;
    grid-auto-flow: row !important;
    grid-auto-rows: auto !important;
    grid-auto-columns: minmax(140px, 1fr) !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(1),
  .analytics-summary .summary-card.card:nth-child(2) {
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(3),
  .analytics-summary .summary-card.card:nth-child(4) {
    grid-row: 2 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(1),
  .analytics-summary .summary-card.card:nth-child(3) {
    grid-column: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(2),
  .analytics-summary .summary-card.card:nth-child(4) {
    grid-column: 2 !important;
  }
}

/* Desktop spacing optimization */
@media (min-width: 1025px) {
  .hero {
    padding: 2rem 2rem;
    min-height: 80vh;
  }
  
  .features {
    padding: 4rem 2rem;
  }
  
  .plans {
    padding: 4rem 2rem;
  }
  
  .cta {
    padding: 4rem 2rem;
  }
}

/* Force dashboard card corner radius - Highest specificity */
.landing-page .hero .hero-visual .visual-card {
  border-radius: 32px !important;
  overflow: hidden !important;
}

.landing-page .hero .hero-visual .visual-card * {
  border-radius: inherit !important;
}

.landing-page .hero .hero-visual .visual-card .card-header {
  border-radius: 32px 32px 0 0 !important;
}

.landing-page .hero .hero-visual .visual-card .card-content {
  border-radius: 0 0 32px 32px !important;
}

.landing-page .hero .hero-visual .visual-card .subscription-item {
  border-radius: 16px !important;
  margin: 0.25rem 0 !important;
}

/* Welcome Section */
.welcome-section {
  min-height: 60vh;
  display: flex;
  align-items: flex-start;
  padding: 2rem 1rem 0.5rem 1rem;
  background: transparent;
}

.welcome-container {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}

.welcome-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 2rem 3rem;
  text-align: center;
  box-shadow: 0 4px 20px var(--shadow);
}

.welcome-title {
  font-size: 3.5rem;
  font-weight: 700;
  line-height: 1.1;
  color: var(--fg);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.welcome-subtitle {
  font-size: 1.4rem;
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 2.5rem;
}

.welcome-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
}

.btn-large {
  padding: 1rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: 50px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-primary.btn-large {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  box-shadow: 0 4px 20px rgba(244, 118, 0, 0.3);
}

.btn-primary.btn-large:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(244, 118, 0, 0.4);
  border-color: #F47600;
}

.btn-secondary.btn-large {
  background: transparent;
  color: var(--fg);
  border: 2px solid var(--border);
}

.btn-secondary.btn-large:hover {
  background: var(--surface);
  border-color: #F47600;
}

/* Intro Section */
.intro-section {
  padding: 1.5rem 1rem;
  background: transparent;
}

.intro-container {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}

.intro-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 40px;
  padding: 2rem 2.5rem;
  text-align: center;
  box-shadow: 0 2px 12px var(--shadow);
}

.intro-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.intro-description {
  font-size: 1.3rem;
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 2rem;
}

.intro-stats {
  display: flex;
  gap: 2rem;
  justify-content: center;
}

.stat-pill {
  background: rgba(0, 122, 255, 0.1);
  border-radius: 20px;
  padding: 1rem 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: #F47600;
  margin-bottom: 0.25rem;
}

.stat-label {
  font-size: 1rem;
  color: var(--muted);
  font-weight: 500;
}

/* Benefits Section */
.benefits-section {
  padding: 1.5rem 1rem;
  background: transparent;
}

.benefits-container {
  max-width: 1200px;
  margin: 0 auto;
}

.benefits-title {
  font-size: 3rem;
  font-weight: 700;
  text-align: center;
  color: var(--fg);
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  justify-items: center;
}

/* Ensure desktop benefits grid stays correct */
@media (min-width: 769px) {
  .benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    justify-items: center;
  }
}

.benefit-circle {
  width: 280px;
  height: 280px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  transition: all 0.3s ease;
  box-shadow: 0 2px 12px var(--shadow);
  position: relative;
}

.benefit-circle:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 24px var(--shadow);
  border-color: var(--primary);
}

.circle-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--primary), #0056b3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: white;
}

.benefit-title {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--fg);
  margin-bottom: 1rem;
}

.benefit-description {
  font-size: 1.1rem;
  line-height: 1.5;
  color: var(--muted);
}

/* Closure Section */
.closure-section {
  padding: 1.5rem 1rem;
  background: transparent;
  color: var(--fg);
}

.closure-container {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
}

.closure-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 50px;
  padding: 2rem 3rem;
  text-align: center;
  box-shadow: 0 4px 20px var(--shadow);
}

.closure-title {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
}

.closure-subtitle {
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--muted);
}

.closure-actions {
  margin-bottom: 1rem;
  display: flex;
  justify-content: center;
}

.closure-actions .btn-primary.btn-large {
  background: var(--primary);
  color: white;
  box-shadow: 0 4px 20px rgba(0, 122, 255, 0.3);
}

.closure-actions .btn-primary.btn-large:hover {
  background: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 122, 255, 0.4);
}

.closure-benefits {
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.benefit-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--fg);
}

.benefit-item svg {
  color: #34c759;
}

/* Responsive Design */
@media (max-width: 768px) {
  .welcome-section {
    min-height: 50vh;
    padding: 1.5rem 1rem 0.5rem 1rem;
  }
  
  .welcome-title {
    font-size: 3rem;
  }
  
  .welcome-subtitle {
    font-size: 1.2rem;
  }
  
  .welcome-actions {
    flex-direction: column;
    align-items: center;
  }
  
  .welcome-pill {
    padding: 1.5rem 2rem;
  }
  
  .intro-section {
    padding: 1rem;
  }
  
  .intro-pill {
    padding: 1.5rem 2rem;
  }
  
  .intro-stats {
    flex-direction: column;
    gap: 1rem;
  }
  
  .benefits-section {
    padding: 1rem;
  }
  
  .benefits-grid {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
  }
  
  .benefit-circle {
    width: 250px;
    height: 250px;
  }
  
  .closure-section {
    padding: 1rem;
  }
  
  .closure-benefits {
    flex-direction: row;
    justify-content: center;
    gap: 1rem;
    align-items: center;
  }
  
  .benefits-title {
    font-size: 2.5rem;
  }
  
  .closure-title {
    font-size: 2.5rem;
  }
  
  .closure-pill {
    padding: 1.5rem 2rem;
  }
}

/* Mobile landscape ONLY - very specific targeting */
@media screen and (max-width: 768px) and (orientation: landscape) and (max-height: 500px) and (min-width: 480px) {
  .benefits-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
    justify-items: center;
    align-items: center;
    max-width: 100%;
  }
  
  .benefit-circle {
    width: 160px;
    height: 160px;
    margin: 0 auto;
  }
  
  .benefits-section {
    padding: 0.3rem;
  }
  
  .benefit-title {
    font-size: 0.9rem;
  }
  
  .benefit-description {
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .welcome-section {
    min-height: 45vh;
    padding: 1rem 1rem 0.5rem 1rem;
  }
  
  .welcome-title {
    font-size: 2.5rem;
  }
  
  .welcome-subtitle {
    font-size: 1.1rem;
  }
  
  .btn-large {
    padding: 0.875rem 1.5rem;
    font-size: 1rem;
  }
  
  .welcome-pill {
    padding: 1rem 1.5rem;
  }
  
  .intro-section {
    padding: 0.75rem;
  }
  
  .intro-pill {
    padding: 1rem 1.5rem;
  }
  
  .benefits-section {
    padding: 0.75rem;
  }
  
  .benefit-circle {
    width: 220px;
    height: 220px;
  }
  
  .benefits-grid {
    grid-template-columns: 1fr;
  }
  
  .closure-section {
    padding: 0.75rem;
  }
  
  .closure-benefits {
    flex-direction: row;
    justify-content: center;
    gap: 0;
    align-items: center;
    flex-wrap: wrap;
  }
  
  .closure-benefits .benefit-item {
    margin: 0;
    padding: 0;
  }
  
  .closure-pill {
    padding: 1rem 1.5rem;
  }
}

/* Main page iOS-inspired styling */
.main-container {
  height: 100vh;
  display: flex;
  align-items: flex-start; /* Change from center to flex-start to move content up */
  justify-content: center;
  padding: 8px;
  padding-top: 40px; /* Reduced top padding to move content closer to header */
  background: transparent;
  overflow: visible; /* Allow content to be visible and clickable */
  transform: none; /* Remove transform that might cause positioning issues */
}

.hero-section {
  width: 100%;
  max-width: 900px;
  text-align: center;
}

.hero-content {
  background: transparent;
  border-radius: 24px;
  padding: 20px 16px;
  box-shadow: none;
  border: none;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.app-icon {
  margin-bottom: 16px;
}

.icon-circle {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.3);
}

.icon-symbol {
  font-size: 32px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.hero-title {
  font-size: 4rem;
  font-weight: 400;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .hero-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.5rem;
  color: var(--muted);
  margin-bottom: 24px;
  line-height: 1.4;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  font-weight: 400;
}

.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn-primary {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 2px solid transparent;
  padding: 16px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  min-width: 140px;
  justify-content: center;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  border-color: #F47600;
  color: white;
}

.btn-secondary {
  background: var(--surface);
  color: var(--fg);
  border: 2px solid var(--border);
  padding: 14px 32px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: var(--bg);
  border-color: #F47600;
  color: var(--fg);
  transform: translateY(-2px);
}

.btn-icon {
  font-size: 18px;
  transition: transform 0.3s ease;
}

.btn-primary:hover .btn-icon {
  transform: translateX(4px);
}

/* Input and button elements with btn-primary class */
input.btn-primary,
input.btn-primary.btn,
button.btn-primary,
button.btn-primary.btn {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
  color: white !important;
  border: 2px solid transparent !important;
  border-radius: 50px !important;
  padding: 14px 32px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
  transition: all 0.3s ease !important;
  cursor: pointer !important;
}

/* Force white text on all btn-primary hover states */
.btn-primary:hover,
.btn.btn-primary:hover,
a.btn-primary:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
  color: white !important;
  border-color: #F47600 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4) !important;
}

input.btn-primary:hover,
input.btn-primary.btn:hover,
button.btn-primary:hover,
button.btn-primary.btn:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
  color: white !important;
  border-color: #F47600 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4) !important;
}

input.btn-danger,
input.btn-danger.btn,
button.btn-danger,
button.btn-danger.btn {
  background: #FF8000 !important;
  color: white !important;
  border: 2px solid transparent !important;
  border-radius: 50px !important;
  padding: 14px 32px !important;
  font-size: 16px !important;
  font-weight: 600 !important;
  box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3) !important;
  transition: all 0.3s ease !important;
  cursor: pointer !important;
}

input.btn-danger:hover,
input.btn-danger.btn:hover,
button.btn-danger:hover,
button.btn-danger.btn:hover {
  background: #FF8000 !important;
  border-color: #F47600 !important;
  color: white !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4) !important;
}

/* SPECIFIC FIX for Upgrade to Pro button */
a.btn-primary[href*="upgrade"]:hover,
a.btn-primary:hover {
  color: white !important;
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
}

/* Account page buttons now use liquid glass styles */

/* SPECIFIC FIX for pricing page Upgrade to Pro button */
/* Removed old pro-btn hover styles - now using btn-liquid-primary */

/* ========================================
   iOS-INSPIRED MOBILE DESIGN SYSTEM
   Mobile-first approach with iOS aesthetics
   ======================================== */

/* iOS Mobile Navigation */
@media (max-width: 768px) {
  .navbar {
    background: rgba(245, 245, 247, 0.15) !important;
    backdrop-filter: blur(40px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(40px) saturate(180%) !important;
    border-bottom: none;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 10001 !important;
    min-height: 60px !important;
    height: 60px !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    border-top-left-radius: 20px !important;
    border-top-right-radius: 20px !important;
    border-bottom-left-radius: 20px !important;
    border-bottom-right-radius: 20px !important;
  }
  
  [data-theme="dark"] .navbar {
    background: rgba(29, 29, 31, 0.15);
    border-bottom: none;
    box-shadow: none;
  }
  
  .navbar .container {
    padding: 12px 20px !important;
    min-height: 60px !important;
    height: 60px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    margin: 0 !important;
    max-width: none !important;
  }
  
  /* Button group container for theme toggle and hamburger */
  .navbar nav {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 12px !important;
    height: 60px !important;
    min-height: 60px !important;
    max-height: 60px !important;
    flex-shrink: 0 !important;
    position: relative !important;
    overflow: visible !important;
  }
  
  /* Ensure both buttons are perfectly aligned horizontally - center them in the same container */
  .theme-toggle.ios-toggle {
    width: auto !important;
    min-width: 91px !important;
    height: 31px !important;
    max-height: 31px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
    align-self: center !important;
    flex-shrink: 0 !important;
    position: relative !important;
    top: 0 !important;
    transform: none !important;
    vertical-align: middle !important;
    line-height: 31px !important;
  }
  
  .hamburger-menu {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    min-height: 30px !important;
    max-width: 30px !important;
    max-height: 30px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
    align-self: center !important;
    flex-shrink: 0 !important;
    position: relative !important;
    top: 0 !important;
    transform: none !important;
    vertical-align: middle !important;
    line-height: 30px !important;
  }
  
  /* Ensure nav-group doesn't affect button alignment when it's in nav */
  .navbar nav .nav-group {
    position: absolute !important;
    top: auto !important;
    bottom: auto !important;
    left: auto !important;
    right: auto !important;
    width: auto !important;
    height: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    flex: none !important;
    order: 999 !important;
    pointer-events: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
    display: none !important;
  }
  
  .brand {
    font-size: 20px;
    font-weight: 600;
    color: var(--fg);
    flex: 1;
    display: flex;
    align-items: center;
  }
  
  .brand img {
    height: 28px;
    margin-right: 2px;
  }
  
  /* iOS-style hamburger menu - MUST be visible on mobile */
  .hamburger-menu {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    min-height: 30px !important;
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    flex-direction: column !important;
    justify-content: space-around !important;
    background: transparent !important;
    border: none !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 !important;
    align-self: center !important;
    flex-shrink: 0 !important;
  }
  
  .hamburger-menu span {
    width: 20px !important;
    height: 2px !important;
    background: var(--fg) !important;
    border-radius: 1px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    transform-origin: center !important;
    display: block !important;
    flex-shrink: 0 !important;
  }
  
  .hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
  }
  
  .hamburger-menu.active span:nth-child(2) {
    opacity: 0;
  }
  
  .hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }
  
  /* iOS-style slide-out menu - appears on RIGHT side */
  .nav-group {
    position: fixed !important;
    top: 60px !important;
    right: -100% !important;
    left: auto !important;
    width: 50% !important;
    min-width: 250px !important;
    max-width: 300px !important;
    height: calc(100vh - 60px) !important;
    background: #ffffff !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-left: 0.5px solid #e0e0e0 !important;
    border-right: none !important;
    flex-direction: column !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
    padding: 20px 0 0 0 !important;
    transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1) !important;
    overflow-y: auto !important;
    z-index: 99999 !important; /* Above everything including hero section */
    pointer-events: none !important;
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
  }
  
  [data-theme="dark"] .nav-group {
    background: #2c2c2e !important;
    border-left-color: #3a3a3c !important;
  }
  
  .nav-group.active,
  .nav-group.mobile-menu-open {
    right: 0 !important;
    left: auto !important;
    pointer-events: auto !important;
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 99999 !important; /* Above everything including hero section */
  }
  
  /* Ensure mobile menu links are visible and clickable */
  .nav-group a {
    padding: 16px 24px !important;
    border: none !important;
    background: transparent !important;
    font-size: 17px !important;
    font-weight: 400 !important;
    text-align: left !important;
    margin: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    min-height: auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    color: var(--fg) !important;
    text-decoration: none !important;
    transition: background-color 0.2s ease !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    cursor: pointer;
    pointer-events: auto !important;
    touch-action: manipulation !important;
    z-index: 1002 !important;
    position: relative !important;
    -webkit-tap-highlight-color: rgba(0, 122, 255, 0.3);
    -webkit-touch-callout: default;
    -webkit-user-select: text;
    user-select: text;
  }
  
  .nav-group a:hover {
    background: rgba(0, 122, 255, 0.1);
    color: var(--primary);
    transform: none;
    box-shadow: none;
  }
  
  /* iOS-style theme toggle */
  .theme-toggle.ios-toggle {
    width: auto;
    height: 31px;
    border-radius: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: none;
    flex-shrink: 0;
    position: relative;
    top: 0;
    left: 0;
    transform: none !important;
    padding: 0;
    margin: 0;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
  }
  
  .theme-toggle.ios-toggle:active {
    transform: none !important;
  }
  
  .theme-toggle.ios-toggle .toggle-track {
    width: 51px;
    height: 31px;
  }
  
  .theme-toggle.ios-toggle .toggle-icon {
    width: 20px;
    height: 20px;
    position: relative;
  }
  
  .theme-toggle.ios-toggle .toggle-icon svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
  }
  
  .theme-toggle.ios-toggle .toggle-icon-sun {
    margin-right: 0;
  }
  
  .theme-toggle.ios-toggle .toggle-icon-moon {
    margin-left: 0;
  }
  
  .theme-toggle.ios-toggle .toggle-thumb {
    width: 27px;
    height: 27px;
    will-change: transform;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  }
  
  [data-theme="dark"] .theme-toggle.ios-toggle .toggle-thumb {
    transform: translateX(20px);
  }
  
  .theme-toggle.ios-toggle:hover .toggle-track {
    background: #b0b0b5;
  }
  
  [data-theme="dark"] .theme-toggle.ios-toggle:hover .toggle-track {
    background: #30d158;
  }
  
  .theme-toggle.ios-toggle:active .toggle-thumb {
    transform: scale(0.98);
    transition: transform 0.1s ease;
  }
  
  [data-theme="dark"] .theme-toggle.ios-toggle:active .toggle-thumb {
    transform: translateX(20px) scale(0.98);
    transition: transform 0.1s ease;
  }
  
  .theme-toggle.ios-toggle:focus {
    outline: none;
  }
  
  /* Hamburger menu positioning */
  .hamburger-menu {
    width: 30px;
    height: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    flex-shrink: 0;
    margin: 0;
  }
}

/* iOS Mobile Main Content - REMOVED CONFLICTING RULES */
  
  /* Dashboard cards are circular - styles defined in main .card rule above */
  
  /* Card border colors - Total Subscriptions and Total Monthly */
  .dashboard-container .cards .card:nth-child(1),
  .dashboard-container .cards .card:nth-child(2) {
    border-color: #788084 !important;
  }
  
  /* Paid and Remaining cards with circular styling */
  .dashboard-container .paid-card {
    border-color: #28a745 !important;
  }
  
  .dashboard-container .paid-card .card-title {
    color: #28a745 !important;
  }
  
  .dashboard-container .paid-amount {
    color: #28a745 !important;
  }
  
  .dashboard-container .remaining-card {
    border-color: #F47600 !important;
  }
  
  .dashboard-container .remaining-card .card-title {
    color: #F47600 !important;
  }
  
  .dashboard-container .remaining-amount {
    color: #F47600 !important;
  }
}

/* iOS Mobile Forms */
@media (max-width: 768px) {
  .auth-card {
    background: var(--surface);
    border-radius: 20px;
    padding: 32px 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 0.5px solid rgba(0, 0, 0, 0.05);
    margin: 20px auto;
    max-width: 100%;
  }
  
  [data-theme="dark"] .auth-card {
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  }
  
  .auth-card h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--fg);
    margin-bottom: 32px;
    text-align: center;
  }
  
  .form {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }
  
  .form label {
    font-size: 17px;
    font-weight: 400;
    color: var(--fg);
    margin-bottom: 8px;
    display: block;
  }
  
  .form input,
  .form textarea,
  .form select {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    color: var(--fg);
    font-size: 17px;
    font-weight: 400;
    transition: all 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
  }
  
  .form input:focus,
  .form textarea:focus,
  .form select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
    transform: scale(1.02);
  }
  
  /* iOS-style buttons */
  .btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px 24px;
    border: none;
    border-radius: 12px;
    font-size: 17px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 50px;
    width: 100%;
    -webkit-tap-highlight-color: transparent;
  }
  
  .btn-primary {
    background: var(--primary);
    color: white;
    box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
  }
  
  .btn-primary:hover {
    background: #0056b3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.4);
    color: white !important;
  }
  
  .btn-primary:active {
    transform: scale(0.98);
  }
  
  .btn-secondary {
    background: var(--surface);
    color: var(--fg);
    border: 1px solid var(--border);
  }
  
  .btn-secondary:hover {
    background: var(--border);
    transform: translateY(-1px);
  }
  
  /* iOS-style form groups */
  .form-group {
    margin-bottom: 20px;
  }
  
  .form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--fg);
  }
  
  .form-group input {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    color: var(--fg);
    font-size: 17px;
    font-weight: 400;
    transition: all 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
  }
  
  .form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.1);
    transform: scale(1.02);
  }
  
  /* iOS-style auth links */
  .auth-links {
    text-align: center;
    margin-top: 24px;
  }
  
  .auth-switch {
    font-size: 15px;
    color: var(--muted);
    margin: 0;
  }
  
  .auth-switch a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
  }
  
  .auth-switch a:hover {
    text-decoration: underline;
  }
  
  .forgot-password-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
  }
  
  .forgot-password-link:hover {
    text-decoration: underline;
  }
}

/* iOS Mobile Subscription Cards */
@media (max-width: 768px) {
  .subscription-card {
    background: var(--surface);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 0.5px solid rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
    width: 100%;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
  }
  
  [data-theme="dark"] .subscription-card {
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  }
  
  .subscription-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  }
  
  .mobile-subscriptions {
    display: block;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    padding: 24px;
    background: var(--surface);
    border-radius: 16px;
    box-shadow: 0 8px 32px var(--shadow);
    border: 1px solid var(--border);
    box-sizing: border-box;
  }
  
  .subscription-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
    gap: 12px;
    position: relative;
  }
  
  .subscription-name {
    font-size: 20px;
    font-weight: 600;
    color: var(--fg);
    flex: 1;
    line-height: 1.3;
    display: flex;
    align-items: center;
    gap: 8px;
    max-width: calc(100% - 80px);
  }
  
  .subscription-name .color-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
  }
  
  .subscription-amount {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
    text-align: right;
  }
  
  .subscription-detail-value.subscription-amount {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
  }
  
  .subscription-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
  }
  
  .subscription-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.05);
  }
  
  [data-theme="dark"] .subscription-detail {
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.1);
  }
  
  .subscription-detail:last-child {
    border-bottom: none;
  }
  
  .subscription-detail-label {
    font-size: 15px;
    color: var(--muted);
    font-weight: 400;
  }
  
  .subscription-detail-value {
    font-size: 15px;
    font-weight: 600;
    color: var(--fg);
    display: flex;
    align-items: center;
    gap: 8px;
  }
  
  .subscription-detail-value .passed-indicator {
    color: white;
    font-weight: 600;
    font-size: 10px;
    background: var(--success);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 2px solid var(--success);
  }
  
  .subscription-actions {
    display: flex;
    gap: 8px;
    margin-top: 20px;
    width: 100%;
  }
  
  .subscription-actions .btn {
    flex: 1 1 0;
    padding: 12px 8px;
    font-size: 15px;
    font-weight: 600;
    min-height: 44px;
    border-radius: 50px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    margin: 0;
  }
  
  .subscription-actions .btn-liquid-secondary,
  .subscription-actions .btn-liquid-danger {
    flex: 1 1 0 !important;
    min-width: 0 !important;
    width: 100% !important;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    padding: 0.875rem 1.25rem !important;
    font-size: 0.9rem !important;
    box-sizing: border-box !important;
  }
  
  .subscription-actions .delete-form {
    flex: 1 1 0 !important;
    margin: 0;
    padding: 0;
    display: flex;
    border: none;
    background: transparent;
    min-width: 0 !important;
    width: 100%;
  }
  
  .subscription-actions .delete-form button,
  .subscription-actions .delete-form .btn-liquid-danger {
    flex: 1 1 0 !important;
    width: 100% !important;
    margin: 0;
    padding: 0.875rem 1.25rem !important;
    font-size: 0.9rem !important;
    font-weight: 600;
    height: 44px !important;
    min-height: 44px !important;
    max-height: 44px !important;
    border-radius: 50px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    box-sizing: border-box !important;
    text-align: center;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0 !important;
  }
  
  .btn-edit {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    color: white;
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    min-height: 48px;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3);
  }
  
  .btn-edit:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4);
  }
  
  .btn-delete {
    background: #FF8000;
    color: white;
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    min-height: 48px;
    box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3);
  }
  
  .btn-delete:hover {
    background: #FF8000;
    border-color: #F47600;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4);
  }
}

/* iOS Mobile Table */
@media (max-width: 768px) {
  .table-container {
    background: var(--surface);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 0.5px solid rgba(0, 0, 0, 0.05);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  [data-theme="dark"] .table-container {
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  }
  
  .table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
    font-size: 15px;
  }
  
  .table th,
  .table td {
    padding: 12px 8px;
    text-align: left;
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.05);
    white-space: nowrap;
  }
  
  [data-theme="dark"] .table th,
  [data-theme="dark"] .table td {
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.1);
  }
  
  .table th {
    background: transparent;
    font-weight: 600;
    color: var(--muted);
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  
  .table td {
    color: var(--fg);
    font-weight: 400;
  }
  
  /* Due date cell with iOS styling */
  .due-date-cell {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
  }
  
  .passed-indicator {
    color: var(--success);
    font-weight: 600;
    font-size: 12px;
    background: rgba(52, 199, 89, 0.1);
    border-radius: 8px;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--success);
    animation: checkmark-pulse 2s ease-in-out infinite;
  }
  
  @keyframes checkmark-pulse {
    0%, 100% {
      transform: scale(1);
      opacity: 1;
    }
    50% {
      transform: scale(1.1);
      opacity: 0.8;
    }
  }
  
  [data-theme="dark"] .passed-indicator {
    background: rgba(52, 199, 89, 0.2);
    border-color: var(--success);
    color: var(--success);
  }
}

/* iOS Mobile Calendar */
@media (max-width: 768px) {
  .calendar-container {
    background: var(--surface);
    border-radius: 16px;
    padding: 20px;
    margin: 24px 0 40px 0; /* Add bottom margin for footer spacing */
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 0.5px solid rgba(0, 0, 0, 0.05);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  
  [data-theme="dark"] .calendar-container {
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  }
  
  .calendar {
    width: 100%;
    border-collapse: collapse;
    min-width: 400px;
  }
  
  .calendar th,
  .calendar td {
    padding: 8px 4px;
    font-size: 13px;
    border: 0.5px solid rgba(0, 0, 0, 0.05);
    text-align: center;
  }
  
  [data-theme="dark"] .calendar th,
  [data-theme="dark"] .calendar td {
    border: 0.5px solid rgba(255, 255, 255, 0.1);
  }
  
  .calendar th {
    background: transparent;
    font-weight: 600;
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  
  .calendar td {
    height: 36px;
    vertical-align: top;
    position: relative;
  }
  
  .calendar-day {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 500;
    color: var(--fg);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    min-height: 36px;
    background: transparent;
    padding: 2px;
    border: 1px solid var(--border);
  }
  
  .calendar-day:hover {
    background: rgba(0, 122, 255, 0.1);
  }
  
  .calendar-day.today {
    background: var(--surface) !important;
    color: var(--fg);
    font-weight: 600;
    border: 3px solid #F47600 !important;
    position: relative;
  }
  
  .calendar-day.today::before {
    display: none;
  }
  
  .calendar-day.today .calendar-day-number {
    position: absolute;
    z-index: 2;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    color: #F47600;
  }
  
  /* Ensure subscription colors show on today's date */
  .calendar-day.today.has-subscription .subscription-donut-chart {
    z-index: 1;
  }
  
  .calendar-day-number {
    display: block;
    font-weight: 500;
    margin: 0;
    color: inherit;
    line-height: 1;
  }
  
  .calendar-indicators {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 2px;
    margin-top: 2px;
    margin-bottom: 0;
  }
  
  .subscription-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
  }
  
  .subscription-checkmark {
    color: var(--success);
    font-weight: 600;
    font-size: 10px;
    background: rgba(52, 199, 89, 0.1);
    border-radius: 6px;
    width: 12px;
    height: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--success);
    margin: 1px auto 0;
    animation: checkmark-pulse 2s ease-in-out infinite;
  }
  
  .calendar-day.today .subscription-dot {
    border: 1px solid white;
  }
}

/* iOS Mobile Landing Page */
@media (max-width: 768px) {
  .hero-section {
    padding: 40px 20px;
    text-align: center;
    background: transparent;
    color: var(--fg);
    margin-bottom: 40px;
    min-height: calc(100vh - 60px);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0;
  }
  
  .hero-content {
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
  }
  
  .ios-text-container {
    background: var(--surface);
    border-radius: 20px;
    padding: 32px 24px;
    text-align: center;
    width: 100%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 0.5px solid rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    margin: 60px auto 16px auto;
  }
  
  [data-theme="dark"] .ios-text-container {
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  }
  
  .ios-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--fg);
    margin: 0 0 16px 0;
    line-height: 1.2;
    letter-spacing: -0.5px;
  }
  
  .ios-description {
    font-size: 16px;
    font-weight: 400;
    color: var(--muted);
    margin: 0;
    line-height: 1.5;
    letter-spacing: 0.2px;
  }
  
  .hero-actions {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    position: relative;
    z-index: 4; /* Ensure hero actions are above other elements */
    pointer-events: auto !important; /* Ensure container allows clicks */
  }
  
  .hero-actions .btn {
    padding: 16px 32px;
    font-size: 17px;
    font-weight: 600;
    border-radius: 14px;
    min-width: 200px;
    max-width: 280px;
    width: 100%;
    position: relative;
    z-index: 1000 !important; /* High z-index to ensure buttons are above other elements */
    pointer-events: auto !important; /* Force buttons to be clickable */
    cursor: pointer !important; /* Ensure cursor shows as clickable */
    touch-action: manipulation; /* Optimize for touch */
  }
  
/* =============================================================================
   SIMPLE MOBILE BUTTON FIX - NATURAL LIKE DESKTOP
   ============================================================================= */

/* Simple mobile button fixes - make them work naturally like desktop */
@media (max-width: 768px) {
  /* Just ensure buttons are clickable and properly sized for mobile */
  .hero-actions a.btn,
  .hero-actions a.btn-primary,
  .hero-actions a.btn-secondary {
    display: block !important;
    width: 100% !important;
    max-width: 300px !important;
    margin: 0 auto !important;
    padding: 1rem 2rem !important;
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    text-align: center !important;
    text-decoration: none !important;
    border-radius: 50px !important;
    min-height: 48px !important;
    line-height: 1.2 !important;
    cursor: pointer !important;
    touch-action: manipulation !important;
    pointer-events: auto !important;
    position: relative !important;
    z-index: 1000 !important;
    transition: all 0.3s ease !important;
  }
  
  .hero-actions a.btn-primary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    color: white !important;
    border: 2px solid transparent !important;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
  }
  
  .hero-actions a.btn-secondary {
    background: transparent !important;
    color: var(--fg) !important;
    border: 2px solid var(--border) !important;
  }
  
  /* Ensure child elements don't interfere */
  .hero-actions a.btn *,
  .hero-actions a.btn-primary *,
  .hero-actions a.btn-secondary * {
    pointer-events: none !important;
  }
}
  
  .hero-actions a.btn-primary:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4) !important;
    border-color: #F47600 !important;
    color: white !important;
  }
  
  .hero-actions a.btn-primary:active {
    transform: scale(0.98) !important;
  }
  
  .hero-actions a.btn-secondary:hover {
    background: var(--surface) !important;
    border-color: #F47600 !important;
    color: var(--fg) !important;
    transform: translateY(-2px) !important;
  }
  
  .hero-actions a.btn-secondary:active {
    transform: scale(0.98) !important;
  }
  
  /* Ensure link functionality works for both buttons */
  .hero-actions a.btn-primary:link,
  .hero-actions a.btn-primary:visited,
  .hero-actions a.btn-primary:hover,
  .hero-actions a.btn-primary:active,
  .hero-actions a.btn-secondary:link,
  .hero-actions a.btn-secondary:visited,
  .hero-actions a.btn-secondary:hover,
  .hero-actions a.btn-secondary:active {
    text-decoration: none !important;
    color: inherit !important;
  }
  
  /* Desktop-like btn-icon functionality for mobile */
  .hero-actions .btn-icon {
    font-size: 18px !important;
    transition: transform 0.3s ease !important;
  }
  
  .hero-actions a.btn-primary:hover .btn-icon {
    transform: translateX(4px) !important; /* Match desktop icon animation */
  }
  
  /* Force clickable area - prevent child elements from blocking clicks */
  .hero-actions a.btn-primary *,
  .hero-actions a.btn-secondary * {
    pointer-events: none !important; /* Prevent child elements from blocking clicks */
  }
  
  /* Ensure btn-text and btn-icon are clickable through parent */
  .hero-actions .btn-text,
  .hero-actions .btn-icon {
    pointer-events: none !important;
    user-select: none !important;
  }
}

/* Icon Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* iOS Mobile Animations */
@media (max-width: 768px) {
  @keyframes fadeOut {
    from {
      opacity: 1;
      transform: translateY(0);
    }
    to {
      opacity: 0;
      transform: translateY(-10px);
    }
  }
  
  @keyframes slideIn {
    from {
      opacity: 0;
      transform: translateY(-10px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  @keyframes slideInFromRight {
    from {
      transform: translateX(100%);
      opacity: 0;
    }
    to {
      transform: translateX(0);
      opacity: 1;
    }
  }
  
  @keyframes slideInFromBottom {
    from {
      transform: translateY(20px);
      opacity: 0;
    }
    to {
      transform: translateY(0);
      opacity: 1;
    }
  }
  
  .card {
    animation: slideInFromBottom 0.3s ease-out;
  }
  
  .nav-group.active {
    animation: slideInFromRight 0.3s ease-out;
  }
  
  /* iOS-style button press animation */
  .btn:active {
    transform: scale(0.96);
    transition: transform 0.1s ease;
  }
  
  /* Remove square animation from hamburger menu close on mobile - instant close */
  .hamburger-menu:active,
  .hamburger-menu.active:active {
    transform: none !important;
    transition: none !important;
    background: transparent !important;
  }
  
  .hamburger-menu.active span:active,
  .hamburger-menu.active span {
    transition: none !important;
  }
  
  /* Ensure hamburger menu closes instantly without animation on mobile */
  .hamburger-menu.active span:nth-child(1):active,
  .hamburger-menu.active span:nth-child(3):active {
    transform: inherit !important;
    transition: none !important;
  }
  
  /* iOS-style card hover */
  .card:hover {
    transform: translateY(-4px);
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  }
}

/* Desktop/Mobile View Controls */
.desktop-only {
  display: block;
}

.mobile-only {
  display: none;
}

@media (max-width: 768px) {
  .desktop-only {
    display: none !important;
  }
  
  .mobile-only {
    display: block !important;
  }
}

/* Dark theme adjustments */
[data-theme="dark"] .main-container {
  background: transparent;
}

/* Mobile responsive for main page */
@media (max-width: 768px) {
  .main-container {
    padding: 0;
    margin: 0;
    width: 100%;
    min-height: calc(100vh - 60px);
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1; /* Ensure proper stacking context */
    overflow: visible; /* Ensure content is not clipped */
    padding-top: 0; /* Remove all top padding to move content closer to header */
  }
  
  .main-container .hero-section {
    flex: 1;
    display: flex;
    align-items: flex-start; /* Change from center to flex-start to move content up */
    justify-content: center;
    padding: 0; /* Remove all padding to move content closer to header */
    position: relative;
    z-index: 2; /* Ensure hero section is above other elements */
    padding-top: 5px; /* Minimal top padding */
  }
  
  .hero-content {
    padding: 4px 12px; /* Further reduced padding to move content closer to header */
    border-radius: 20px;
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 3; /* Ensure hero content is above other elements */
  }
  
  .icon-circle {
    width: 64px;
    height: 64px;
    border-radius: 16px;
  }
  
  .icon-symbol {
    font-size: 24px;
  }
  
  .hero-title {
    font-size: 44px;
  }
  
  .hero-description {
    font-size: 28px;
    margin-bottom: 20px;
  }
  
  .hero-actions {
    flex-direction: column;
    align-items: center;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    max-width: 280px;
  }
}

/* =============================================================================
   UPGRADE PAGE STYLING
   ============================================================================= */

.upgrade-container {
  min-height: auto;
  background: var(--bg);
  padding: 48px 2rem 6rem 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.upgrade-content {
  max-width: 1200px;
  width: 100%;
  text-align: center;
}

.upgrade-header {
  margin-bottom: 4rem;
}

.upgrade-icon {
  margin-bottom: 2rem;
}

.upgrade-title {
  font-size: 3rem;
  font-weight: 400;
  margin-bottom: 3rem;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .upgrade-title {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.upgrade-subtitle {
  font-size: 1.25rem;
  color: var(--muted);
  margin-bottom: 0;
  font-weight: 400;
}

.pricing-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 3rem 2.5rem;
  margin-bottom: 3rem;
  border: 1px solid var(--border);
  box-shadow: none;
}

.pricing-header {
  margin-bottom: 32px;
}

.pricing-header h2 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.price {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
}

.currency {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
}

.amount {
  font-size: 48px;
  font-weight: 700;
  color: #007aff;
}

.plan-card .amount {
  font-size: 48px !important;
  font-weight: 700 !important;
}

.price .amount {
  font-size: 48px !important;
  font-weight: 700 !important;
}

/* Force Pro Plan dollar sign to be large */
.pro-plan .price .amount {
  font-size: 48px !important;
  font-weight: 700 !important;
  color: #007aff !important;
}

/* Force Free Plan text to be large */
.free-plan .price .amount {
  font-size: 48px !important;
  font-weight: 700 !important;
  color: #007aff !important;
}

/* Additional specificity for dollar sign */
.pro-plan .price .amount:first-child {
  font-size: 48px !important;
  font-weight: 700 !important;
  color: #007aff !important;
}

.period {
  font-size: 18px;
  color: var(--text-secondary);
}

.features-list {
  margin-bottom: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.feature-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-color);
  min-height: 35px;
}

.feature-item:last-child {
  border-bottom: none;
}


.feature-text {
  font-size: 22px;
  color: var(--text-primary);
  font-weight: 500;
}


.upgrade-btn {
  width: 100%;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 16px;
  padding: 20px 32px;
  font-size: 20px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}

.upgrade-btn:hover {
  background: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(0, 122, 255, 0.3);
}

.upgrade-btn:disabled {
  background: var(--text-secondary);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-icon {
  font-size: 16px;
  transition: transform 0.3s ease;
}

.upgrade-btn:hover .btn-icon {
  transform: translateX(4px);
}

.upgrade-note {
  font-size: 14px;
  color: var(--text-secondary);
  margin: 0;
}

.upgrade-benefits {
  margin-top: 4rem;
  padding-top: 4rem;
  border-top: 1px solid var(--border);
}

.upgrade-benefits h3 {
  font-size: 2rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 3rem;
  letter-spacing: -0.01em;
  text-align: center;
}

.upgrade-benefits .benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem;
}

.upgrade-benefits .benefit-item {
  background: transparent;
  border-radius: 0;
  padding: 0;
  border: none;
  text-align: left;
  display: block !important;
  box-shadow: none;
}

.upgrade-benefits .benefit-item h4 {
  font-size: 1.25rem;
  font-weight: 400;
  color: var(--fg);
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}

.upgrade-benefits .benefit-item p {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.6;
  margin: 0;
  font-weight: 400;
}

/* Dark theme adjustments */
[data-theme="dark"] .upgrade-container {
  background: transparent;
}

/* Remove background colors for analytics page in dark theme */
[data-theme="dark"] .analytics-container {
  background: transparent;
}

[data-theme="dark"] .current-limits {
  background: #3d2f00;
  border-color: #6c5ce7;
}

[data-theme="dark"] .current-limits h3 {
  color: #fdcb6e;
}

[data-theme="dark"] .limit-text {
  color: #fdcb6e;
}

/* New Plans Grid Layout */
.plans-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
  margin-bottom: 48px;
}

.plan-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 3rem 2.5rem;
  border: 1px solid var(--border);
  box-shadow: none;
  position: relative;
  min-height: auto;
  display: flex;
  flex-direction: column;
  transition: border-color 0.2s ease;
}

.plan-card:hover {
  border-color: var(--fg);
}

.pro-plan {
  border: 1px solid var(--fg);
  transform: none;
}

.pro-plan::before {
  content: "Most Popular";
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  padding: 8px 24px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
}

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

.plan-header h2 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 12px;
}

.plan-limits {
  background: var(--surface);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 20px;
}

.limit-text {
  font-size: 16px;
  color: var(--text-secondary);
  margin: 0;
  font-weight: 500;
}

.plan-benefits {
  background: var(--surface);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 20px;
}

.benefit-text {
  font-size: 16px;
  color: #F47600;
  margin: 0;
  font-weight: 600;
}

.plan-btn {
  width: 100%;
  border: 2px solid transparent;
  border-radius: 50px;
  padding: 20px 32px;
  font-size: 20px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.free-btn {
  background: var(--surface);
  color: var(--text-secondary);
  cursor: not-allowed;
}

.pro-btn {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
}

.pro-btn:hover {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  border-color: #F47600;
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(244, 118, 0, 0.3);
}

.pro-btn:disabled {
  background: var(--text-secondary);
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Mobile responsive for upgrade page */
@media (max-width: 768px) {
  .upgrade-container {
    padding: 3rem 1.5rem;
  }
  
  .upgrade-content {
    padding: 0;
  }
  
  .upgrade-header {
    margin-bottom: 3rem;
  }
  
  .upgrade-title {
    font-size: 2.25rem;
    font-weight: 400;
    letter-spacing: -0.02em;
    margin-bottom: 0;
  }
  
  .upgrade-subtitle {
    font-size: 1.1rem;
    font-weight: 400;
  }
  
  .pricing-card {
    padding: 2.5rem 2rem;
    border-radius: 16px;
    box-shadow: none;
    overflow: visible !important;
  }
  
  .upgrade-benefits {
    margin-top: 3rem;
    padding-top: 3rem;
  }
  
  .upgrade-benefits h3 {
    font-size: 1.75rem;
    margin-bottom: 2rem;
  }
  
  .upgrade-benefits .benefits-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .amount {
    font-size: 36px;
  }
  
  .plans-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  
  .pro-plan {
    transform: none;
  }
  
  .upgrade-benefits .benefits-grid {
    grid-template-columns: 1fr;
  }
}

/* =============================================================================
   TIER STATUS STYLING
   ============================================================================= */

.tier-status-container {
  margin: -8px 0 0 0;
}

.tier-status-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 2.5rem 2rem;
  border: 1px solid var(--border);
  box-shadow: none;
}

.tier-info {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.tier-badge {
  padding: 8px 16px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.tier-badge.free {
  background: #e3f2fd;
  color: #1976d2;
  border: 1px solid #bbdefb;
}

.tier-badge.pro {
  background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
  color: white;
  border: 1px solid #F47600;
}

.tier-details {
  flex: 1;
  text-align: center;
}

.tier-details h3 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 12px 0;
}

.tier-details p {
  font-size: 18px;
  font-weight: 500;
  color: var(--text-primary);
  margin: 0 0 16px 0;
}

.upgrade-prompt {
  background: #fff3cd;
  border: 1px solid #ffeaa7;
  border-radius: 8px;
  padding: 16px;
  margin-top: 12px;
}

.upgrade-prompt p {
  margin: 0 0 12px 0;
  color: #856404;
  font-weight: 500;
}

.upgrade-suggestion {
  margin-top: 12px;
}

.upgrade-suggestion p {
  margin: 0;
  font-size: 14px;
  color: var(--text-secondary);
}

.upgrade-suggestion a {
  color: #007aff;
  text-decoration: none;
  font-weight: 500;
}

.upgrade-suggestion a:hover {
  text-decoration: underline;
}

/* Dark theme adjustments */
[data-theme="dark"] .tier-badge.free {
  background: #1a237e;
  color: #90caf9;
  border-color: #3f51b5;
}

[data-theme="dark"] .upgrade-prompt {
  background: #3d2f00;
  border-color: #6c5ce7;
}

[data-theme="dark"] .upgrade-prompt p {
  color: #fdcb6e;
}

/* Mobile responsive */
@media (max-width: 768px) {
  /* Ensure all buttons on mobile have the circular teal gradient style */
  .actions .btn,
  .actions .btn-primary,
  .upgrade-prompt .btn,
  .upgrade-prompt .btn-primary,
  .tier-status-card .btn,
  .tier-status-card .btn-primary,
  .account-page .btn-liquid-primary,
  .account-page .btn-liquid-secondary,
  .account-page .btn-liquid-danger {
    width: 100%;
    max-width: 300px;
    font-size: 1.125rem;
  }
  
  .account-page .btn-primary {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    color: white !important;
    border: 2px solid transparent !important;
    border-radius: 50px !important;
    padding: 14px 32px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
    transition: all 0.3s ease !important;
  }
  
  .actions .btn:hover,
  .actions .btn-primary:hover,
  .upgrade-prompt .btn:hover,
  .upgrade-prompt .btn-primary:hover,
  .tier-status-card .btn:hover,
  .tier-status-card .btn-primary:hover,
  .account-page .btn-primary:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    border-color: #F47600 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4) !important;
  }
  
  /* Ensure button groups (Edit/Delete) match desktop exactly */
  .btn-group .btn-secondary,
  .btn-group .btn-edit {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    color: white !important;
    border: 2px solid transparent !important;
    border-radius: 50px !important;
    padding: 14px 32px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 16px rgba(244, 118, 0, 0.3) !important;
    transition: all 0.3s ease !important;
  }
  
  .btn-group .btn-secondary:hover,
  .btn-group .btn-edit:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%) !important;
    border-color: #F47600 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 24px rgba(244, 118, 0, 0.4) !important;
  }
  
  .btn-group .btn-danger,
  .btn-group .btn-delete {
    background: #FF8000 !important;
    color: white !important;
    border: 2px solid transparent !important;
    border-radius: 50px !important;
    padding: 14px 32px !important;
    font-size: 16px !important;
    font-weight: 600 !important;
    box-shadow: 0 4px 16px rgba(255, 128, 0, 0.3) !important;
    transition: all 0.3s ease !important;
  }
  
  .btn-group .btn-danger:hover,
  .btn-group .btn-delete:hover {
    background: #FF8000 !important;
    border-color: #F47600 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 24px rgba(255, 128, 0, 0.4) !important;
  }
  
  /* Override subscription-actions to ensure circular buttons */
  .subscription-actions .btn,
  .subscription-actions .btn-secondary,
  .subscription-actions .btn-danger {
    border-radius: 50px !important;
  }
  
  .tier-info {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
  }
  
  .tier-status-card {
    padding: 10px;
  }
  
  .tier-details h3 {
    font-size: 22px;
  }
  
  .tier-details p {
    font-size: 16px;
  }
}

/* Contact Form Textarea Styling */
textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background-color: var(--surface);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  resize: vertical;
  min-height: 100px;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}

/* Dark theme textarea */
[data-theme="dark"] textarea {
  background-color: #2c2c2e;
  border-color: #3a3a3c;
  color: #ffffff;
}

[data-theme="dark"] textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.1);
}

[data-theme="dark"] textarea::placeholder {
  color: #8e8e93;
}

/* Contact Page Styling */
.contact-page {
  max-width: 600px !important; /* Better width for contact form */
  padding: 48px 2rem 6rem 2rem;
}

.contact-page h2 {
  font-size: 3rem;
  font-weight: 400;
  margin-bottom: 3rem;
  letter-spacing: -0.02em;
  text-align: center;
  background: linear-gradient(135deg, #F47600 0%, #000000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Dark theme - use white instead of black for better visibility */
[data-theme="dark"] .contact-page h2 {
  background: linear-gradient(135deg, #F47600 0%, #ffffff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.contact-page .auth-card {
  max-width: 100%;
  margin: 0 auto;
}

.contact-intro {
  text-align: center;
  margin-bottom: 2rem;
}

.contact-intro h3 {
  color: var(--fg);
  font-size: 1.5rem;
  font-weight: 400;
  margin: 0;
  letter-spacing: -0.01em;
}

/* Responsive contact form improvements */
.contact-page .auth-card {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.contact-page .auth-card textarea {
  resize: vertical;
  min-height: 120px;
}

/* Contact form specific styling */
.contact-form-card .form {
  max-width: 100%;
  gap: 28px;
}

/* Contact form button centering for desktop */
.contact-form-card .btn {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  display: block;
  text-align: center;
}

/* Contact page liquid glass button */
.contact-page .btn-liquid-primary {
  width: 100%;
  max-width: 300px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
}

/* Force button centering on landscape/larger mobile (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
  /* Override flex display for contact page forms - use grid */
  .contact-page .auth-card .form,
  .contact-page .centered.auth-card .form,
  .contact-page .centered .auth-card .form {
    display: grid !important;
    gap: 20px !important;
    align-items: stretch !important;
    justify-items: stretch !important;
  }
  
  /* Center the button - works with grid layout */
  .contact-page .auth-card .form button,
  .contact-page .auth-card .form .btn-liquid-primary,
  .contact-page .auth-card .form button[type="submit"],
  .contact-page .centered.auth-card .form button,
  .contact-page .centered.auth-card .form .btn-liquid-primary,
  .contact-page .centered.auth-card .form button[type="submit"],
  .contact-page .centered .auth-card .form button,
  .contact-page .centered .auth-card .form .btn-liquid-primary,
  .contact-page .centered .auth-card .form button[type="submit"] {
    grid-column: 1 / -1 !important;
    justify-self: center !important;
    align-self: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
    width: 100% !important;
    max-width: 300px !important;
    display: flex !important;
    justify-content: center !important;
  }
  
  /* If form is still flex (fallback), center button */
  .contact-page .centered.auth-card .form[style*="flex"] button,
  .contact-page .centered.auth-card .form[style*="flex"] .btn-liquid-primary {
    align-self: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }
}

/* Center button on tablets and larger mobile screens */
@media (min-width: 481px) {
  .contact-page .form {
    display: grid;
    gap: 20px;
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
  }
  
  .contact-page .form button.btn-liquid-primary {
    grid-column: 1 / -1;
    justify-self: center;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    justify-content: center;
    width: 100%;
    max-width: 300px;
  }
}

/* Center button on larger screens */
@media (min-width: 769px) {
  .contact-page .form {
    display: grid;
    gap: 20px;
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
  }
  
  .contact-page .form button.btn-liquid-primary {
    grid-column: 1 / -1;
    justify-self: center;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    justify-content: center;
    width: 100%;
    max-width: 300px;
  }
}

.contact-form-card label {
  display: block;
  margin-bottom: 20px;
  font-size: 18px;
  font-weight: 600;
  color: var(--fg);
}

.contact-form-card input[type="email"],
.contact-form-card input[type="text"] {
  width: 100%;
  padding: 20px;
  font-size: 18px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background-color: var(--surface);
  color: var(--fg);
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
}

.contact-form-card textarea {
  width: 100%;
  padding: 20px;
  font-size: 18px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background-color: var(--surface);
  color: var(--fg);
  box-sizing: border-box;
  resize: vertical;
  min-height: 140px;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  line-height: 1.5;
}

.contact-form-card input:focus,
.contact-form-card textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

/* Dark theme contact form */
[data-theme="dark"] .contact-form-card input[type="email"],
[data-theme="dark"] .contact-form-card input[type="text"],
[data-theme="dark"] .contact-form-card textarea {
  background-color: #2c2c2e;
  border-color: #3a3a3c;
  color: #ffffff;
}

[data-theme="dark"] .contact-form-card input:focus,
[data-theme="dark"] .contact-form-card textarea:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.1);
}


/* Center button on larger mobile/tablet screens (481px - 768px) - FINAL FIX */
@media (min-width: 481px) and (max-width: 768px) {
  /* Force form to use flexbox with center alignment */
  .contact-page .auth-card .form,
  .contact-page .centered.auth-card .form,
  .contact-page .centered .auth-card .form,
  .contact-page.centered .auth-card .form {
    display: flex !important;
    flex-direction: column !important;
    gap: 20px !important;
    align-items: center !important;
    max-width: 400px !important;
    width: 100% !important;
    margin: 0 auto !important;
  }
  
  /* Keep labels full width */
  .contact-page .auth-card .form label,
  .contact-page .centered.auth-card .form label,
  .contact-page .centered .auth-card .form label,
  .contact-page.centered .auth-card .form label {
    width: 100% !important;
    align-self: stretch !important;
  }
  
  /* Keep input and textarea elements full width */
  .contact-page .auth-card .form input,
  .contact-page .auth-card .form textarea,
  .contact-page .centered.auth-card .form input,
  .contact-page .centered.auth-card .form textarea,
  .contact-page .centered .auth-card .form input,
  .contact-page .centered .auth-card .form textarea,
  .contact-page.centered .auth-card .form input,
  .contact-page.centered .auth-card .form textarea {
    width: 100% !important;
    align-self: stretch !important;
  }
  
  /* CENTER THE BUTTON - All possible selectors */
  .contact-page .auth-card .form button,
  .contact-page .auth-card .form .btn-liquid-primary,
  .contact-page .auth-card .form button[type="submit"],
  .contact-page .auth-card .form button.btn-liquid-primary,
  .contact-page .centered.auth-card .form button,
  .contact-page .centered.auth-card .form .btn-liquid-primary,
  .contact-page .centered.auth-card .form button[type="submit"],
  .contact-page .centered.auth-card .form button.btn-liquid-primary,
  .contact-page .centered .auth-card .form button,
  .contact-page .centered .auth-card .form .btn-liquid-primary,
  .contact-page .centered .auth-card .form button[type="submit"],
  .contact-page .centered .auth-card .form button.btn-liquid-primary,
  .contact-page.centered .auth-card .form button,
  .contact-page.centered .auth-card .form .btn-liquid-primary,
  .contact-page.centered .auth-card .form button[type="submit"],
  .contact-page.centered .auth-card .form button.btn-liquid-primary {
    align-self: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
    width: 100% !important;
    max-width: 300px !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
  }
}

/* Mobile responsive contact page */
@media (max-width: 768px) {
  .contact-page {
    max-width: 100% !important;
    padding: 3rem 1.5rem !important;
  }
  
  .contact-page h2 {
    font-size: 2.25rem !important;
    margin-bottom: 0 !important;
  }
  
  .contact-page .auth-card {
    padding: 2.5rem 2rem;
    border-radius: 16px;
    box-shadow: none;
  }
  
  .contact-intro {
    margin-bottom: 2rem;
  }
  
  .contact-intro h3 {
    font-size: 1.35rem;
    font-weight: 400;
  }
  
  .contact-page .auth-card label {
    font-size: 16px;
  }
  
  .contact-page .auth-card input[type="email"],
  .contact-page .auth-card input[type="text"],
  .contact-page .auth-card textarea {
    font-size: 16px;
    padding: 16px;
  }
  
  .contact-page .auth-card .btn {
    width: 100%;
    max-width: 300px;
    margin: 0 auto;
    display: block;
    text-align: center;
  }
  
  /* Center button on larger mobile screens within mobile breakpoint */
  .contact-page .form button.btn-liquid-primary {
    grid-column: 1 / -1;
    justify-self: center;
    margin-left: auto !important;
    margin-right: auto !important;
    display: flex !important;
    justify-content: center !important;
    width: 100%;
    max-width: 300px;
  }
  
  
  /* Mobile container optimization */
  .container {
    padding: 20px 16px;
    max-width: 100%;
    min-height: calc(100vh - 140px);
  }
  
  .centered {
    padding: 20px 16px;
    gap: 20px;
    max-width: calc(100vw - 32px);
    margin: 0 auto;
    min-height: calc(100vh - 140px);
  }
  
  /* Mobile form optimization */
  .form {
    gap: 20px;
    max-width: 100%;
  }
  
  .form input,
  .form textarea,
  .form select {
    font-size: 16px;
    padding: 16px;
    border-radius: 12px;
    -webkit-appearance: none;
    appearance: none;
  }
  
  /* Mobile button optimization */
  .btn {
    font-size: 16px;
    padding: 16px 24px;
    border-radius: 12px;
    min-height: 48px;
    touch-action: manipulation;
  }
  
  /* Mobile search optimization */
  .search-container {
    margin-bottom: 20px;
  }
  
  .search-container input {
    font-size: 16px;
    padding: 12px 16px;
    border-radius: 12px;
  }
  
  /* Mobile calendar optimization */
  .calendar-container {
    margin: 24px 0 40px 0; /* Add bottom margin for footer spacing */
    padding: 16px;
    background: var(--surface);
    border-radius: 16px;
    border: 1px solid var(--border);
  }
  
  .calendar-header {
    margin-bottom: 16px;
  }
  
  .calendar-header h4 {
    font-size: 18px;
    font-weight: 700;
    color: var(--fg);
  }
  
  .calendar-nav {
    width: 40px;
    height: 40px;
    border-radius: 16px;
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    border: none;
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 20px rgba(244, 118, 0, 0.3);
    line-height: 40px;
    padding: 0;
    margin: 0;
    text-align: center;
  }
  
  .calendar-nav:hover {
    background: linear-gradient(135deg, #F47600 0%, #F47600 100%);
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 10px 28px rgba(244, 118, 0, 0.4);
  }
  
  .calendar-grid {
    width: 100%;
  }
  
  .calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    margin-bottom: 8px;
  }
  
  .weekday {
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: var(--muted);
    padding: 8px 2px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
  
  .calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
  }
  
  .calendar-day {
    aspect-ratio: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    color: var(--fg);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    min-height: 40px;
    background: var(--surface);
    padding: 2px;
    border: 1px solid var(--border);
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
  }
  
  .calendar-day:hover {
    background: var(--bg);
    transform: translateY(-1px);
  }
  
  .calendar-day.today {
    background: var(--surface) !important;
    color: var(--fg);
    font-weight: 700;
    border: 3px solid #F47600 !important;
    position: relative;
  }
  
  .calendar-day.today::before {
    display: none;
  }
  
  [data-theme="dark"] .calendar-day.today::before {
    display: none;
  }
  
  .calendar-day.today .calendar-day-number {
    position: absolute;
    z-index: 2;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    color: #F47600;
  }
  
  [data-theme="dark"] .calendar-day.today .calendar-day-number {
    color: #F47600;
  }
  
  /* Ensure subscription colors show on today's date */
  .calendar-day.today.has-subscription .subscription-donut-chart {
    z-index: 1;
  }
  
  .calendar-day.has-subscription {
    background: var(--surface) !important;
    border: 1px solid var(--border) !important;
  }
  
  /* Don't override border for today or passed dates - let their specific borders show */
  .calendar-day.has-subscription.today {
    border: 3px solid #F47600 !important;
  }
  
  .calendar-day.has-subscription.passed {
    border: 2px solid #28a745 !important;
  }
  
  .calendar-day.has-subscription::before {
    display: none;
  }
  
  [data-theme="dark"] .calendar-day.has-subscription::before {
    display: none;
  }
  
  .calendar-day.has-subscription:hover::before {
    display: none;
  }
  
  .calendar-day.passed {
    border: 2px solid #28a745 !important;
  }
  
  .calendar-day.paid {
    background: rgba(40, 167, 69, 0.1);
    border: 1px solid rgba(40, 167, 69, 0.3);
  }
  
  .calendar-day.paid::after {
    content: '✓';
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 10px;
    color: #28a745;
    font-weight: bold;
  }
  
  .subscription-indicator {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin: 1px;
    display: inline-block;
  }
  
  /* Mobile tooltip styles */
  .mobile-tooltip {
    position: fixed !important;
    z-index: 10002 !important;
    pointer-events: none !important;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
  }
  
  /* Mobile and Tablet (up to 1024px) - works in portrait, landscape, and all orientations */
  @media (max-width: 1024px), (max-height: 1024px) {
    .mobile-tooltip {
      max-width: calc(100vw - 20px) !important;
      white-space: normal !important;
      text-align: center;
      line-height: 1.4;
      position: fixed !important;
      z-index: 10002 !important;
    }
  }
  
  /* Landscape mode support */
  @media (orientation: landscape) and (max-width: 1024px) {
    .mobile-tooltip {
      max-width: calc(100vw - 20px) !important;
      white-space: normal !important;
      text-align: center;
      line-height: 1.4;
      position: fixed !important;
      z-index: 10002 !important;
    }
  }
  
  /* Mobile flash messages */
  .flash-list {
    margin: 16px 0;
  }
  
  .flash {
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 14px;
    margin-bottom: 8px;
  }
}

/* Desktop navigation - hide hamburger menu */
@media (min-width: 769px) {
/* Hamburger menu hidden on desktop by default */
@media (min-width: 769px) {
  .hamburger-menu {
    display: none;
  }
  }
  
  .nav-group {
    position: static;
    width: auto;
    height: auto;
    background: transparent;
    border: none;
    padding: 0;
    flex-direction: row;
    gap: 8px;
    box-shadow: none;
    align-items: center;
  }
  
  .nav-group a {
    padding: 0;
    background: transparent;
    border: none;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    color: var(--fg);
    transition: color 0.2s ease;
  }
  
  .nav-group a:hover {
    background: transparent;
    color: var(--primary);
    transform: none;
  }
  
  .theme-toggle {
    position: static;
    top: auto;
    right: auto;
  }
  
  /* Desktop calendar indicators */
  .subscription-checkmark {
    color: #28a745;
    font-weight: bold;
    font-size: 12px;
    background: rgba(40, 167, 69, 0.1);
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #28a745;
    margin: 1px auto 0;
    animation: checkmark-pulse 2s ease-in-out infinite;
  }
  
  .subscription-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
  }
  
  .calendar-indicators {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 2px;
    margin-top: 2px;
    margin-bottom: 0;
  }
  
  .calendar-day-number {
    display: block;
    font-weight: 600;
    margin: 0;
    color: var(--fg);
    line-height: 1;
  }
}

/* Navigation tier badge styles removed - no longer needed */

/* MOBILE SCROLLING FIX - MOBILE ONLY */
@media (max-width: 767px) {
  /* Basic mobile scrolling optimization */
  html {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
  }
  
  body {
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
  }
  
  /* Fix main-page class for mobile */
  body.main-page {
    height: auto !important;
    overflow: visible !important;
    overflow-y: auto !important;
  }
  
  /* Ensure main container allows scrolling */
  main.container {
    overflow: visible !important;
  }
  
  /* Fix specific page containers */
  .analytics-container,
  .upgrade-container,
  .account-page .centered,
  .contact-page {
    min-height: auto !important;
    height: auto !important;
    overflow: visible !important;
  }
  
  /* Optimize scrolling performance */
  .chart-container,
  .plans-grid,
  .account-sections-grid,
  .contact-form-card {
    -webkit-overflow-scrolling: touch;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
  }
}

/* DESKTOP ANALYTICS RESTORE - SQUARESPACE STYLE */
@media (min-width: 769px) {
  .chart-container {
    padding: 3rem 2.5rem !important;
    margin-bottom: 3rem !important;
    border-radius: 16px !important;
    box-shadow: none !important;
  }
  
  .chart-wrapper {
    height: 800px !important;
    margin: 0 !important;
  }
  
  .chart-header h2 {
    font-size: 2rem !important;
    font-weight: 400 !important;
    margin-bottom: 2rem !important;
    letter-spacing: -0.01em !important;
  }
  
}

/* Desktop only - 4 in one row (1025px+) - MUST override tablet 2x2 */
@media (min-width: 1025px) {
  .dashboard-container .cards {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    margin: 0 auto 32px auto !important;
    width: 100% !important;
    max-width: 100% !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
  }
  
  .dashboard-container .cards .card {
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(3) {
    grid-column: 3 !important;
    grid-row: 1 !important;
  }
  
  .dashboard-container .cards .card:nth-child(4) {
    grid-column: 4 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 20px !important;
    margin: 0 auto 32px auto !important;
    width: 100% !important;
    max-width: 100% !important;
    justify-items: center !important;
    place-items: center !important;
    justify-content: center !important;
    align-content: center !important;
  }
  
  .analytics-summary .summary-card.card {
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(1) {
    grid-column: 1 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(2) {
    grid-column: 2 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(3) {
    grid-column: 3 !important;
    grid-row: 1 !important;
  }
  
  .analytics-summary .summary-card.card:nth-child(4) {
    grid-column: 4 !important;
    grid-row: 1 !important;
  }
}

/* Desktop card styles (769px+) */
@media (min-width: 769px) {
  .summary-card.card {
    border: 3px solid var(--border) !important;
    border-radius: 20px !important;
    padding: 2.5rem !important;
    background: var(--surface) !important;
    width: 300px !important;
    height: 300px !important;
    box-shadow: 0 4px 12px var(--shadow) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    margin: 0 !important;
  }
  
  .summary-card.card:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 6px 20px var(--shadow) !important;
  }
  
  .summary-card.card .card-title {
    color: var(--muted) !important;
    font-size: 1.1rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    font-weight: 500 !important;
    margin-bottom: 0.75rem !important;
  }
  
  .summary-card.card .card-value {
    font-size: 2.4rem !important;
    font-weight: 600 !important;
    color: var(--fg) !important;
    line-height: 1.2 !important;
  }
  
  .summary-card.card .card-value.insight-positive {
    color: #ff8c00 !important;
  }
  
  .summary-card.card .card-value.insight-negative {
    color: #28a745 !important;
  }
  
  .summary-card.card .card-value.insight-neutral {
    color: #F47600 !important;
  }
  
  /* Desktop color customization - use same base styles as local */
  /* Removed desktop-specific overrides to match local PyCharm styling */
}

/* DESKTOP CARDS LAYOUT - 2x2 GRID */
@media (min-width: 769px) {
  .cards {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 20px !important;
    margin-bottom: 32px !important;
    padding: 0 !important;
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

/* MOBILE NAV-GROUP LINKS AND BUTTONS - MOBILE ONLY */
@media (max-width: 767px) {
  .nav-group a,
  .nav-group .nav-button {
    pointer-events: auto !important;
    cursor: pointer !important;
    touch-action: manipulation !important;
    z-index: 1001 !important;
    position: relative !important;
    -webkit-tap-highlight-color: rgba(0, 122, 255, 0.3) !important;
    -webkit-touch-callout: none !important;
    -webkit-user-select: none !important;
    user-select: none !important;
  }
  
  .nav-group a:active,
  .nav-group .nav-button:active {
    background: rgba(0, 122, 255, 0.1) !important;
    transform: none !important;
  }
  
  /* Make nav-button look exactly like nav links */
  .nav-group .nav-button {
    padding: 16px 24px !important;
    border: none !important;
    background: transparent !important;
    font-size: 17px !important;
    font-weight: 400 !important;
    text-align: left !important;
    margin: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    min-height: auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    color: var(--fg) !important;
    text-decoration: none !important;
    transition: background-color 0.2s ease !important;
    width: 100% !important;
    font-family: inherit !important;
  }
}

/* Desktop calendar styling - Force override with !important */
@media (min-width: 769px) {
  .calendar-day.has-subscription::before {
    display: none !important;
  }
  
  .calendar-day.today::before {
    display: none !important;
  }
  
  /* Ensure SVG donut chart matches faded circle exactly on desktop */
  .calendar-day.has-subscription .subscription-donut-chart {
    width: 100% !important;
    height: 100% !important;
  }
  
  .calendar-day {
    font-size: 32px !important;
    min-height: 70px !important;
    padding: 10px !important;
  }
  
  .calendar-day.today {
    font-size: 34px !important;
  }
  
  .weekday {
    font-size: 18px !important;
    padding: 14px 4px !important;
  }
  
  .calendar-header h4 {
    font-size: 28px !important;
  }
  
/* Auto-close mobile menu when links are clicked */
@media (max-width: 768px) {
  .nav-group a {
    display: block;
    transition: all 0.3s ease;
  }
  
  .nav-group a:active {
    background-color: rgba(0, 0, 0, 0.1);
  }
  
  /* Ensure menu closes when navigating */
  .nav-group a:focus {
    outline: none;
  }
}

/* Section Divider with Animated Teal Lines */
.section-divider {
  position: relative;
  width: 100vw;
  height: 120px;
  overflow: visible;
  background: transparent;
  margin: -60px calc(50% - 50vw);
  padding: 0;
  z-index: 1;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  clip-path: none;
  -webkit-clip-path: none;
  left: 0;