/* ==========================================================================
   Call the Papaurazzi
   Palette + global tokens
   ========================================================================== */

:root {
  --color-1: #FF6DB6;  /* hot pink   */
  --color-2: #9185F5;  /* periwinkle */
  --color-3: #D9FF74;  /* lime       */
  --color-4: #DF96A0;  /* dusty rose */
  --color-5: #FFF4FF;  /* cream pink */

  --ink: #3B2340;
  --ink-soft: #6B4A6E;

  --font-display: "Fredoka", "Trebuchet MS", "Comic Sans MS", sans-serif;
  --font-body: Verdana, Geneva, "DejaVu Sans", sans-serif;

  --edge: 3px solid var(--ink);
  --shadow: 6px 6px 0 var(--ink);
  --shadow-sm: 4px 4px 0 var(--ink);
  --radius: 18px;

  --wrap: 1120px;
}

/* Registered so the conic-gradient angle is animatable, not just swapped. */
@property --a-from {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--color-5);          /* solid, never a gradient */
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-text-size-adjust: 100%;
}

img { max-width: 100%; height: auto; display: block; }

a { color: inherit; }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin: 0;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}

.sep { opacity: .5; padding-inline: 4px; }

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--color-5);
  padding: 12px 18px;
  z-index: 100;
}
.skip:focus { left: 8px; top: 8px; }

:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
  padding: 14px 28px;
  border: var(--edge);
  border-radius: 999px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease;
}
.btn:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }

.btn-primary { background: var(--color-1); color: var(--color-5); }
.btn-ghost   { background: var(--color-3); color: var(--ink); }
.btn-full    { width: 100%; font-size: 1.1rem; }

/* ==========================================================================
   Nav
   ========================================================================== */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 10px 24px;
  background: var(--color-1);
  border-bottom: var(--edge);
}

.nav-logo { display: block; line-height: 0; }
.nav-logo img {
  height: 58px;
  width: auto;
  border: 2px solid var(--ink);
  border-radius: 10px;
}

.nav nav { display: flex; gap: 6px; }

.nav nav a {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  color: var(--ink);
  background: var(--color-5);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 9px 20px;
  transition: background .12s ease, color .12s ease;
}
.nav nav a:hover { background: var(--color-3); }

/* ==========================================================================
   Ticker  --  currently unused: the banner markup is commented out in
   index.html. These rules are kept so re-enabling it needs no CSS changes.
   ========================================================================== */

.ticker {
  background: var(--color-2);
  border-bottom: var(--edge);
  overflow: hidden;
  padding: 9px 0;
}

.ticker-track {
  display: flex;
  align-items: center;
  width: max-content;
  /* --ticker-shift is one set's width, set by script.js. Shifting by exactly
     one set means the reset lands on an identical frame, so the loop is
     seamless. The 100% fallback keeps it sane if the script never runs. */
  animation: ticker-scroll var(--ticker-duration, 40s) linear infinite;
}

.ticker-set {
  display: flex;
  align-items: center;
  gap: 22px;
  padding-right: 22px;   /* same rhythm across the seam as within a set */
  flex: none;
}

.ticker-track span {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .82rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--color-5);
  white-space: nowrap;
}

.ticker .dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--color-3);
  flex: none;
}

@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(calc(-1 * var(--ticker-shift, 100%))); }
}

/* ==========================================================================
   Aura frames  (the glow lives behind the photo, not on the page background)
   ========================================================================== */

.aura {
  position: relative;
  margin: 0;
  isolation: isolate;
  padding: 26px;
}

.aura::before {
  content: "";
  position: absolute;
  inset: -5%;
  z-index: -1;
  border-radius: 50%;
  background: conic-gradient(
    from var(--a-from, 0deg),
    var(--a1) 0deg,
    var(--a2) 90deg,
    var(--a3) 180deg,
    var(--a4) 270deg,
    var(--a1) 360deg
  );
  filter: blur(36px);
  opacity: .95;
  transform: scale(1.02);
  animation: swirl 26s linear infinite;
}

.aura img {
  position: relative;
  z-index: 1;
  width: 100%;
  border: var(--edge);
  border-radius: 6px;
  box-shadow: var(--shadow);
}

@keyframes swirl {
  from { --a-from: 0deg;   transform: scale(1.02) rotate(0deg); }
  to   { --a-from: 360deg; transform: scale(1.02) rotate(360deg); }
}

/* per-photo aura palettes */
.aura-a { --a1: #6FC7FF; --a2: var(--color-3); --a3: var(--color-1); --a4: var(--color-2); }
.aura-b { --a1: var(--color-2); --a2: #6FC7FF; --a3: var(--color-3); --a4: var(--color-1); }
.aura-c { --a1: #FFB25E; --a2: var(--color-1); --a3: var(--color-2); --a4: #FFE27A; }
.aura-d { --a1: var(--color-1); --a2: var(--color-4); --a3: var(--color-2); --a4: var(--color-3); }
.aura-e { --a1: var(--color-3); --a2: #6FC7FF; --a3: var(--color-1); --a4: #FFB25E; }
.aura-f { --a1: var(--color-1); --a2: #FFB25E; --a3: #FFE27A; --a4: var(--color-4); }
.aura-g { --a1: #6FC7FF; --a2: var(--color-2); --a3: #7CFCE0; --a4: var(--color-3); }
.aura-h { --a1: var(--color-2); --a2: #6FC7FF; --a3: #7CFCE0; --a4: var(--color-4); }
.aura-i { --a1: #FF5E3A; --a2: #FFB25E; --a3: var(--color-1); --a4: #FFE27A; }
.aura-j { --a1: #FF5E3A; --a2: var(--color-2); --a3: #FFB25E; --a4: var(--color-1); }
.aura-k { --a1: #FFB25E; --a2: #6FC7FF; --a3: #FF5E3A; --a4: var(--color-1); }
.aura-hero { --a1: #FFB25E; --a2: var(--color-1); --a3: var(--color-2); --a4: #6FC7FF; }

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

.hero {
  position: relative;
  background: var(--color-5);
  padding: 72px 0 84px;
  border-bottom: var(--edge);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--color-2);
  margin: 0 0 18px;
}

.hero h1 {
  font-size: clamp(2.6rem, 6.4vw, 4.6rem);
  color: var(--color-1);
  text-shadow: 4px 4px 0 var(--color-2);
  margin-bottom: 24px;
}

.lede {
  font-size: 1.06rem;
  max-width: 34em;
  color: var(--ink-soft);
  margin: 0 0 32px;
}

.hero-btns { display: flex; gap: 14px; flex-wrap: wrap; }

.hero-photo { display: flex; justify-content: center; }
.hero-photo .aura { max-width: 380px; }

/* Two prints fanned like a pair of photos set down together. Because they
   overlap, the glow belongs to the pair and not to each card -- an .aura per
   card meant the front photo's glow painted across the back one. So the
   wrapper is the .aura here and the figures are plain frames inside it;
   `.aura img` still styles both photos. */
.hero-pair { max-width: 460px; margin-inline: auto; align-items: flex-start; }
.hero-pair .print { position: relative; margin: 0; flex: 0 1 198px; }
.hero-pair .print:first-child { transform: rotate(-3deg); z-index: 1; }
/* 198px photos and a 12px gap reproduce the original spacing: back when each
   card carried its own 26px aura padding, a -40px margin between the padded
   boxes left the photos themselves 12px apart. */
.hero-pair .print:last-child  { transform: rotate(3deg); margin: 44px 0 0 12px; }

/* CSS four point sparkles */
.sparkles { position: absolute; inset: 0; pointer-events: none; }
.spark {
  position: absolute;
  width: 26px;
  height: 26px;
  background: var(--color-3);
  clip-path: polygon(50% 0%, 60% 40%, 100% 50%, 60% 60%, 50% 100%, 40% 60%, 0% 50%, 40% 40%);
  animation: twinkle 4s ease-in-out infinite;
}
.s1 { top: 12%;  left: 4%;  }
.s2 { top: 68%;  left: 46%; background: var(--color-1); width: 18px; height: 18px; animation-delay: 1.1s; }
.s3 { top: 30%;  right: 3%; background: var(--color-2); width: 22px; height: 22px; animation-delay: 2.2s; }
.s4 { bottom: 8%; left: 20%; width: 15px; height: 15px; animation-delay: 3s; }

@keyframes twinkle {
  0%, 100% { opacity: .25; transform: scale(.7) rotate(0deg); }
  50%      { opacity: 1;   transform: scale(1) rotate(45deg); }
}

/* ==========================================================================
   About
   ========================================================================== */

.about {
  overflow-x: clip;   /* contain the aura glow's -5% bleed */
  background: var(--color-2);
  color: var(--color-5);
  padding: 84px 0;
  border-bottom: var(--edge);
}

.about-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 56px;
  align-items: center;
}

.about-photo .aura { max-width: 360px; margin-inline: auto; }

.section-title {
  font-size: clamp(2rem, 4.4vw, 3rem);
  margin-bottom: 26px;
}

.about .section-title {
  color: var(--color-3);
  text-shadow: 3px 3px 0 var(--ink);
}

.about p { margin: 0 0 18px; }

.about .pull {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.16rem;
  line-height: 1.5;
  color: var(--color-3);
  border-left: 5px solid var(--color-1);
  padding-left: 20px;
  margin-top: 28px;
}

/* ==========================================================================
   Gallery
   ========================================================================== */

.gallery {
  overflow-x: clip;   /* contain the aura glow's -5% bleed */
  background: var(--color-5);
  padding: 84px 0 92px;
  border-bottom: var(--edge);
}

.center { text-align: center; }

.gallery .section-title {
  color: var(--color-1);
  text-shadow: 3px 3px 0 var(--color-2);
  margin-bottom: 12px;
}

.section-sub {
  text-align: center;
  color: var(--ink-soft);
  margin: 0 0 52px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
  /* One shared stacking context for the whole row. Without this each figure
     isolates itself, so a later card's glow -- which spills well past its own
     box -- paints over the earlier cards' photos. */
  isolation: isolate;
}

/* Let the gallery glows out of their per-figure layer so they all sit at the
   same depth, behind every photo in the row rather than just their own.
   The hero and About auras keep their isolation: they stand alone, and their
   sections establish no stacking context to escape into. */
.gallery-grid .aura { isolation: auto; }

/* The source photos have differing aspect ratios (0.83 / 0.75 / 0.71), which
   made the cards render at different heights. Lock every gallery image to one
   frame and let object-fit crop the overflow instead. */
.gallery-grid .aura img {
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center;
}

/* photo-6 is landscape, and a 3/4 crop would cut its outer two prints off. It
   spans two columns instead, at the 8/5 ratio that makes a double-wide card
   land at the same height as its 3/4 neighbours. */
.gallery-grid .wide { grid-column: span 2; }
.gallery-grid .wide img { aspect-ratio: 8 / 5; }

/* Hover: the aura behind the photo blooms instead of the card lifting.
   The flare lives on ::after so the slow ::before swirl keeps its position --
   restarting the shorthand on ::before would snap its rotation angle. */
.gallery-grid .aura::after {
  content: "";
  position: absolute;
  inset: -5%;
  z-index: -1;
  border-radius: 50%;
  background: conic-gradient(
    from 90deg,
    var(--a1) 0deg,
    var(--a2) 90deg,
    var(--a3) 180deg,
    var(--a4) 270deg,
    var(--a1) 360deg
  );
  filter: blur(36px);
  opacity: 0;
  pointer-events: none;
}

.gallery-grid .aura:hover::after {
  animation: aura-flare 1.15s ease-out;
}

/* The resting glow lifts a little too -- a transition, so it never restarts. */
.gallery-grid .aura::before { transition: opacity .35s ease; }
.gallery-grid .aura:hover::before { opacity: 1; }

@keyframes aura-flare {
  0%   { opacity: 0;   transform: scale(.96) rotate(0deg); }
  30%  { opacity: .9;  transform: scale(1.13) rotate(50deg); }
  100% { opacity: 0;   transform: scale(1.28) rotate(125deg); }
}

/* ==========================================================================
   Book + form
   ========================================================================== */

.book {
  background: var(--color-3);
  padding: 84px 0;
  border-bottom: var(--edge);
}

.book-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: start;
}

.book .section-title {
  color: var(--color-1);
  text-shadow: 3px 3px 0 var(--color-5);
}

.book-copy p { color: var(--ink); margin: 0 0 28px; }

.contact-list { list-style: none; margin: 0; padding: 0; }

.contact-list li {
  background: var(--color-5);
  border: var(--edge);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  padding: 14px 20px;
  margin-bottom: 14px;
}

.contact-list .label {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .72rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--color-2);
}

.contact-list a {
  display: flex;
  align-items: center;
  min-height: 44px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--color-1);
  text-decoration: none;
  word-break: break-word;
}
.contact-list a:hover { text-decoration: underline; }

.form-card {
  background: var(--color-5);
  border: var(--edge);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 32px;
}

.form-card h3 {
  font-size: 1.7rem;
  color: var(--color-1);
  margin-bottom: 22px;
}

.field { margin-bottom: 20px; }

.field label {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--color-2);
  margin-bottom: 7px;
}

.field input,
.field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: #fff;
  border: 2px solid var(--ink);
  border-radius: 10px;
  padding: 12px 14px;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--color-1);
  box-shadow: 3px 3px 0 var(--color-1);
}

.field.invalid input,
.field.invalid textarea { border-color: #C22B5A; }

.err {
  margin: 6px 0 0;
  font-size: .82rem;
  color: #C22B5A;
  min-height: 0;
}

.form-note {
  font-size: .8rem;
  line-height: 1.6;
  color: var(--ink-soft);
  margin: 16px 0 0;
}
.form-note a { color: var(--color-1); }

.form-note.sent {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .95rem;
  color: var(--ink);
  background: var(--color-3);
  border: 2px solid var(--ink);
  border-radius: 10px;
  padding: 12px 14px;
}

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

.foot {
  background: var(--color-1);
  padding: 56px 0 44px;
  text-align: center;
}

.foot-logo {
  width: 260px;
  margin: 0 auto 26px;
  border: var(--edge);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}

.foot-links {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.foot-links a {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  color: var(--ink);
  background: var(--color-5);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 8px 20px;
}
.foot-links a:hover { background: var(--color-3); }

.foot-fine {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: .76rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--color-5);
  margin: 0;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 900px) {
  .hero-grid,
  .about-grid,
  .book-grid { grid-template-columns: 1fr; gap: 44px; }

  .about-grid .about-photo { order: 2; }
  .about-grid .about-copy  { order: 1; }

  .gallery-grid { grid-template-columns: repeat(2, 1fr); }

  .hero { padding: 52px 0 64px; }
  .about, .gallery, .book { padding: 60px 0; }
}

@media (max-width: 620px) {
  .nav { justify-content: center; padding: 10px 16px; }
  .nav nav a { padding: 9px 15px; font-size: .92rem; }   /* keep the 44px tap target */
  .wrap { padding-inline: 18px; }
  .gallery-grid { grid-template-columns: 1fr; max-width: 380px; margin-inline: auto; }
  .gallery-grid .wide { grid-column: auto; }
  .hero-pair .print:last-child { margin: 28px 0 0 16px; }
  .form-card { padding: 24px 20px; }
  .aura { padding: 20px; }
  .btn { width: 100%; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker-track,
  .aura::before,
  .gallery-grid .aura:hover::after,
  .spark { animation: none; }
  .spark { opacity: .8; }
  .btn:hover { transform: none; }
}
