/* Common styles for auxiliary pages (privacy, terms, delivery, refund, etc.) */

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

:root {
  --primary: #6366F1;
  --primary-dark: #4F46E5;
  --primary-light: #818CF8;
  --secondary: #8B5CF6;
  --accent: #EC4899;
  --success: #10B981;
  --text: #0F172A;
  --text-secondary: #64748B;
  --text-light: #94A3B8;
  --border: #E2E8F0;
  --bg: #FFFFFF;
  --bg-light: #F8FAFC;
  --bg-secondary: #FFFFFF;
  --bg-gradient: linear-gradient(135deg, #667EEA 0%, #764BA2 100%);
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --text-2xs: 10px;
  --text-xs: 12px;
  --text-sm: 14px;
  --text-base: 16px;
  --text-md: 18px;
  --text-lg: 20px;
  --text-xl: 24px;
  --text-2xl: 32px;
  --text-3xl: 48px;
  --leading-none: 1;
  --leading-tight: 1.25;
  --leading-snug: 1.4;
  --leading-normal: 1.5;
  --leading-relaxed: 1.6;
}

/* Dark theme */
[data-theme="dark"] {
  --text: #F1F5F9;
  --text-secondary: #94A3B8;
  --text-light: #64748B;
  --border: #334155;
  --bg: #0F172A;
  --bg-light: #1E293B;
  --bg-secondary: #1E293B;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
  --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

/* Auto dark theme based on system preference */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --text: #F1F5F9;
    --text-secondary: #94A3B8;
    --text-light: #64748B;
    --border: #334155;
    --bg: #0F172A;
    --bg-light: #1E293B;
    --bg-secondary: #1E293B;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  }
}

/* Theme transition animation - smooth and elegant */
*,
*::before,
*::after {
  transition: background-color 0.5s cubic-bezier(0.4, 0, 0.2, 1), 
              color 0.5s cubic-bezier(0.4, 0, 0.2, 1), 
              border-color 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              fill 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              stroke 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light fade animation during theme transition */

/* Respect user's motion preferences */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: var(--leading-relaxed);
  font-size: var(--text-base);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.5s cubic-bezier(0.4, 0, 0.2, 1), 
              color 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

html {
  scroll-behavior: smooth;
  transition: background-color 0.5s cubic-bezier(0.4, 0, 0.2, 1), 
              color 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Header */
header {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--border);
  padding: 20px 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 1000;
  transition: all 0.3s ease;
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  will-change: transform;
}

[data-theme="dark"] header {
  background: rgba(15, 23, 42, 0.8);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) header {
    background: rgba(15, 23, 42, 0.8);
  }
}

.logo {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 800;
  font-size: var(--text-xl);
  color: var(--text);
  text-decoration: none;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.logo:hover {
  transform: scale(1.03);
}

.logo-svg {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.logo-text {
  font-size: var(--text-xl);
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  color: #FFFFFF;
  padding: 14px 28px;
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 600;
  font-size: var(--text-sm);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-block;
  box-shadow: var(--shadow);
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

/* Unified Theme Toggle Button Styles */
.theme-toggle {
  background: var(--bg-light);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease, transform 0.2s ease;
  color: var(--text);
  position: relative;
  overflow: hidden;
}

.theme-toggle:hover {
  background: var(--bg);
  border-color: var(--primary);
  transform: scale(1.05);
}

.theme-toggle:active {
  transform: scale(0.95);
}

.theme-toggle svg {
  width: 20px;
  height: 20px;
  transition: opacity 0.4s ease, transform 0.4s ease;
  position: absolute;
}

.theme-toggle .sun-icon,
.theme-toggle .moon-icon {
  animation: themeIconRotate 0.4s ease;
}

@keyframes themeIconRotate {
  from {
    opacity: 0;
    transform: rotate(-180deg) scale(0.8);
  }
  to {
    opacity: 1;
    transform: rotate(0deg) scale(1);
  }
}

.theme-toggle .sun-icon {
  display: block;
}

.theme-toggle .moon-icon {
  display: none;
}

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

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

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .sun-icon {
    display: none;
  }
  :root:not([data-theme="light"]) .theme-toggle .moon-icon {
    display: block;
  }
}

/* Content */
.content-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 80px 5%;
}

.page-title {
  font-size: var(--text-3xl);
  font-weight: 900;
  margin-bottom: 20px;
  color: var(--text);
  letter-spacing: -0.03em;
}

.page-subtitle {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  margin-bottom: 60px;
  line-height: var(--leading-relaxed);
}

.content-section {
  margin-bottom: 48px;
}

.content-section h2 {
  font-size: var(--text-2xl);
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text);
  letter-spacing: -0.02em;
}

.content-section h3 {
  font-size: var(--text-xl);
  font-weight: 600;
  margin-top: 32px;
  margin-bottom: 16px;
  color: var(--text);
}

.content-section p {
  color: var(--text-secondary);
  margin-bottom: 20px;
  line-height: var(--leading-relaxed);
  font-size: var(--text-base);
}

.content-section ul,
.content-section ol {
  margin-left: 24px;
  margin-bottom: 20px;
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
}

.content-section li {
  margin-bottom: 12px;
}

.content-section strong {
  color: var(--text);
  font-weight: 600;
}

.content-section a {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-color: var(--primary);
  text-underline-offset: 3px;
  transition: all 0.2s ease;
  font-weight: 500;
}

.content-section a.btn-primary,
.content-section a.btn-secondary {
  text-decoration: none;
}

.content-section a:hover {
  color: var(--primary-light);
  text-decoration-color: var(--primary-light);
}

[data-theme="dark"] .content-section a {
  color: #60A5FA;
  text-decoration-color: #60A5FA;
}

[data-theme="dark"] .content-section a:hover {
  color: #93C5FD;
  text-decoration-color: #93C5FD;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .content-section a {
    color: #60A5FA;
    text-decoration-color: #60A5FA;
  }
  :root:not([data-theme="light"]) .content-section a:hover {
    color: #93C5FD;
    text-decoration-color: #93C5FD;
  }
}

.last-updated {
  color: var(--text-light);
  font-size: var(--text-sm);
  font-style: italic;
  margin-bottom: 40px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

/* Footer - matches landing page footer style */
footer,
.auxiliary-footer {
  background: linear-gradient(135deg, #0F172A 0%, #1E293B 100%);
  color: #FFFFFF;
  margin-top: 120px;
  padding: 60px 5%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
}

.auxiliary-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: center;
  align-items: center;
  margin-bottom: 0;
}

.auxiliary-footer nav a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: var(--text-sm);
  transition: color 0.2s ease;
}

.auxiliary-footer nav a:hover {
  color: #FFFFFF;
}

.auxiliary-footer .footer-copyright {
  color: rgba(255, 255, 255, 0.7);
  font-size: var(--text-sm);
  margin: 0;
}

/* Responsive */
@media (max-width: 768px) {
  header {
    padding: 16px 5%;
    flex-wrap: wrap;
    gap: 12px;
  }

  .logo {
    font-size: var(--text-xl);
  }

  .logo-svg {
    width: 32px;
    height: 32px;
  }

  .btn-primary {
    padding: 12px 20px;
    font-size: var(--text-sm);
  }

  .content-container {
    padding: 60px 5%;
  }

  .page-title {
    font-size: var(--text-2xl);
    margin-bottom: 16px;
  }

  .page-subtitle {
    font-size: var(--text-md);
    margin-bottom: 40px;
  }

  .content-section h2 {
    font-size: var(--text-xl);
    margin-bottom: 16px;
  }

  .content-section h3 {
    font-size: var(--text-lg);
    margin-top: 24px;
    margin-bottom: 12px;
  }

  .content-section p,
  .content-section li {
    font-size: var(--text-sm);
  }

  .content-section ul,
  .content-section ol {
    margin-left: 20px;
  }
}
