/* =====================================================================
   Our Wedding Hub — public front-end stylesheet
   One CSS file for this area, per Blue Logic convention.

   Colours are Mel's confirmed palette (light latte, sage, white) —
   the exact hex values below are a reasonable placeholder, NOT
   confirmed swatches. Swap these three variables once Mel gives
   exact hex codes; nothing else needs to change.
   ===================================================================== */

:root {
    --color-latte: #F3EAD9;   /* placeholder — confirm exact hex */
    --color-sage:  #A3AD8C;   /* placeholder — confirm exact hex */
    --color-white: #FFFFFF;
    --color-text:  #33312E;
    --color-error: #B3413C;

    --font-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--font-base);
    background: var(--color-latte);
    color: var(--color-text);
}

a { color: inherit; }

/* ---- header / wordmark -------------------------------------------- */
/* No logo image yet (still waiting on the file from Mel) — plain text
   wordmark for now. Swap this block for an <img> once LOGO_PATH in
   config.php is set; nothing else in the layout needs to change. */
.site-header {
    background: var(--color-white);
    border-bottom: 1px solid var(--color-sage);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-header .wordmark {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.site-header nav a {
    margin-left: 1.5rem;
    text-decoration: none;
    font-size: 0.95rem;
}

/* ---- layout ---------------------------------------------------------- */
.page-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

.auth-wrap {
    max-width: 380px;
    margin: 4rem auto;
    background: var(--color-white);
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.auth-wrap h1 {
    margin-top: 0;
    font-size: 1.4rem;
}

/* ---- forms ------------------------------------------------------------ */
label { display: block; margin: 1rem 0 0.35rem; font-size: 0.9rem; }

input[type="text"],
input[type="email"],
input[type="password"],
select {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--color-sage);
    border-radius: 6px;
    font-size: 1rem;
    background: var(--color-white);
}

button, .btn {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.65rem 1.25rem;
    background: var(--color-sage);
    color: var(--color-white);
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
    text-decoration: none;
}

button:hover, .btn:hover { opacity: 0.9; }

.error {
    background: #FBEAE9;
    color: var(--color-error);
    padding: 0.75rem 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
    margin-top: 1rem;
}

.success {
    background: #EAF3E5;
    color: #3f6b2c;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
    max-width: 480px;
    margin: 0 auto 1.5rem;
    text-align: left;
}

.muted {
    color: #8a8a86;
    font-size: 0.9rem;
}

/* ---- hero -------------------------------------------------------------- */
.hero {
    background: var(--color-white);
    text-align: center;
    padding: 3.5rem 0;
    position: relative;
}

.hero h1 {
    font-size: 2.2rem;
    margin: 0 0 1rem;
}

.hero-subheading {
    font-size: 1.1rem;
    max-width: 640px;
    margin: 0 auto 1.5rem;
    color: #555;
}

.hero .btn { margin-top: 0; }

.hero-inner {
    position: relative;
    z-index: 1;
    width: 100%;
}

/* Full-bleed background photo — only renders once HERO_IMAGE_PATH is
   set in config.php (the inline background-image comes from there);
   left blank, .hero-has-image never applies and the hero stays the
   plain centred-text banner above. A dark scrim (::before) sits
   between the photo and the text so the heading/body stay readable
   over any photo Mel supplies, without hand-tuning per image. */
.hero-has-image {
    background-size: cover;
    background-position: center;
    min-height: 560px;
    display: flex;
    align-items: center;
    padding: 3rem 0;
    color: var(--color-white);
}

.hero-has-image::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(51, 49, 46, 0.45);
}

.hero-has-image .hero-subheading {
    color: rgba(255, 255, 255, 0.92);
}

/* ---- features ------------------------------------------------------------ */
.features {
    padding: 3rem 0;
}

.features h2 {
    text-align: center;
    font-size: 1.7rem;
    margin-bottom: 2rem;
}

.features-body {
    max-width: 760px;
    margin: 0 auto;
}

.features-body h3 {
    margin: 1.5rem 0 0.4rem;
    color: var(--color-text);
}

.features-body h3:first-child { margin-top: 0; }

.features-body p { margin: 0 0 0.75rem; line-height: 1.55; }

/* ---- contact CTA + form -------------------------------------------------- */
.cta {
    background: var(--color-white);
    padding: 3rem 0;
    border-top: 1px solid var(--color-sage);
}

.cta h2 {
    text-align: center;
    font-size: 1.6rem;
    margin-bottom: 0.5rem;
}

.cta-body {
    text-align: center;
    max-width: 560px;
    margin: 0 auto 1.5rem;
    color: #555;
}

.contact-form {
    max-width: 480px;
    margin: 0 auto;
    background: var(--color-latte);
    border-radius: 10px;
    padding: 1.75rem 2rem;
}

.contact-form textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid var(--color-sage);
    border-radius: 6px;
    font-size: 1rem;
    font-family: var(--font-base);
    background: var(--color-white);
    resize: vertical;
}

.contact-form button {
    width: 100%;
}

/* Honeypot field — invisible to a real visitor (off-screen, not just
   hidden, so a screen reader doesn't announce it either), still
   reachable by a bot's automated form-filler. See views/public/home.php. */
.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* ---- footer -------------------------------------------------------------- */
.site-footer {
    background: var(--color-text);
    color: var(--color-white);
    text-align: center;
    padding: 1.5rem 0;
    font-size: 0.85rem;
}

.site-footer a { color: var(--color-white); }

/* ---- narrow screens: stack things that are wider on desktop --------------- */
@media (max-width: 600px) {
    .page-wrap { padding: 1.25rem 1rem; }

    .hero { padding: 2.5rem 0; }
    .hero h1 { font-size: 1.6rem; }
    .hero-has-image { min-height: 420px; padding: 2.5rem 0; }

    .features { padding: 2rem 0; }
    .cta { padding: 2rem 0; }

    .contact-form { padding: 1.25rem; }

    .site-header nav a { margin-left: 1rem; }
}
