/* ============================================
   GEORGIANA COWLEY NUTRITION — Design Tokens
   Aesthetic: Jo Malone × Barbara Sturm × Cowshed
   ============================================ */

:root {
  /* Type Scale */
  --text-xs:   clamp(0.75rem,  0.7rem  + 0.25vw, 0.875rem);
  --text-sm:   clamp(0.875rem, 0.8rem  + 0.35vw, 1rem);
  --text-base: clamp(1rem,     0.95rem + 0.25vw, 1.125rem);
  --text-lg:   clamp(1.125rem, 1rem    + 0.75vw, 1.5rem);
  --text-xl:   clamp(1.5rem,   1.2rem  + 1.25vw, 2.25rem);
  --text-2xl:  clamp(2rem,     1.2rem  + 2.5vw,  3.5rem);
  --text-3xl:  clamp(2.5rem,   1rem    + 4vw,    5rem);
  --text-hero: clamp(3rem,     0.5rem  + 7vw,    8rem);

  /* Spacing */
  --space-1:  0.25rem;
  --space-2:  0.5rem;
  --space-3:  0.75rem;
  --space-4:  1rem;
  --space-5:  1.25rem;
  --space-6:  1.5rem;
  --space-8:  2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* Fonts */
  --font-display: 'Cormorant Garamond', 'Georgia', serif;
  --font-body: 'Switzer', 'Helvetica Neue', sans-serif;

  /* Radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.375rem;
  --radius-lg: 0.5rem;
  --radius-xl: 0.75rem;
  --radius-full: 9999px;

  /* Transitions */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* Content widths */
  --content-narrow: 640px;
  --content-default: 960px;
  --content-wide: 1200px;
  --content-full: 100%;
}

/* ============================================
   Color Palette — Warm Cream + Sage + Stone
   ============================================ */

:root, [data-theme="light"] {
  --color-bg:           #FAF8F5;
  --color-surface:      #F5F1EC;
  --color-surface-2:    #EDE8E1;
  --color-border:       #D5CFC7;
  --color-text:         #2C2A25;
  --color-text-muted:   #7A756C;
  --color-text-faint:   #B5B0A8;
  --color-primary:      #6B7C5E;
  --color-primary-hover:#546347;
  --color-accent:       #A68B6B;
  --color-accent-hover: #8D7459;

  --shadow-sm: 0 1px 2px oklch(0.2 0.01 60 / 0.06);
  --shadow-md: 0 4px 12px oklch(0.2 0.01 60 / 0.08);
  --shadow-lg: 0 12px 32px oklch(0.2 0.01 60 / 0.12);
}

[data-theme="dark"] {
  --color-bg:           #1A1917;
  --color-surface:      #222120;
  --color-surface-2:    #2A2928;
  --color-border:       #3D3C39;
  --color-text:         #E0DDD8;
  --color-text-muted:   #8E8A83;
  --color-text-faint:   #5E5B56;
  --color-primary:      #8FA87D;
  --color-primary-hover:#A5BD95;
  --color-accent:       #C4A888;
  --color-accent-hover: #D4BC9E;

  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.2);
  --shadow-md: 0 4px 12px oklch(0 0 0 / 0.3);
  --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.4);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg:           #1A1917;
    --color-surface:      #222120;
    --color-surface-2:    #2A2928;
    --color-border:       #3D3C39;
    --color-text:         #E0DDD8;
    --color-text-muted:   #8E8A83;
    --color-text-faint:   #5E5B56;
    --color-primary:      #8FA87D;
    --color-primary-hover:#A5BD95;
    --color-accent:       #C4A888;
    --color-accent-hover: #D4BC9E;
    --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.2);
    --shadow-md: 0 4px 12px oklch(0 0 0 / 0.3);
    --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.4);
  }
}

/* ============================================
   Global Styles
   ============================================ */

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-interactive);
}
a:hover { color: var(--color-primary-hover); }

/* ============================================
   Navigation
   ============================================ */

.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: oklch(from var(--color-bg) l c h / 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid oklch(from var(--color-text) l c h / 0.06);
  transition: box-shadow 0.3s var(--ease-out);
}

.header--scrolled {
  box-shadow: var(--shadow-sm);
}

.header-inner {
  max-width: var(--content-wide);
  margin: 0 auto;
  padding: var(--space-4) var(--space-6);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  color: var(--color-text);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  line-height: 1.2;
}
.logo span {
  display: block;
  font-size: var(--text-xs);
  letter-spacing: 0.25em;
  color: var(--color-text-muted);
  font-family: var(--font-body);
  font-weight: 400;
  text-transform: uppercase;
}

.nav { display: flex; align-items: center; gap: var(--space-8); }

.nav-links {
  display: flex;
  gap: var(--space-6);
  list-style: none;
}
.nav-links a {
  font-family: var(--font-body);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 400;
  transition: color var(--transition-interactive);
}
.nav-links a:hover { color: var(--color-text); }

.theme-toggle {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-muted);
  cursor: pointer;
  border-radius: var(--radius-full);
  transition: color var(--transition-interactive), background var(--transition-interactive);
}
.theme-toggle:hover {
  color: var(--color-text);
  background: var(--color-surface);
}

.mobile-menu-btn {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  color: var(--color-text);
}

.mobile-nav {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100;
  background: var(--color-bg);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-8);
}
.mobile-nav.active { display: flex; }
.mobile-nav a {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: 0.08em;
}
.mobile-nav-close {
  position: absolute;
  top: var(--space-4);
  right: var(--space-4);
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text);
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .theme-toggle-nav { display: none; }
  .mobile-menu-btn { display: flex; }
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
  position: relative;
  min-height: 85vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
}
[data-theme="light"] .hero-overlay,
:root:not([data-theme]) .hero-overlay {
  background: linear-gradient(
    to right,
    oklch(from var(--color-bg) l c h / 0.88) 0%,
    oklch(from var(--color-bg) l c h / 0.6) 40%,
    oklch(from var(--color-bg) l c h / 0.1) 70%,
    transparent 100%
  );
}
[data-theme="dark"] .hero-overlay {
  background: linear-gradient(
    to right,
    oklch(from var(--color-bg) l c h / 0.92) 0%,
    oklch(from var(--color-bg) l c h / 0.7) 40%,
    oklch(from var(--color-bg) l c h / 0.2) 70%,
    transparent 100%
  );
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .hero-overlay {
    background: linear-gradient(
      to right,
      oklch(from var(--color-bg) l c h / 0.92) 0%,
      oklch(from var(--color-bg) l c h / 0.7) 40%,
      oklch(from var(--color-bg) l c h / 0.2) 70%,
      transparent 100%
    );
  }
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--content-wide);
  margin: 0 auto;
  padding: var(--space-16) var(--space-6);
  width: 100%;
}
.hero-text {
  max-width: 580px;
}
.hero h1 {
  font-family: var(--font-display);
  font-size: var(--text-3xl);
  font-weight: 400;
  color: var(--color-text);
  line-height: 1.1;
  margin-bottom: var(--space-6);
  letter-spacing: -0.01em;
}
.hero h1 em {
  font-style: italic;
  color: var(--color-primary);
}
.hero-subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  line-height: 1.7;
  max-width: 460px;
  margin-bottom: var(--space-8);
}
.hero-line {
  width: 48px;
  height: 1px;
  background: var(--color-accent);
  margin-bottom: var(--space-6);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: var(--space-3) var(--space-8);
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-interactive);
}
.btn-primary {
  background: var(--color-text);
  color: var(--color-bg);
  border-color: var(--color-text);
}
.btn-primary:hover {
  background: transparent;
  color: var(--color-text);
}
.btn-outline {
  background: transparent;
  color: var(--color-text);
  border-color: var(--color-border);
}
.btn-outline:hover {
  border-color: var(--color-text);
}

/* ============================================
   Sections
   ============================================ */

.section {
  padding: clamp(var(--space-12), 8vw, var(--space-24)) var(--space-6);
}
.section-inner {
  max-width: var(--content-wide);
  margin: 0 auto;
}

.section-header {
  margin-bottom: clamp(var(--space-8), 4vw, var(--space-16));
}
.section-label {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-3);
}
.section-title {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 400;
  color: var(--color-text);
  line-height: 1.15;
}
.section-subtitle {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  max-width: 540px;
  margin-top: var(--space-4);
  line-height: 1.7;
}

/* Divider */
.divider {
  width: 48px;
  height: 1px;
  background: var(--color-accent);
  margin: var(--space-6) 0;
}

/* ============================================
   About Section (asymmetric two-column)
   ============================================ */

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 5vw, var(--space-16));
  align-items: center;
}
.about-image {
  overflow: hidden;
}
.about-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4/5;
}
.about-text p {
  color: var(--color-text-muted);
  line-height: 1.8;
  margin-bottom: var(--space-4);
}
.about-credentials {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-6);
}
.credential {
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--color-border);
}

@media (max-width: 768px) {
  .about-grid { grid-template-columns: 1fr; }
  .about-image { order: -1; }
  .about-image img { aspect-ratio: 16/9; }
}

/* ============================================
   Services Section
   ============================================ */

.services-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 5vw, var(--space-16));
  align-items: start;
}
.services-image {
  overflow: hidden;
  position: sticky;
  top: calc(var(--space-16) + 60px);
}
.services-image img {
  width: 100%;
  aspect-ratio: 3/4;
  object-fit: cover;
}

.services-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-8);
}
.service-item {
  padding-bottom: var(--space-8);
  border-bottom: 1px solid oklch(from var(--color-text) l c h / 0.08);
}
.service-item:last-child { border-bottom: none; }
.service-number {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  color: var(--color-text-faint);
  font-weight: 300;
  margin-bottom: var(--space-2);
}
.service-name {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: var(--space-3);
}
.service-desc {
  font-size: var(--text-base);
  color: var(--color-text-muted);
  line-height: 1.7;
}
.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-3);
}
.service-tag {
  font-size: var(--text-xs);
  color: var(--color-primary);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.service-tag::before {
  content: '— ';
  color: var(--color-text-faint);
}

@media (max-width: 768px) {
  .services-layout { grid-template-columns: 1fr; }
  .services-image {
    position: static;
    order: -1;
  }
  .services-image img { aspect-ratio: 16/9; }
}

/* ============================================
   Approach (How It Works)
   ============================================ */

.approach-bg {
  background: var(--color-surface);
}
.approach-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-6);
}
.approach-step {
  padding: var(--space-6) var(--space-4);
}
.step-number {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 300;
  color: var(--color-text-faint);
  line-height: 1;
  margin-bottom: var(--space-4);
}
.step-title {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: var(--space-3);
}
.step-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}

@media (max-width: 768px) {
  .approach-steps {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .approach-step {
    padding: var(--space-6) 0;
    border-bottom: 1px solid oklch(from var(--color-text) l c h / 0.06);
  }
  .approach-step:last-child { border-bottom: none; }
}

/* ============================================
   Testimonials
   ============================================ */

.testimonials-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-8);
}
.testimonial {
  padding: var(--space-8);
  background: var(--color-surface);
  border: 1px solid oklch(from var(--color-text) l c h / 0.04);
}
.testimonial-quote {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  font-style: italic;
  color: var(--color-text);
  line-height: 1.6;
  margin-bottom: var(--space-6);
}
.testimonial-author {
  font-size: var(--text-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

@media (max-width: 768px) {
  .testimonials-grid { grid-template-columns: 1fr; }
}

/* ============================================
   Blog Preview
   ============================================ */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-6);
}
.blog-card {
  text-decoration: none;
  color: inherit;
  display: block;
  transition: transform var(--transition-interactive), box-shadow var(--transition-interactive);
}
.blog-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.blog-card-img {
  aspect-ratio: 16/10;
  overflow: hidden;
  background: var(--color-surface);
  margin-bottom: var(--space-4);
}
.blog-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out);
}
.blog-card:hover .blog-card-img img {
  transform: scale(1.03);
}
.blog-card-category {
  font-size: var(--text-xs);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: var(--space-2);
}
.blog-card-title {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  color: var(--color-text);
  line-height: 1.3;
  margin-bottom: var(--space-2);
}
.blog-card-excerpt {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.6;
}

@media (max-width: 768px) {
  .blog-grid { grid-template-columns: 1fr; }
}

/* ============================================
   Contact / CTA Section
   ============================================ */

.cta-section {
  background: var(--color-surface);
  text-align: center;
}
.cta-section .section-title {
  margin: 0 auto var(--space-4);
}
.cta-section .section-subtitle {
  margin: 0 auto var(--space-8);
}
.cta-actions {
  display: flex;
  gap: var(--space-4);
  justify-content: center;
  flex-wrap: wrap;
}

/* Contact form */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--space-8), 5vw, var(--space-16));
  align-items: start;
}
.contact-info h3 {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 400;
  margin-bottom: var(--space-4);
}
.contact-info p {
  color: var(--color-text-muted);
  line-height: 1.8;
  margin-bottom: var(--space-6);
}
.contact-detail {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  margin-bottom: var(--space-6);
}
.contact-detail-item {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}
.contact-detail-item strong {
  display: block;
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text);
  font-weight: 500;
  margin-bottom: var(--space-1);
}

.form { display: flex; flex-direction: column; gap: var(--space-4); }
.form-group { display: flex; flex-direction: column; gap: var(--space-1); }
.form-label {
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-text-muted);
}
.form-input,
.form-textarea {
  padding: var(--space-3) var(--space-4);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  font-size: var(--text-base);
  color: var(--color-text);
  transition: border-color var(--transition-interactive);
}
.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--color-primary);
}
.form-textarea { resize: vertical; min-height: 120px; }

@media (max-width: 768px) {
  .contact-grid { grid-template-columns: 1fr; }
}

/* ============================================
   Footer
   ============================================ */

.footer {
  border-top: 1px solid oklch(from var(--color-text) l c h / 0.06);
  padding: var(--space-12) var(--space-6) var(--space-8);
}
.footer-inner {
  max-width: var(--content-wide);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: var(--space-8);
}
.footer-brand {
  max-width: 320px;
}
.footer-brand .logo {
  margin-bottom: var(--space-4);
}
.footer-brand p {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.7;
}
.footer-links h4 {
  font-family: var(--font-body);
  font-size: var(--text-xs);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--color-text);
  margin-bottom: var(--space-4);
  font-weight: 500;
}
.footer-links ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}
.footer-links a {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  text-decoration: none;
  transition: color var(--transition-interactive);
}
.footer-links a:hover { color: var(--color-text); }

.footer-bottom {
  max-width: var(--content-wide);
  margin: var(--space-8) auto 0;
  padding-top: var(--space-6);
  border-top: 1px solid oklch(from var(--color-text) l c h / 0.06);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-4);
}
.footer-bottom p {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
}
.footer-bottom a {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  text-decoration: none;
}
.footer-bottom a:hover { color: var(--color-text-muted); }

@media (max-width: 768px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: var(--space-8);
  }
}

/* ============================================
   Scroll Reveal Animations
   ============================================ */

.fade-in { opacity: 1; }

@supports (animation-timeline: scroll()) {
  .fade-in {
    opacity: 0;
    animation: reveal-fade linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 80%;
  }
}

@keyframes reveal-fade {
  to { opacity: 1; }
}
