/* Tarita Capetown Photography — demo site
   Type: Besley (headings) + Sora (body) — Google Fonts, free/self-hostable
   Palette: warm paper base + coral-magenta "flash" accent + sunlight yellow
   Signature move: "The Print Fan" — CSS 3D fan-out of stacked print-styled photo cards,
   driven by scroll (animation-timeline: scroll()) with a JS scroll/drag fallback. */

:root {
  --paper:      #FAF6F0;
  --paper-alt:  #F3ECE1;
  --ink:        #241F1A;
  --ink-mid:    #55493D;
  --flash:      #E8437A;
  --flash-deep: #C22C5C;
  --sunlight:   #FFC93C;
  --border:     #E5DACB;
  --whatsapp:   #25D366;
  --whatsapp-ink: #0b2013;
  --white:      #ffffff;
  --radius:     16px;
  --radius-sm:  10px;
  --maxw:       1240px;
  --shadow-card: 0 18px 40px rgba(36,31,26,0.14), 0 2px 8px rgba(36,31,26,0.08);
}

*,*::before,*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Sora', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3, h4 { font-family: 'Besley', Georgia, serif; margin: 0; color: var(--ink); font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0 0 1em; color: var(--ink-mid); }
a { color: inherit; }
img { max-width: 100%; display: block; }
button { font-family: inherit; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; }
@media (max-width: 640px) { .container { padding: 0 20px; } }

.wa-icon { flex-shrink: 0; }

/* ===== HEADER ===== */
header.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250,246,240,0.92);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
header.nav .container {
  padding: 14px 28px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.nav-brand {
  font-family: 'Besley', Georgia, serif; font-weight: 700; font-size: 21px;
  color: var(--ink); text-decoration: none; letter-spacing: -0.01em;
}
.nav-brand span { color: var(--flash); }
.nav-links {
  display: flex; align-items: center; gap: 30px; list-style: none; margin: 0; padding: 0;
}
.nav-links a {
  text-decoration: none; color: var(--ink-mid); font-weight: 500; font-size: 15px;
  transition: color 0.2s ease;
}
.nav-links a:hover { color: var(--flash); }
.nav-right { display: flex; align-items: center; gap: 18px; }
.nav-menu-btn { display: none; }
@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-menu-btn {
    display: flex; align-items: center; justify-content: center;
    background: none; border: none; color: var(--ink); width: 30px; height: 35px;
    cursor: pointer; padding: 0;
  }
}

/* ===== FULL-SCREEN MOBILE MENU ===== */
.full-menu {
  position: fixed; inset: 0; z-index: 200;
  background: var(--paper);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden;
  transition: opacity 0.4s cubic-bezier(0.16,1,0.3,1), visibility 0.4s cubic-bezier(0.16,1,0.3,1);
}
.full-menu.open { opacity: 1; visibility: visible; }
.full-menu-close {
  position: absolute; top: 24px; right: 24px;
  background: none; border: none; color: var(--ink); width: 30px; height: 44px; cursor: pointer; padding: 0;
}
.full-menu-inner { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.full-menu-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.full-menu-links a {
  font-family: 'Besley', serif; font-weight: 600;
  font-size: clamp(30px, 8vw, 46px); line-height: 1.3;
  color: var(--ink); text-decoration: none; transition: color 0.2s ease;
}
.full-menu-links a:hover, .full-menu-links a:focus-visible { color: var(--flash); }
.full-menu-sub {
  margin-top: 22px; font-weight: 500;
  font-size: 14px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-mid);
}
@media (prefers-reduced-motion: reduce) { .full-menu { transition: none; } }

/* ===== BUTTONS ===== */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 26px; border-radius: 999px; font-weight: 600; font-size: 15px;
  text-decoration: none; min-height: 44px; border: 1px solid transparent; cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, border-color 0.2s ease;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--whatsapp); color: var(--whatsapp-ink); }
.btn-primary:hover { background: #2be374; }
.btn-secondary { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--paper); }
.btn-ghost { background: transparent; border-color: var(--border); color: var(--ink); }
.btn-ghost:hover { background: var(--paper-alt); }
.btn-sm { padding: 10px 18px; font-size: 14px; min-height: 38px; }

/* ===== HERO ===== */
.hero { position: relative; padding: 56px 0 40px; overflow: hidden; }
.hero .container {
  display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: center;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--paper-alt); border: 1px solid var(--border); border-radius: 999px;
  padding: 8px 16px; font-size: 13px; font-weight: 600; color: var(--flash-deep);
  margin-bottom: 22px;
}
.hero-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--flash); flex-shrink: 0; }
.hero h1 {
  font-size: clamp(36px, 5vw, 58px); line-height: 1.06; letter-spacing: -0.015em;
  margin-bottom: 20px;
}
.hero h1 .accent { color: var(--flash); }
.hero p.lede { font-size: clamp(16px, 1.5vw, 19px); max-width: 52ch; color: var(--ink-mid); margin-bottom: 30px; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 34px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 22px 30px; font-size: 14px; color: var(--ink-mid); }
.hero-meta strong { color: var(--ink); font-weight: 600; }

/* Hero-side Print Fan preview — three prints that rotate through the
   "in focus" centre spot on a timer, snap to a click, and reveal one another
   with a hover-blur so it's always clear which print you're looking at. */
.hero-fan-preview {
  position: relative; height: 420px; perspective: 1400px;
}
/* Card height is content-driven (auto), never a fixed aspect-ratio on the card
   itself — the photo inside keeps its true 4:5 ratio, so nothing ever crops
   and the caption strip never overlaps the image. All 4 cards stay visible at
   all times; only which slot (position/size) each one occupies rotates. */
.hero-fan-preview .fan-card {
  position: absolute; top: 50%; left: 50%; width: 200px; height: auto;
  transform-origin: center center; cursor: pointer;
  transition: transform 0.85s cubic-bezier(.22,1,.36,1), filter 0.3s ease;
  filter: brightness(0.94);
}
.hero-fan-preview .fan-card .print-photo { height: auto; aspect-ratio: 4/5; }
.hero-fan-preview .fan-card.slot-center { transform: translate(-50%,-50%) translateY(-4px) scale(1.03); z-index: 4; filter: none; }
.hero-fan-preview .fan-card.slot-left   { transform: translate(-50%,-50%) translate(-104px, 20px) rotate(-10deg) scale(0.8); z-index: 2; }
.hero-fan-preview .fan-card.slot-right  { transform: translate(-50%,-50%) translate(104px, 20px) rotate(10deg) scale(0.8); z-index: 3; }
.hero-fan-preview .fan-card.slot-back   { transform: translate(-50%,-50%) translateY(-42px) scale(0.86); z-index: 1; filter: brightness(0.88); }
.hero-fan-preview .fan-card.slot-left:hover   { transform: translate(-50%,-50%) translate(-88px, 10px) rotate(-6deg) scale(0.9); filter: none; }
.hero-fan-preview .fan-card.slot-right:hover  { transform: translate(-50%,-50%) translate(88px, 10px) rotate(6deg) scale(0.9); filter: none; }
.hero-fan-preview .fan-card.slot-center:hover { transform: translate(-50%,-50%) translateY(-4px) scale(1.08); }
.hero-fan-preview .fan-card.slot-back:hover   { transform: translate(-50%,-50%) translateY(-42px) scale(0.92); filter: none; }
.hero-fan-preview:has(.fan-card:hover) .fan-card:not(:hover) { filter: blur(3px) brightness(0.7); }
@media (prefers-reduced-motion: reduce) {
  .hero-fan-preview .fan-card { transition: filter 0.3s ease; }
}
@media (max-width: 980px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-fan-preview { height: 340px; order: -1; margin-bottom: 8px; }
}
@media (max-width: 640px) {
  .hero { padding: 32px 0 28px; }
  .hero-fan-preview { height: 300px; }
  .hero-fan-preview .fan-card { width: 158px; }
  .hero-fan-preview .fan-card.slot-left  { transform: translate(-50%,-50%) translate(-72px, 16px) rotate(-10deg) scale(0.8); }
  .hero-fan-preview .fan-card.slot-right { transform: translate(-50%,-50%) translate(72px, 16px) rotate(10deg) scale(0.8); }
  .hero-fan-preview .fan-card.slot-back  { transform: translate(-50%,-50%) translateY(-34px) scale(0.86); }
}

/* ===== PRINT-STYLE CARD (shared: hero preview + gallery fan) ===== */
.print-card {
  background: var(--white); border-radius: 6px; padding: 10px 10px 34px;
  box-shadow: var(--shadow-card);
  position: relative; overflow: hidden;
}
.print-card::after {
  /* faint paper-grain texture */
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 2;
  opacity: 0.05; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.print-card .print-photo {
  width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: 2px; display: block;
  background: var(--paper-alt);
}
.print-card .print-cap {
  position: absolute; left: 0; right: 0; bottom: 0; height: 34px;
  display: flex; align-items: center; justify-content: center;
  font-family: 'Besley', serif; font-size: 12px; font-weight: 600; letter-spacing: 0.02em;
  color: var(--ink-mid);
}

/* ===== SECTION SHELL ===== */
section { padding: 88px 0; position: relative; z-index: 1; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 52px; }
.section-eyebrow { font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--flash-deep); font-weight: 700; margin-bottom: 14px; }
.section-head h2 { font-size: clamp(28px, 4vw, 42px); margin-bottom: 14px; }
.section-head p { max-width: 52ch; margin: 0 auto; }
.alt-bg { background: var(--paper-alt); }
@media (max-width: 640px) { section { padding: 64px 0; } }

/* CSS Scroll-Driven Animation — native entrance reveal, zero JS. */
@supports (animation-timeline: view()) {
  .service-card, .studio-card, .step, .faq-item, .footer-col {
    animation: reveal-up linear both;
    animation-timeline: view();
    animation-range: entry 0% cover 30%;
  }
  @keyframes reveal-up {
    from { transform: translateY(24px); }
    to   { transform: translateY(0); }
  }
}
@media (prefers-reduced-motion: reduce) {
  .studio-card, .step, .faq-item, .footer-col { animation: none !important; }
}

/* ===== GALLERY — Daniel Lopez-style masonry collage, straight off the hero ===== */
#work { padding-top: 28px; }
@media (max-width: 640px) { #work { padding-top: 20px; } }
.mason-grid { column-count: 4; column-gap: 14px; }
.mason-item {
  break-inside: avoid; margin-bottom: 14px; border-radius: 8px; overflow: hidden;
  cursor: pointer; box-shadow: var(--shadow-card);
}
.mason-item img { width: 100%; display: block; transition: transform 0.4s ease; }
.mason-item:hover img { transform: scale(1.035); }
@media (prefers-reduced-motion: reduce) { .mason-item img { transition: none; } }
@media (max-width: 980px) { .mason-grid { column-count: 3; } }
@media (max-width: 640px) { .mason-grid { column-count: 2; column-gap: 10px; } .mason-item { margin-bottom: 10px; } }

.fan-cta { text-align: center; margin-top: 44px; }

/* ===== LIGHTBOX ===== */
.lightbox {
  position: fixed; inset: 0; z-index: 300;
  display: none; align-items: center; justify-content: center;
  padding: 24px; background: rgba(36,31,26,0.72);
}
.lightbox.open { display: flex; }
.lightbox-inner {
  width: 100%; max-width: 640px; max-height: 88vh;
  background: var(--white); border-radius: var(--radius); padding: 20px; overflow: hidden;
  display: flex; flex-direction: column;
  box-shadow: 0 30px 80px rgba(0,0,0,0.4);
}
.lightbox-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; flex-shrink: 0; }
.lightbox-title { font-family: 'Besley', serif; font-size: 18px; font-weight: 600; color: var(--ink); }
.lightbox-close {
  width: 40px; height: 40px; border-radius: 999px; border: 1px solid var(--border);
  background: var(--paper-alt); color: var(--ink); cursor: pointer;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.lightbox-close:hover { background: var(--border); }
.lightbox-img { width: 100%; border-radius: var(--radius-sm); object-fit: contain; max-height: 70vh; }
@media (max-width: 640px) { .lightbox-inner { padding: 14px; } }

/* ===== STUDIO ===== */
.studio-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: stretch; }
.studio-card {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 36px; display: flex; flex-direction: column; justify-content: center;
}
.studio-card h3 { font-size: 22px; margin-bottom: 14px; }
.studio-row { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 16px; }
.studio-row .ic { color: var(--flash); flex-shrink: 0; margin-top: 3px; }
.studio-row .ic-whatsapp { color: var(--whatsapp); }
.studio-row div { font-size: 15px; color: var(--ink-mid); }
.studio-row strong { color: var(--ink); display: block; font-size: 14px; margin-bottom: 2px; }
.map-wrap { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); min-height: 320px; }
.map-wrap iframe { width: 100%; height: 100%; min-height: 320px; border: 0; display: block; }
@media (max-width: 860px) { .studio-grid { grid-template-columns: 1fr; } }

/* ===== HOW BOOKING WORKS ===== */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.step { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 30px 26px; text-align: center; }
.step-num {
  width: 40px; height: 40px; border-radius: 50%; background: var(--flash); color: var(--white);
  display: flex; align-items: center; justify-content: center; font-family: 'Besley', serif; font-weight: 700;
  margin: 0 auto 18px;
}
.step h3 { font-size: 17px; margin-bottom: 8px; }
.step p { font-size: 14.5px; margin: 0; }
@media (max-width: 780px) { .steps { grid-template-columns: 1fr; } }

/* ===== FAQ ===== */
.faq-list { max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 4px 22px;
}
.faq-item summary {
  padding: 18px 0; font-family: 'Besley', serif; font-weight: 600; font-size: 16.5px;
  color: var(--ink); cursor: pointer; list-style: none; position: relative;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; font-family: 'Sora', sans-serif; font-weight: 600; font-size: 22px;
  color: var(--flash); flex-shrink: 0; transition: transform 0.25s ease;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { padding-bottom: 18px; margin: -4px 0 0; font-size: 15px; }

/* ===== FOOTER ===== */
footer { padding: 56px 0 100px; border-top: 1px solid var(--border); background: var(--paper-alt); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 36px; }
@media (max-width: 780px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-brand { font-family: 'Besley', serif; font-weight: 700; font-size: 20px; margin-bottom: 10px; }
.footer-brand span { color: var(--flash); }
.footer-col .k { font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--flash-deep); font-weight: 700; margin-bottom: 10px; }
.footer-col .v { font-size: 15px; color: var(--ink); margin-bottom: 8px; }
.footer-col .v a { color: var(--ink); text-decoration: none; }
.footer-col .v a:hover { color: var(--flash-deep); }
.foot-fine { font-size: 13px; color: var(--ink-mid); text-align: center; padding-top: 24px; border-top: 1px solid var(--border); }
.foot-fine a { color: var(--ink-mid); text-decoration: underline; }
@media (max-width: 760px) { footer { padding-bottom: 100px; } }

/* ===== STICKY MOBILE CTA BAR ===== */
.sticky-bar { display: none; }
@media (max-width: 760px) {
  .sticky-bar {
    display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 90;
    background: rgba(250,246,240,0.95); backdrop-filter: blur(14px);
    border-top: 1px solid var(--border); padding: 10px 16px; gap: 10px;
  }
  .sticky-bar .btn { flex: 1; justify-content: center; }
  body:has(.lightbox.open) .sticky-bar,
  body:has(.full-menu.open) .sticky-bar { display: none; }
}
