/* ==========================================================================
   Divine Journey Funeral Arrangements — styles
   Mobile-first: base styles target small screens; min-width queries scale up.
   Brand tokens (colors, fonts, radii) are documented in BRAND.md — keep in sync.
   ========================================================================== */

:root {
  /* 1 · Color palette (extracted from the official logo artwork) */
  --navy: #23365B;        /* Deep Navy Blue — headings, footer, primary accents */
  --navy-deep: #1A2947;   /* darker navy — footer bg, text on gold buttons      */
  --gold: #D8A037;        /* Warm Mustard Gold — interactive elements only       */
  --gold-deep: #B9822A;   /* gold for links on light bg + hover                  */
  --white: #FFFFFF;       /* Crisp White — card surfaces                         */
  --pearl: #F7F5F0;       /* Soft Pearl — page background                        */
  --ink: #414D68;         /* Muted Charcoal-Navy — body text                     */

  /* 2 · Typography */
  --font-serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-sans: "Montserrat", "Helvetica Neue", Arial, sans-serif;

  /* 3 · UI */
  --radius: 10px;         /* buttons, inputs, image frames */
  --radius-lg: 12px;      /* cards */
  --line: rgba(35, 54, 91, 0.16);
  --shadow: 0 18px 50px -18px rgba(26, 41, 71, 0.35);
  --wrap: 72rem;
}

/* ---------- Base ---------- */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--pearl);
}

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

h1, h2 {
  font-family: var(--font-serif);
  font-weight: 600;
  color: var(--navy);
  line-height: 1.15;
}

a { color: var(--gold-deep); }

::selection { background: var(--gold); color: var(--navy-deep); }

:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  background: var(--navy);
  color: var(--pearl);
  padding: 0.7rem 1.2rem;
  border-radius: var(--radius);
  text-decoration: none;
  font-size: 0.85rem;
  transition: top 0.2s ease;
}
.skip-link:focus { top: 1rem; color: var(--pearl); }

/* ---------- Buttons (gold = interactive only, per brand) ---------- */

.btn {
  display: inline-block;
  background: var(--gold);
  color: var(--navy-deep);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 1rem 2.4rem;
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  box-shadow: 0 10px 24px -10px rgba(216, 160, 55, 0.65);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.btn:hover {
  background: var(--gold-deep);
  transform: translateY(-1px);
  box-shadow: 0 14px 28px -10px rgba(185, 130, 42, 0.7);
}
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: 0.65; cursor: wait; transform: none; }

/* ---------- 1 · Hero ---------- */

.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 100vh;
  min-height: 100svh;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--pearl);
  padding: clamp(2.5rem, 7vw, 4.5rem) clamp(1.25rem, 5vw, 3rem);
}

.hero__bg { position: absolute; inset: 0; z-index: -2; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }

/* deep-blue grade over the photo + faint warm (golden-hour) tint at the horizon */
.hero__scrim {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(0deg, rgba(216, 160, 55, 0.12), rgba(216, 160, 55, 0) 38%),
    radial-gradient(130% 100% at 50% 0%, rgba(26, 41, 71, 0.30) 0%, rgba(26, 41, 71, 0.62) 62%, rgba(26, 41, 71, 0.85) 100%),
    linear-gradient(180deg, rgba(26, 41, 71, 0.55) 0%, rgba(26, 41, 71, 0.30) 45%, rgba(26, 41, 71, 0.80) 100%);
}

.hero__content { max-width: 46rem; }

.hero__logo {
  width: clamp(190px, 42vw, 280px);
  height: auto;
  margin: 0 auto clamp(1.5rem, 4vw, 2.5rem);
  filter: drop-shadow(0 12px 32px rgba(10, 18, 35, 0.45));
}

.hero h1 {
  margin: 0 0 1.25rem;
  font-size: clamp(2.1rem, 7vw, 3.6rem);
  color: var(--white);
}

.hero__lede {
  max-width: 56ch;
  margin: 0 auto;
  font-size: clamp(1rem, 2.6vw, 1.125rem);
  color: rgba(247, 245, 240, 0.92);
}

.hero__tagline {
  margin: 1.4rem 0 2.1rem;
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1rem, 2.4vw, 1.15rem);
  color: var(--gold);
}

/* ---------- 2 · Contact ---------- */

.contact {
  padding: clamp(4rem, 10vw, 7rem) clamp(1.25rem, 5vw, 3rem);
}

.contact__card {
  max-width: var(--wrap);
  margin: 0 auto;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: clamp(1.75rem, 5vw, 3.5rem);
  display: grid;
  gap: clamp(2rem, 5vw, 3.5rem);
}

@media (min-width: 56rem) {
  .contact__card {
    grid-template-columns: 1fr 1.4fr;
    align-items: start;
  }
}

.contact h2 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.8rem, 4.5vw, 2.6rem);
}

.contact__subtitle {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink);
}

/* form */
.form { display: grid; gap: 1.25rem; }

.form__row { display: grid; gap: 1.25rem; }
@media (min-width: 34rem) {
  .form__row--2 { grid-template-columns: 1fr 1fr; }
}

.field { display: grid; gap: 0.4rem; align-content: start; }

.field label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--navy);
}

.req { color: var(--gold-deep); }

.field input,
.field textarea {
  width: 100%;
  font: inherit;
  color: var(--navy-deep);
  background: #FCFBF8;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
}
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--gold);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(216, 160, 55, 0.22);
}
.field textarea { resize: vertical; min-height: 8.5rem; }

.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.form__actions { display: flex; }
@media (min-width: 34rem) {
  .form__actions { justify-content: flex-start; }
}
.form__actions .btn { width: 100%; }
@media (min-width: 34rem) {
  .form__actions .btn { width: auto; }
}

.form__status {
  display: none;
  margin: 0;
  padding: 0.9rem 1rem;
  border-radius: var(--radius);
  font-size: 0.95rem;
}
.form__status.is-visible { display: block; }
.form__status--ok {
  background: rgba(216, 160, 55, 0.12);
  border: 1px solid rgba(216, 160, 55, 0.55);
  color: var(--navy-deep);
}
.form__status--error {
  background: rgba(154, 59, 46, 0.08);
  border: 1px solid rgba(154, 59, 46, 0.4);
  color: #7C2D22;
}
.form__status a { color: inherit; font-weight: 600; }

/* ---------- 3 · Footer ---------- */

.footer {
  background: var(--navy-deep);
  color: rgba(247, 245, 240, 0.88);
  text-align: center;
  padding: clamp(3rem, 8vw, 4.5rem) 1.5rem 2.5rem;
}

.footer__logo {
  width: 128px;
  height: auto;
  margin: 0 auto 1.75rem;
  opacity: 0.95;
}

.footer__line { margin: 0.3rem 0; font-size: 0.98rem; }

.footer a { color: var(--gold); text-decoration: none; }
.footer a:hover { text-decoration: underline; }

.footer__credit {
  margin: 1.25rem auto 0;
  max-width: 40rem;
  font-size: 0.72rem;
  line-height: 1.6;
  color: rgba(247, 245, 240, 0.5);
}
.footer__credit a { color: rgba(247, 245, 240, 0.75); text-decoration: underline; }

.footer__copy {
  margin-top: 2.25rem;
  font-size: 0.78rem;
  color: rgba(247, 245, 240, 0.55);
}

/* ---------- Motion preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn, .skip-link { transition: none; }
}
