/**
 * MAKTOUB Page-Specific Styles
 * Version: 1.0.0
 * Author: WEBDEV
 *
 * Contents:
 * 1. Landing Page
 * 2. Login/Signup Pages
 * 3. Account Dashboard
 * 4. Address Page
 * 5. Plans & Subscription Page
 * 6. Contact Page
 * 7. Legal Pages (Privacy, Terms, Returns)
 * 8. Payment Pages
 */

/* ========================================
 * 1. LANDING PAGE
 * ======================================== */

/* Landing hero adjustments */
.landing-hero {
  text-align: center;
}

.landing-hero .hero-title span {
  color: var(--brand);
}

/* How it works section */
.how-it-works {
  counter-reset: step;
}

.how-it-works-item {
  display: flex;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.how-it-works-item:last-child {
  margin-bottom: 0;
}

.how-it-works-number {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand);
  color: var(--white);
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  border-radius: var(--radius-full);
}

.how-it-works-content {
  flex: 1;
}

.how-it-works-title {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-xs);
}

.how-it-works-description {
  font-size: var(--text-sm);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
}

/* FAQ section */
.faq-list {
  max-width: 720px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: var(--space-lg) 0;
  background: none;
  border: none;
  text-align: start;
  font-size: var(--text-base);
  font-weight: var(--font-medium);
  color: var(--text);
  cursor: pointer;
  transition: color var(--transition-fast);
}

.faq-question:hover {
  color: var(--brand);
}

.faq-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform var(--transition-fast);
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  padding-bottom: var(--space-lg);
  font-size: var(--text-sm);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
  display: none;
}

.faq-item.active .faq-answer {
  display: block;
}

/* Testimonials */
.testimonials-grid {
  display: grid;
  gap: var(--space-lg);
}

@media (min-width: 768px) {
  .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .testimonials-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.testimonial-card {
  padding: var(--space-xl);
}

.testimonial-quote {
  font-size: var(--text-sm);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-lg);
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.testimonial-avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  background-color: var(--brand-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand);
  font-weight: var(--font-bold);
}

.testimonial-name {
  font-size: var(--text-sm);
  font-weight: var(--font-bold);
  color: var(--text);
}

.testimonial-location {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* ========================================
 * 2. LOGIN / SIGNUP PAGES
 * ======================================== */

/* Password strength indicator */
.password-strength {
  margin-top: var(--space-sm);
}

.password-strength-bar {
  display: flex;
  gap: var(--space-xs);
  margin-bottom: var(--space-xs);
}

.password-strength-segment {
  flex: 1;
  height: 4px;
  background-color: var(--border);
  border-radius: var(--radius-full);
  transition: background-color var(--transition-fast);
}

.password-strength[data-strength="weak"] .password-strength-segment:first-child {
  background-color: var(--error);
}

.password-strength[data-strength="medium"] .password-strength-segment:nth-child(-n+2) {
  background-color: var(--warning);
}

.password-strength[data-strength="strong"] .password-strength-segment:nth-child(-n+3) {
  background-color: var(--success);
}

.password-strength[data-strength="very-strong"] .password-strength-segment {
  background-color: var(--success);
}

.password-strength-text {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* Phone input with country code */
.phone-input-group {
  display: flex;
  gap: var(--space-sm);
}

.phone-country-code {
  width: 100px;
  flex-shrink: 0;
}

.phone-number {
  flex: 1;
}

/* Terms checkbox in signup */
.terms-check {
  margin-top: var(--space-lg);
}

.terms-check a {
  color: var(--brand);
  text-decoration: none;
}

.terms-check a:hover {
  text-decoration: underline;
}

/* ========================================
 * 3. ACCOUNT DASHBOARD
 * ======================================== */

/* Welcome card */
.welcome-card {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  padding: var(--space-xl);
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-hover) 100%);
  color: var(--white);
  border-radius: var(--radius-xl);
  margin-bottom: var(--space-xl);
}

@media (min-width: 768px) {
  .welcome-card {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.welcome-content {
  flex: 1;
}

.welcome-greeting {
  font-size: var(--text-lg);
  opacity: 0.9;
  margin-bottom: var(--space-xs);
}

.welcome-name {
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
}

/* Subscription status card */
.subscription-status {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

@media (min-width: 768px) {
  .subscription-status {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.subscription-info {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.subscription-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-md);
  background-color: var(--success-bg);
  color: var(--success);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
}

.subscription-badge.inactive {
  background-color: var(--error-bg);
  color: var(--error);
}

.subscription-badge.paused {
  background-color: var(--warning-bg);
  color: var(--warning);
}

.subscription-details {
  font-size: var(--text-sm);
  color: var(--text-light);
}

/* Quick actions grid */
.quick-actions {
  display: grid;
  gap: var(--space-md);
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 768px) {
  .quick-actions {
    grid-template-columns: repeat(4, 1fr);
  }
}

.quick-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-lg);
  background-color: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.quick-action:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card-hover);
}

.quick-action-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand-light);
  border-radius: var(--radius-md);
  color: var(--brand);
}

.quick-action-icon svg {
  width: 24px;
  height: 24px;
}

.quick-action-label {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text);
  text-align: center;
}

/* ========================================
 * 4. ADDRESS PAGE
 * ======================================== */

/* Address list */
.address-list {
  display: grid;
  gap: var(--space-md);
}

.address-card {
  display: flex;
  gap: var(--space-lg);
  padding: var(--space-lg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: all var(--transition-fast);
}

.address-card:hover {
  border-color: var(--brand-light);
}

.address-card.default {
  border-color: var(--brand);
  background-color: var(--brand-lighter);
}

.address-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand-light);
  border-radius: var(--radius-md);
  color: var(--brand);
  flex-shrink: 0;
}

.address-icon svg {
  width: 24px;
  height: 24px;
}

.address-content {
  flex: 1;
  min-width: 0;
}

.address-header {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-xs);
}

.address-name {
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  color: var(--text);
}

.address-default-badge {
  padding: var(--space-xs) var(--space-sm);
  background-color: var(--brand);
  color: var(--white);
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  border-radius: var(--radius-full);
}

.address-details {
  font-size: var(--text-sm);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
}

.address-actions {
  display: flex;
  gap: var(--space-sm);
  flex-shrink: 0;
}

/* Add address button */
.add-address {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  padding: var(--space-xl);
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
  background: none;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.add-address:hover {
  border-color: var(--brand);
  background-color: var(--brand-lighter);
}

.add-address-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand-light);
  border-radius: var(--radius-full);
  color: var(--brand);
}

.add-address-text {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-light);
}

/* ========================================
 * 5. PLANS & SUBSCRIPTION PAGE
 * ======================================== */

/* Current plan display */
.current-plan {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
  padding: var(--space-xl);
  background: linear-gradient(135deg, var(--brand) 0%, var(--brand-hover) 100%);
  color: var(--white);
  border-radius: var(--radius-xl);
  margin-bottom: var(--space-xl);
}

@media (min-width: 768px) {
  .current-plan {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.current-plan-info h3 {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  margin-bottom: var(--space-sm);
}

.current-plan-details {
  font-size: var(--text-sm);
  opacity: 0.9;
}

.current-plan-price {
  text-align: center;
}

@media (min-width: 768px) {
  .current-plan-price {
    text-align: end;
  }
}

.current-plan-amount {
  font-size: var(--text-3xl);
  font-weight: var(--font-extrabold);
}

.current-plan-period {
  font-size: var(--text-sm);
  opacity: 0.8;
}

/* Billing history */
.billing-history {
  margin-top: var(--space-xl);
}

.billing-table {
  width: 100%;
  border-collapse: collapse;
}

.billing-table th,
.billing-table td {
  padding: var(--space-md);
  text-align: start;
  border-bottom: 1px solid var(--border);
}

.billing-table th {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-muted);
}

.billing-table td {
  font-size: var(--text-sm);
  color: var(--text);
}

.billing-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-full);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
}

.billing-status.paid {
  background-color: var(--success-bg);
  color: var(--success);
}

.billing-status.pending {
  background-color: var(--warning-bg);
  color: var(--warning);
}

.billing-status.failed {
  background-color: var(--error-bg);
  color: var(--error);
}

/* ========================================
 * 6. CONTACT PAGE
 * Task: WD-039a - UXLEAD Specification
 * ======================================== */

/* Page Header */
.page-header {
  text-align: right;
  margin-bottom: 32px;
}

.page-title {
  font-family: 'Tajawal', sans-serif;
  font-size: 28px;
  font-weight: 800;
  color: var(--text);
  margin: 0 0 8px 0;
}

.page-subtitle {
  font-family: 'Tajawal', sans-serif;
  font-size: 16px;
  font-weight: 400;
  color: var(--text);
  opacity: 0.6;
  margin: 0;
}

/* ============================================
   CONTACT INFO CARDS SECTION
   ============================================ */

.contact-info-section {
  margin-bottom: 32px;
}

.contact-info-row {
  display: flex;
  flex-direction: row-reverse; /* RTL: Email on right, Address on left */
  justify-content: flex-start;
  align-items: stretch; /* Equal heights */
  gap: 24px;
  flex-wrap: wrap;
}

.contact-info-card {
  flex: 1;
  min-width: 200px;
  max-width: 280px;
  background: var(--white);
  border-radius: 24px;
  padding: 32px 24px;
  box-shadow: 0 16px 40px rgba(108, 15, 15, 0.08);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Icon Container */
.contact-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--brand); /* #6C0F0F */
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: var(--white);
}

.contact-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--white);
}

/* Email icon */
.email-icon {
  background: var(--brand);
}

/* WhatsApp icon should be green */
.whatsapp-icon {
  background: #25D366;
}

.whatsapp-icon svg {
  fill: var(--white);
  stroke: none;
}

/* Location icon */
.location-icon {
  background: var(--brand);
}

/* Card Content */
.contact-label {
  font-family: 'Tajawal', sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  opacity: 0.6;
  margin: 0 0 8px 0;
}

.contact-value {
  font-family: 'Tajawal', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--brand);
  text-decoration: none;
  margin: 0 0 8px 0;
  word-break: break-word;
  display: block;
}

a.contact-value:hover {
  text-decoration: underline;
}

p.contact-value {
  color: var(--brand);
}

.contact-note {
  font-family: 'Tajawal', sans-serif;
  font-size: 13px;
  font-weight: 400;
  color: var(--text);
  opacity: 0.5;
  margin: 0;
}

/* ============================================
   CONTACT FORM CARD SECTION
   ============================================ */

.contact-form-section {
  width: 100%;
}

.contact-form-card {
  background: var(--white);
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 16px 40px rgba(108, 15, 15, 0.08);
}

.form-title {
  font-family: 'Tajawal', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 8px 0;
  text-align: right;
}

.form-subtitle {
  font-family: 'Tajawal', sans-serif;
  font-size: 15px;
  font-weight: 400;
  color: var(--text);
  opacity: 0.6;
  margin: 0 0 32px 0;
  text-align: right;
}

/* Form Layout */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.form-row {
  width: 100%;
}

.form-row.two-columns {
  display: flex;
  flex-direction: row-reverse; /* RTL */
  gap: 24px;
}

.form-row.two-columns .form-group {
  flex: 1;
}

/* Form Inputs - Contact page specific overrides */
.contact-form .form-input,
.contact-form .form-select,
.contact-form .form-textarea {
  width: 100%;
  background: var(--input-fill); /* #F7F2EF */
  border: 1px solid var(--border); /* rgba(0,0,0,0.08) */
  border-radius: 14px;
  padding: 16px 20px;
  font-family: 'Tajawal', sans-serif;
  font-size: 15px;
  color: var(--text);
  text-align: right;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form .form-input:focus,
.contact-form .form-select:focus,
.contact-form .form-textarea:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(108, 15, 15, 0.16);
}

/* Email input should be LTR */
.contact-form .form-input[type="email"],
.contact-form .form-input[dir="ltr"] {
  text-align: left;
  direction: ltr;
}

/* Select Dropdown */
.contact-form .form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23231F20' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left 16px center; /* RTL: arrow on left */
  padding-left: 40px;
  cursor: pointer;
}

/* Textarea */
.contact-form .form-textarea {
  resize: vertical;
  min-height: 120px;
}

.contact-form .form-textarea::placeholder {
  color: var(--text);
  opacity: 0.4;
}

/* Submit Button */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: var(--brand); /* #6C0F0F */
  color: var(--white);
  border: none;
  border-radius: 14px;
  padding: 16px 32px;
  font-family: 'Tajawal', sans-serif;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(108, 15, 15, 0.25);
  transition: background 0.2s ease, transform 0.1s ease;
}

.btn-primary:hover {
  background: var(--brand-hover); /* #4D0A0A */
}

.btn-primary:active {
  background: var(--brand-pressed); /* #3D0808 */
  transform: scale(0.98);
}

.btn-full-width {
  width: 100%;
}

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

/* ============================================
   CONTACT PAGE RESPONSIVE STYLES
   ============================================ */

/* Tablet */
@media (max-width: 1024px) {
  .contact-info-row {
    justify-content: center;
  }

  .contact-info-card {
    max-width: none;
    flex: 1 1 calc(33.333% - 16px);
  }
}

/* Mobile */
@media (max-width: 768px) {
  .contact-info-row {
    flex-direction: column;
    align-items: stretch;
  }

  .contact-info-card {
    max-width: none;
    width: 100%;
  }

  .form-row.two-columns {
    flex-direction: column;
  }

  .contact-form-card {
    padding: 24px;
  }

  .page-title {
    font-size: 24px;
  }
}

/* ========================================
 * 7. LEGAL PAGES
 * Privacy, Terms, Returns
 * ======================================== */

.legal-content {
  padding: var(--space-xl);
}

.legal-content h2 {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content h3 {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.legal-content p {
  font-size: var(--text-base);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-md);
}

.legal-content ul,
.legal-content ol {
  margin-bottom: var(--space-md);
  padding-inline-start: var(--space-lg);
}

.legal-content li {
  font-size: var(--text-base);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-sm);
}

.legal-content ul li {
  list-style-type: disc;
}

.legal-content ol li {
  list-style-type: decimal;
}

.legal-last-updated {
  font-size: var(--text-sm);
  color: var(--text-muted);
  padding: var(--space-md);
  background-color: var(--input-fill);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-xl);
}

/* ========================================
 * 8. PAYMENT PAGES
 * ======================================== */

/* Payment method selection */
.payment-methods {
  display: grid;
  gap: var(--space-md);
}

.payment-method {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-lg);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.payment-method:hover {
  border-color: var(--brand-light);
}

.payment-method.selected {
  border-color: var(--brand);
  background-color: var(--brand-lighter);
}

.payment-method input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.payment-method-icon {
  width: 48px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.payment-method-icon img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.payment-method-info {
  flex: 1;
}

.payment-method-name {
  font-size: var(--text-base);
  font-weight: var(--font-medium);
  color: var(--text);
}

.payment-method-description {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.payment-method-check {
  width: 24px;
  height: 24px;
  border: 2px solid var(--border);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.payment-method.selected .payment-method-check {
  background-color: var(--brand);
  border-color: var(--brand);
}

.payment-method.selected .payment-method-check::after {
  content: '';
  width: 8px;
  height: 8px;
  background-color: var(--white);
  border-radius: var(--radius-full);
}

/* TAP card element container */
.tap-card-container {
  padding: var(--space-lg);
  background-color: var(--input-fill);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  margin-top: var(--space-lg);
}

/* Order summary */
.order-summary {
  padding: var(--space-lg);
  background-color: var(--input-fill);
  border-radius: var(--radius-lg);
  margin-top: var(--space-lg);
}

.order-summary-title {
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--border);
}

.order-summary-row {
  display: flex;
  justify-content: space-between;
  padding: var(--space-sm) 0;
  font-size: var(--text-sm);
}

.order-summary-label {
  color: var(--text-light);
}

.order-summary-value {
  font-weight: var(--font-medium);
  color: var(--text);
}

.order-summary-total {
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border);
  font-size: var(--text-base);
}

.order-summary-total .order-summary-label {
  font-weight: var(--font-bold);
  color: var(--text);
}

.order-summary-total .order-summary-value {
  font-size: var(--text-lg);
  font-weight: var(--font-extrabold);
  color: var(--brand);
}

/* Secure payment notice */
.secure-notice {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.secure-notice svg {
  width: 16px;
  height: 16px;
  color: var(--success);
}

/* ========================================
 * 9. ENHANCED ACCOUNT PAGES
 * ======================================== */

/* Address card enhanced */
.address-card {
  flex-direction: column;
}

.address-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--space-md);
}

.address-label {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.address-card.address-default {
  border-color: var(--brand);
  background-color: var(--brand-lighter);
}

.address-details {
  margin-bottom: var(--space-md);
}

.address-line {
  font-size: var(--text-sm);
  color: var(--text-light);
  margin-bottom: var(--space-xs);
}

.address-notes {
  font-size: var(--text-sm);
  color: var(--text-muted);
  font-style: italic;
  margin-top: var(--space-sm);
}

.address-card-footer {
  padding-top: var(--space-md);
  border-top: 1px solid var(--border);
}

/* Subscription card enhanced */
.current-subscription-card {
  padding: var(--space-xl);
}

.subscription-details-grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

@media (min-width: 768px) {
  .subscription-details-grid {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }
}

.subscription-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.subscription-plan-name {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  color: var(--text);
}

.subscription-meta {
  display: grid;
  gap: var(--space-sm);
}

.subscription-meta-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: var(--text-sm);
}

.meta-label {
  color: var(--text-muted);
  min-width: 100px;
}

.meta-value {
  color: var(--text);
  font-weight: var(--font-medium);
}

.subscription-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

/* Toggle switch */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 48px;
  height: 26px;
}

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

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: var(--border);
  border-radius: var(--radius-full);
  transition: var(--transition-fast);
}

.toggle-slider::before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  right: 3px;
  bottom: 3px;
  background-color: var(--white);
  border-radius: var(--radius-full);
  transition: var(--transition-fast);
}

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

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

/* Pricing grid */
.pricing-grid {
  display: grid;
  gap: var(--space-lg);
}

@media (min-width: 768px) {
  .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .pricing-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Account plans grid sits inside a sidebar layout, so it has far less width
   than the full viewport. Size columns by the REAL container width (auto-fit)
   instead of forcing 4 by viewport — prevents cramped, per-word-wrapping cards.
   ID specificity wins over the .pricing-grid breakpoint rules above.
   min(260px,100%) avoids overflow on narrow screens. */
#plans-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr));
}

.pricing-card.current-plan {
  opacity: 0.8;
}

.pricing-card-savings {
  position: absolute;
  top: var(--space-md);
  left: var(--space-md);
  padding: var(--space-xs) var(--space-sm);
  background-color: var(--success-bg);
  color: var(--success);
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  border-radius: var(--radius-full);
}

/* Data table */
.table-responsive {
  overflow-x: auto;
}

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

.data-table th,
.data-table td {
  padding: var(--space-md);
  text-align: start;
  border-bottom: 1px solid var(--border);
}

.data-table th {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-muted);
  background-color: var(--input-fill);
}

.data-table td {
  font-size: var(--text-sm);
  color: var(--text);
}

/* ========================================
 * 10. CONTACT PAGE ENHANCED
 * NOTE: Main contact page styles moved to Section 6
 * This section kept for backward compatibility
 * ======================================== */

/* Legacy classes - deprecated, use Section 6 styles */
.contact-info-grid {
  display: none; /* Deprecated - use .contact-info-row instead */
}

.contact-form-title,
.contact-form-description {
  /* Deprecated - use .form-title and .form-subtitle instead */
  display: none;
}

/* FAQ quick links */
.faq-quick-card {
  padding: var(--space-lg);
  margin-top: var(--space-xl);
}

.faq-quick-title {
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-md);
}

.faq-quick-links {
  display: grid;
  gap: var(--space-xs);
}

.faq-quick-link {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md);
  background-color: var(--input-fill);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--text);
  font-size: var(--text-sm);
  transition: all var(--transition-fast);
}

.faq-quick-link:hover {
  background-color: var(--brand-light);
  color: var(--brand);
}

/* ========================================
 * 11. LEGAL PAGES ENHANCED
 * ======================================== */

/* Table of contents */
.legal-toc {
  padding: var(--space-lg);
}

.legal-toc-title {
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-md);
}

.legal-toc-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.legal-toc-nav a {
  padding: var(--space-xs) var(--space-md);
  background-color: var(--input-fill);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  color: var(--text-light);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.legal-toc-nav a:hover {
  background-color: var(--brand-light);
  color: var(--brand);
}

.legal-section {
  scroll-margin-top: var(--space-xl);
}

.legal-last-updated {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.legal-contact-info {
  padding: var(--space-lg);
  background-color: var(--input-fill);
  border-radius: var(--radius-lg);
  margin-top: var(--space-md);
}

.legal-contact-info p {
  margin-bottom: var(--space-sm);
}

.legal-contact-info p:last-child {
  margin-bottom: 0;
}

/* Legal table */
.legal-table-wrapper {
  overflow-x: auto;
  margin: var(--space-md) 0;
}

.legal-table {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.legal-table th,
.legal-table td {
  padding: var(--space-md);
  text-align: start;
  border-bottom: 1px solid var(--border);
}

.legal-table th {
  background-color: var(--input-fill);
  font-weight: var(--font-medium);
  color: var(--text-muted);
}

.legal-table tr:last-child td {
  border-bottom: none;
}

/* ========================================
 * 12. RETURNS PAGE SPECIFIC
 * ======================================== */

.returns-summary {
  padding: var(--space-lg);
  background-color: var(--brand-lighter);
  border: 1px solid var(--brand-light);
}

.returns-summary-title {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  color: var(--brand);
  margin-bottom: var(--space-lg);
}

.returns-summary-grid {
  display: grid;
  gap: var(--space-md);
}

@media (min-width: 768px) {
  .returns-summary-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.returns-summary-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
}

.returns-summary-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.returns-summary-icon.success {
  background-color: var(--success-bg);
  color: var(--success);
}

.returns-summary-icon.warning {
  background-color: var(--warning-bg);
  color: var(--warning);
}

.returns-summary-icon.error {
  background-color: var(--error-bg);
  color: var(--error);
}

.returns-summary-item strong {
  display: block;
  font-size: var(--text-sm);
  color: var(--text);
  margin-bottom: var(--space-xs);
}

.returns-summary-item p {
  font-size: var(--text-xs);
  color: var(--text-light);
  margin: 0;
}

/* Returns steps */
.returns-steps {
  display: grid;
  gap: var(--space-md);
  margin: var(--space-lg) 0;
}

.returns-step {
  display: flex;
  gap: var(--space-md);
}

.returns-step-number {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand);
  color: var(--white);
  font-weight: var(--font-bold);
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.returns-step-content strong {
  display: block;
  font-size: var(--text-sm);
  color: var(--text);
  margin-bottom: var(--space-xs);
}

.returns-step-content p {
  font-size: var(--text-sm);
  color: var(--text-light);
  margin: 0;
}

/* Returns contact options */
.returns-contact-options {
  display: grid;
  gap: var(--space-md);
  margin: var(--space-lg) 0;
}

@media (min-width: 768px) {
  .returns-contact-options {
    grid-template-columns: repeat(2, 1fr);
  }
}

.returns-contact-option {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-lg);
  background-color: var(--input-fill);
  border-radius: var(--radius-lg);
  text-decoration: none;
  transition: all var(--transition-fast);
}

.returns-contact-option:hover {
  background-color: var(--brand-light);
}

.returns-contact-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--white);
  border-radius: var(--radius-md);
  color: var(--brand);
  flex-shrink: 0;
}

.returns-contact-option strong {
  display: block;
  font-size: var(--text-sm);
  color: var(--text);
  margin-bottom: var(--space-xs);
}

.returns-contact-option p {
  font-size: var(--text-sm);
  color: var(--text-light);
  margin: 0;
}

/* Cancel subscription modal */
.cancel-info-list {
  padding-inline-start: var(--space-lg);
}

.cancel-info-list li {
  font-size: var(--text-sm);
  color: var(--text-light);
  margin-bottom: var(--space-sm);
  list-style-type: disc;
}

/* ========================================
 * 13. FEATURE GRID (BENEFITS SECTION)
 * ======================================== */

.feature-grid {
  display: grid;
  gap: var(--space-lg);
}

@media (min-width: 768px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature-card {
  padding: var(--space-xl);
  text-align: center;
}

.feature-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand-light);
  border-radius: var(--radius-lg);
  color: var(--brand);
  margin: 0 auto var(--space-lg);
}

.feature-title {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-sm);
}

.feature-description {
  font-size: var(--text-sm);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
}

/* ========================================
 * 14. EMPTY STATES
 * ======================================== */

.empty-state {
  text-align: center;
  padding: var(--space-2xl) var(--space-xl);
}

.empty-state-icon {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--input-fill);
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-lg);
  color: var(--text-muted);
}

.empty-state-title {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-sm);
}

.empty-state-description {
  font-size: var(--text-sm);
  color: var(--text-light);
  margin-bottom: var(--space-lg);
}

/* ========================================
 * 15. FORM ROW LAYOUT
 * ======================================== */

.form-row {
  display: grid;
  gap: var(--space-md);
}

@media (min-width: 768px) {
  .form-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ========================================
 * 16. CONTACT INFO TITLE
 * NOTE: Deprecated - use .contact-label from Section 6
 * ======================================== */

.contact-info-title {
  /* Deprecated - kept for backward compatibility only */
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-muted);
  margin-bottom: var(--space-xs);
}

/* ========================================
 * 17. COMMUNITY PAGE (WD-052)
 * ======================================== */

/* Coming Soon Banner */
.coming-soon-banner {
  padding: var(--space-2xl);
  text-align: center;
  background: linear-gradient(135deg, var(--brand-light) 0%, var(--white) 100%);
}

.coming-soon-content {
  max-width: 400px;
  margin: 0 auto;
}

.coming-soon-icon {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand);
  color: var(--white);
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-lg);
}

.coming-soon-title {
  font-size: var(--text-2xl);
  font-weight: var(--font-bold);
  color: var(--brand);
  margin-bottom: var(--space-sm);
}

.coming-soon-description {
  font-size: var(--text-sm);
  color: var(--text-light);
  line-height: var(--leading-relaxed);
}

/* Create Post Card */
.create-post-card {
  padding: var(--space-lg);
}

.create-post-header {
  display: flex;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
}

.create-post-input {
  flex: 1;
}

.create-post-input .form-input {
  background-color: var(--input-fill);
  border: none;
}

.create-post-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-md);
  border-top: 1px solid var(--border);
}

/* Post Card */
.post-card {
  padding: var(--space-lg);
}

.post-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--space-md);
}

.post-author {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.post-author-info {
  display: flex;
  flex-direction: column;
}

.post-author-name {
  font-size: var(--text-sm);
  font-weight: var(--font-bold);
  color: var(--text);
}

.post-date {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.post-content {
  margin-bottom: var(--space-md);
}

.post-content p {
  font-size: var(--text-sm);
  color: var(--text);
  line-height: var(--leading-relaxed);
  margin-bottom: var(--space-md);
}

.post-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/9;
  background-color: var(--input-fill);
}

.post-image.placeholder-image {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  color: var(--text-muted);
}

.post-image.placeholder-image span {
  font-size: var(--text-xs);
}

.post-stats {
  display: flex;
  gap: var(--space-lg);
  margin-bottom: var(--space-md);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--border);
}

.post-stat {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.post-actions {
  display: flex;
  gap: var(--space-xs);
}

.post-action {
  flex: 1;
  justify-content: center;
}

/* ========================================
 * 18. MY BOX PAGE (WD-053)
 * ======================================== */

/* Current Box Card */
.current-box-card {
  padding: var(--space-xl);
}

.box-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--space-xl);
}

.box-title {
  font-size: var(--text-xl);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-sm);
}

.box-illustration {
  color: var(--brand);
  opacity: 0.5;
}

/* Delivery Progress Stepper */
.delivery-progress {
  margin-bottom: var(--space-xl);
}

.delivery-progress-title {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-muted);
  margin-bottom: var(--space-lg);
}

.delivery-stepper {
  display: flex;
  justify-content: space-between;
  position: relative;
}

.delivery-stepper::before {
  content: '';
  position: absolute;
  top: 16px;
  left: 0;
  right: 0;
  height: 2px;
  background-color: var(--border);
  z-index: 0;
}

.delivery-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xs);
  position: relative;
  z-index: 1;
  flex: 1;
  text-align: center;
}

.delivery-step-indicator {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--white);
  border: 2px solid var(--border);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--font-bold);
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.delivery-step.completed .delivery-step-indicator {
  background-color: var(--success);
  border-color: var(--success);
  color: var(--white);
}

.delivery-step.active .delivery-step-indicator {
  background-color: var(--brand);
  border-color: var(--brand);
  color: var(--white);
}

.delivery-step-label {
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
  color: var(--text-light);
}

.delivery-step.active .delivery-step-label {
  color: var(--brand);
  font-weight: var(--font-bold);
}

.delivery-step.completed .delivery-step-label {
  color: var(--success);
}

.delivery-step-date {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

/* Tracking Info */
.tracking-info {
  padding: var(--space-lg);
  background-color: var(--input-fill);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-lg);
}

.tracking-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-sm) 0;
}

.tracking-row:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.tracking-label {
  font-size: var(--text-sm);
  color: var(--text-muted);
}

.tracking-value {
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text);
  display: flex;
  align-items: center;
  gap: var(--space-xs);
}

.tracking-value code {
  background-color: var(--white);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  font-family: monospace;
  font-size: var(--text-xs);
}

.box-actions {
  text-align: center;
}

/* Awaiting Box State */
.awaiting-box-state {
  padding: var(--space-2xl);
  text-align: center;
}

.awaiting-box-content {
  max-width: 300px;
  margin: 0 auto;
}

.awaiting-box-icon {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand-light);
  color: var(--brand);
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-lg);
}

.awaiting-box-title {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-sm);
}

.awaiting-box-description {
  font-size: var(--text-sm);
  color: var(--text-light);
}

/* Box Contents */
.box-contents-card {
  padding: var(--space-xl);
}

.box-contents-mystery {
  text-align: center;
}

.mystery-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--input-fill);
  color: var(--text-muted);
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-lg);
}

.mystery-title {
  font-size: var(--text-base);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-sm);
}

.mystery-description {
  font-size: var(--text-sm);
  color: var(--text-light);
}

/* Past Boxes Grid */
.past-boxes-grid {
  display: grid;
  gap: var(--space-md);
}

@media (min-width: 768px) {
  .past-boxes-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .past-boxes-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.past-box-card {
  padding: var(--space-lg);
}

.past-box-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-md);
}

.past-box-month {
  font-size: var(--text-sm);
  font-weight: var(--font-bold);
  color: var(--text);
}

.past-box-content {
  margin-bottom: var(--space-md);
}

.past-box-book {
  display: flex;
  gap: var(--space-md);
  align-items: center;
}

.book-cover-placeholder {
  width: 60px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--input-fill);
  border-radius: var(--radius-md);
  color: var(--text-muted);
  flex-shrink: 0;
}

.book-info {
  min-width: 0;
}

.book-title {
  font-size: var(--text-sm);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-xs);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.book-author {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.past-box-action {
  width: 100%;
}

/* ========================================
 * 19. NOTIFICATIONS PAGE (WD-054)
 * ======================================== */

.notifications-page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
  gap: var(--space-md);
}

.notifications-header-content {
  flex: 1;
  min-width: 200px;
}

/* Notification Filters */
.notification-filters {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.filter-tab {
  padding: var(--space-sm) var(--space-md);
  background-color: var(--input-fill);
  border: none;
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--font-medium);
  color: var(--text-light);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-tab:hover {
  background-color: var(--border);
}

.filter-tab.active {
  background-color: var(--brand);
  color: var(--white);
}

/* Notifications Card */
.notifications-card {
  padding: 0;
}

/* Notification Group */
.notification-group {
  border-bottom: 1px solid var(--border);
}

.notification-group:last-child {
  border-bottom: none;
}

.notification-group-title {
  font-size: var(--text-xs);
  font-weight: var(--font-bold);
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
  padding: var(--space-md) var(--space-lg);
  background-color: var(--input-fill);
}

/* Notification Item */
.notification-item {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  padding: var(--space-lg);
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background-color var(--transition-fast);
}

.notification-item:last-child {
  border-bottom: none;
}

.notification-item:hover {
  background-color: var(--input-fill);
}

.notification-item.unread {
  background-color: var(--brand-lighter);
}

.notification-indicator {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
  margin-top: 6px;
}

.notification-item.unread .notification-indicator {
  background-color: var(--brand);
}

.notification-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.notification-icon.delivery {
  background-color: var(--brand-light);
  color: var(--brand);
}

.notification-icon.subscription {
  background-color: var(--success-bg);
  color: var(--success);
}

.notification-icon.community {
  background-color: #FCE7F3;
  color: #EC4899;
}

.notification-icon.warning {
  background-color: var(--warning-bg);
  color: var(--warning);
}

.notification-icon.system {
  background-color: var(--input-fill);
  color: var(--text-muted);
}

.notification-content {
  flex: 1;
  min-width: 0;
}

.notification-text {
  font-size: var(--text-sm);
  color: var(--text);
  line-height: var(--leading-relaxed);
  margin: 0 0 var(--space-xs);
}

.notification-text strong {
  font-weight: var(--font-bold);
}

.notification-time {
  font-size: var(--text-xs);
  color: var(--text-muted);
}

.notification-action {
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.notification-item:hover .notification-action {
  opacity: 1;
}

/* ========================================
 * 20. MOBILE BOTTOM NAVIGATION (WD-055, WD-061)
 * ======================================== */

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-around;
  background-color: var(--white);
  border-top: 1px solid var(--border);
  padding: var(--space-sm) 0;
  padding-bottom: calc(var(--space-sm) + env(safe-area-inset-bottom));
  z-index: var(--z-fixed);
}

.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-md);
  color: var(--text-muted);
  text-decoration: none;
  font-size: var(--text-xs);
  transition: color var(--transition-fast);
  min-width: 64px;
  min-height: 44px;
}

.bottom-nav-item.active {
  color: var(--brand);
}

.bottom-nav-item:active {
  transform: scale(0.95);
}

/* FAB (Floating Action Button) */
.fab {
  position: fixed;
  bottom: calc(80px + env(safe-area-inset-bottom));
  left: var(--space-lg);
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--brand);
  color: var(--white);
  border: none;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  z-index: var(--z-fixed);
  transition: all var(--transition-fast);
}

.fab:hover {
  background-color: var(--brand-hover);
  transform: scale(1.05);
}

.fab:active {
  transform: scale(0.95);
}

.fab:disabled {
  background-color: var(--border);
  cursor: not-allowed;
}

/* ========================================
 * 21. RESPONSIVE VISIBILITY (WD-055)
 * ======================================== */

.show-mobile-only {
  display: flex;
}

.hide-mobile {
  display: none;
}

@media (min-width: 768px) {
  .show-mobile-only {
    display: none !important;
  }

  .hide-mobile {
    display: block;
  }
}

/* ========================================
 * 22. MOBILE SIDEBAR (WD-055, WD-058)
 * ======================================== */

@media (max-width: 1023px) {
  .sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background-color: var(--white);
    z-index: var(--z-modal);
    transition: right var(--transition-base);
    padding: var(--space-xl);
    overflow-y: auto;
  }

  .sidebar.open {
    right: 0;
  }

  .sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: calc(var(--z-modal) - 1);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-fast);
  }

  .sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
  }

  /* Add padding for bottom nav */
  .account-content {
    padding-bottom: calc(80px + env(safe-area-inset-bottom));
  }
}

/* ========================================
 * 23. TOUCH INTERACTIONS (WD-060)
 * ======================================== */

/* Touch-friendly button sizing */
.btn,
.nav-item,
a {
  min-height: 44px;
}

.btn-sm {
  min-height: 36px;
}

.btn-icon {
  min-width: 44px;
  min-height: 44px;
}

.btn-icon.btn-sm {
  min-width: 36px;
  min-height: 36px;
}

/* Touch feedback */
@media (hover: none) {
  .btn:active,
  .card:active,
  .nav-item:active {
    transform: scale(0.98);
  }

  /* Disable hover effects on touch devices */
  .btn:hover,
  .card:hover {
    transform: none;
  }
}

/* Pull to refresh placeholder */
.pull-to-refresh {
  display: none;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
  color: var(--text-muted);
}

.pull-to-refresh.active {
  display: flex;
}

/* ========================================
 * 24. LOADING STATES (WD-068)
 * ======================================== */

/* Skeleton Loader */
.skeleton {
  background: linear-gradient(90deg, var(--input-fill) 25%, var(--border) 50%, var(--input-fill) 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: var(--radius-md);
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

.skeleton-text {
  height: 1em;
  margin-bottom: var(--space-sm);
}

.skeleton-text:last-child {
  width: 70%;
  margin-bottom: 0;
}

.skeleton-avatar {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
}

.skeleton-card {
  height: 200px;
}

.skeleton-button {
  height: 44px;
  width: 120px;
}

/* Page Loading Indicator */
.page-loading {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background-color: var(--brand);
  z-index: var(--z-tooltip);
  animation: page-loading 2s ease-in-out infinite;
}

@keyframes page-loading {
  0% {
    width: 0;
    left: 0;
  }
  50% {
    width: 100%;
    left: 0;
  }
  100% {
    width: 0;
    left: 100%;
  }
}

/* Loading Overlay */
.loading-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(255, 255, 255, 0.8);
  z-index: 10;
}

/* ========================================
 * 25. ERROR STATES (WD-069)
 * ======================================== */

.error-state {
  text-align: center;
  padding: var(--space-2xl);
}

.error-state-icon {
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--error-bg);
  color: var(--error);
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-lg);
}

.error-state-title {
  font-size: var(--text-lg);
  font-weight: var(--font-bold);
  color: var(--text);
  margin-bottom: var(--space-sm);
}

.error-state-message {
  font-size: var(--text-sm);
  color: var(--text-light);
  margin-bottom: var(--space-lg);
}

/* Network Error Banner */
.network-error-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: var(--space-md) var(--space-lg);
  background-color: var(--error);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-md);
  z-index: var(--z-tooltip);
  transform: translateY(100%);
  transition: transform var(--transition-base);
}

.network-error-banner.active {
  transform: translateY(0);
}

.network-error-banner button {
  background-color: var(--white);
  color: var(--error);
  border: none;
  padding: var(--space-xs) var(--space-md);
  border-radius: var(--radius-md);
  font-weight: var(--font-bold);
  cursor: pointer;
}

/* ========================================
 * 26. TRANSITIONS & ANIMATIONS (WD-072)
 * ======================================== */

/* Page transition */
.page-enter {
  opacity: 0;
  transform: translateY(10px);
}

.page-enter-active {
  opacity: 1;
  transform: translateY(0);
  transition: all var(--transition-base);
}

/* Fade in animation */
.fade-in {
  animation: fadeIn var(--transition-base) ease-out;
}

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

/* Slide up animation */
.slide-up {
  animation: slideUp var(--transition-base) ease-out;
}

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

/* Scale in animation */
.scale-in {
  animation: scaleIn var(--transition-fast) ease-out;
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Hover effects */
.hover-lift {
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.hover-lift:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card-hover);
}

/* Focus states */
.btn:focus-visible,
.form-input:focus-visible,
.nav-item:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* ========================================
 * 27. ACCESSIBILITY (WD-072)
 * ======================================== */

/* Screen reader only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--brand);
  color: var(--white);
  padding: var(--space-sm) var(--space-md);
  z-index: var(--z-tooltip);
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* High contrast mode */
@media (prefers-contrast: high) {
  :root {
    --border: #000;
    --text-muted: #333;
  }

  .btn {
    border: 2px solid currentColor;
  }

  .card {
    border: 2px solid var(--border);
  }
}

/* ========================================
 * 28. NOTIFICATION DOT
 * ======================================== */

.notification-dot {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  background-color: var(--error);
  border-radius: var(--radius-full);
  border: 2px solid var(--white);
}

.relative {
  position: relative;
}
