/* ============================================================
   Kristi Rents — Public Landing Page
   Matches Landlord Portal brand:
   Dark Green #004D40  •  Gold #FBC02D  •  Segoe UI
   ============================================================ */

:root {
    --green:        #004D40;
    --green-light:  #00695C;
    --green-faint:  #e8f5e9;
    --gold:         #FBC02D;
    --gold-hover:   #F9A825;
    --bg:           #f0f4f2;
    --white:        #ffffff;
    --border:       #ddd;
    --text:         #333333;
    --text-muted:   #777777;
    --danger:       #C62828;
    --danger-hover: #B71C1C;
    --success:      #2e7d32;
    --radius:       6px;
    --logo-size:    300px;
}

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

html, body { height: 100%; }

body.landing-body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ══════════════════════════════════════════════
   HERO — top half of screen, 21:9 slideshow
   Logo and tagline are absolutely-positioned overlays
   living inside this section so they sit on top of the
   slideshow images.
══════════════════════════════════════════════ */
.hero {
    flex: 0 0 50vh;
    min-height: 320px;
    background: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;      /* let the 300x300 logo peek over the edge cleanly */
    position: relative;
}

/* ── 300x300 floating logo, upper-left of the page ── */
.logo-overlay {
    position: absolute;
    top: 16px;
    left: 20px;
    width:  var(--logo-size);
    height: var(--logo-size);
    object-fit: contain;
    cursor: context-menu;
    z-index: 15;
    user-select: none;
    -webkit-user-drag: none;
    filter: drop-shadow(0 4px 14px rgba(0,0,0,0.55))
            drop-shadow(0 0 2px rgba(255,255,255,0.35));
    transition: transform 0.25s ease;
    pointer-events: auto;
}
.logo-overlay:hover { transform: scale(1.03); }

/* ── Tagline at upper-right of the hero ── */
.tagline-overlay {
    position: absolute;
    top: 24px;
    right: 28px;
    z-index: 15;
    color: var(--gold);
    font-size: 14px;
    letter-spacing: 0.8px;
    font-weight: 700;
    text-transform: uppercase;
    padding: 6px 14px;
    background: rgba(0,77,64,0.72);
    border-radius: 999px;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    box-shadow: 0 2px 10px rgba(0,0,0,0.35);
    pointer-events: none;
}

.hero-stage {
    position: relative;
    height: 100%;
    aspect-ratio: 21 / 9;
    max-width: 100%;
    background: #000;
    overflow: hidden;
    box-shadow: 0 6px 28px rgba(0,0,0,0.25);
}

/* When the 21:9 stage is taller than the viewport allows, scale width down */
@media (max-aspect-ratio: 21/9) {
    .hero-stage {
        width: 100%;
        height: auto;
        aspect-ratio: 21 / 9;
    }
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0;
    transition: opacity 2.5s ease-in-out;
    will-change: opacity;
}
.hero-slide.is-active { opacity: 1; }

/* Blurred top / bottom edges — two strips that progressively blur
   the image and fade it into the page background, so the picture
   appears to "melt" into the surroundings. */
.hero-fade {
    position: absolute;
    left: 0;
    right: 0;
    pointer-events: none;
    z-index: 2;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}
.hero-fade.top {
    top: 0;
    height: 18%;
    background: linear-gradient(
        to bottom,
        var(--bg)          0%,
        rgba(240,244,242,0.85) 40%,
        rgba(240,244,242,0)   100%
    );
    -webkit-mask-image: linear-gradient(to bottom, black 0%, black 55%, transparent 100%);
            mask-image: linear-gradient(to bottom, black 0%, black 55%, transparent 100%);
}
/* Softer, subtler bottom blend: a ~100px strip where the image
   gently fades into the page background.  No blur, no mask — just
   a single smooth alpha gradient from transparent at the top of
   the strip to the full page background at the bottom.  This
   removes the "frosted band" look the previous rule produced. */
.hero-fade.bottom {
    bottom: 0;
    height: 100px;                       /* ~100px fade area, as requested */
    backdrop-filter: none;               /* kill blur on the bottom edge */
    -webkit-backdrop-filter: none;
    background: linear-gradient(
        to bottom,
        rgba(240, 244, 242, 0)   0%,     /* fully see-through — image shows */
        rgba(240, 244, 242, 0.55) 55%,
        var(--bg)               100%     /* full page background */
    );
    -webkit-mask-image: none;
            mask-image: none;
}

/* Soft vignette to match portal palette */
.hero-vignette {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 3;
    box-shadow: inset 0 0 120px rgba(0,0,0,0.35);
}

/* ══════════════════════════════════════════════
   CARDS ROW — bottom half
══════════════════════════════════════════════ */
.cards-wrap {
    flex: 1 1 auto;
    padding: 32px 24px 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
}

.cards-row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 22px;
    width: 100%;
    max-width: 1400px;
}

.lcard {
    background: var(--white);
    border-radius: var(--radius);
    padding: 22px 20px 24px;
    box-shadow: 0 3px 14px rgba(0,0,0,0.10);
    display: flex;
    flex-direction: column;
    min-height: 240px;
    border-top: 4px solid var(--gold);
    transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.lcard:hover { transform: translateY(-3px); box-shadow: 0 6px 22px rgba(0,0,0,0.15); }

.lcard .lcard-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--green);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold);
    margin-bottom: 14px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.lcard .lcard-body {
    flex: 1;
    font-size: 13.5px;
    line-height: 1.55;
    color: var(--text);
}

.lcard .lcard-actions {
    margin-top: 14px;
    display: flex;
    justify-content: flex-end;
}

/* ── Buttons (shared with portal) ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border: none;
    border-radius: var(--radius);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.14s, opacity 0.14s, transform 0.1s;
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
    font-family: inherit;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn-primary  { background: var(--green); color: white; }
.btn-primary:hover:not(:disabled) { background: var(--green-light); }
.btn-gold     { background: var(--gold); color: var(--green); }
.btn-gold:hover:not(:disabled) { background: var(--gold-hover); }
.btn-outline  { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover:not(:disabled) { background: #f5f5f5; }
.btn-block    { width: 100%; justify-content: center; }

/* ══════════════════════════════════════════════
   MODALS
══════════════════════════════════════════════ */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 500;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}
.modal-overlay.open { display: flex; }

.modal-box {
    background: white;
    border-radius: var(--radius);
    width: 440px;
    max-width: 95vw;
    max-height: 92vh;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0,0,0,0.35);
    display: flex;
    flex-direction: column;
    animation: modalPop 0.18s ease-out;
}
/* Wider waitlist modal to host the address fields */
.modal-box.wl-modal { width: 560px; }

/* Row layouts inside the waitlist form */
.wl-row         { display: grid; gap: 12px; }
.wl-row.two     { grid-template-columns: 1fr 1fr; }
.wl-row.csz     { grid-template-columns: 2fr 0.7fr 1fr; }
.wl-row .form-group { margin-bottom: 14px; }
@media (max-width: 560px) {
    .wl-row.two, .wl-row.csz { grid-template-columns: 1fr; }
}
@keyframes modalPop {
    from { opacity: 0; transform: translateY(12px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}

.modal-header {
    padding: 14px 20px;
    background: var(--green);
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.modal-header h3 { font-size: 15px; margin: 0; font-weight: 700; letter-spacing: 0.3px; }
.modal-close {
    background: none; border: none;
    color: rgba(255,255,255,0.8);
    font-size: 22px; line-height: 1; cursor: pointer; padding: 0;
}
.modal-close:hover { color: white; }

.modal-body { padding: 22px 24px; }
.modal-footer {
    padding: 14px 20px;
    display: flex; gap: 10px; justify-content: flex-end;
    border-top: 1px solid #eee;
    background: #fafafa;
}

/* Form groups inside modals */
.form-group { display: flex; flex-direction: column; gap: 5px; margin-bottom: 14px; }
.form-group label {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.6px;
}
.form-group input {
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 14px;
    color: var(--text);
    background: white;
    transition: border-color 0.14s, box-shadow 0.14s;
    font-family: inherit;
}
.form-group input:focus {
    outline: none;
    border-color: var(--green);
    box-shadow: 0 0 0 2px rgba(0,77,64,0.12);
}

.form-error {
    color: var(--danger);
    background: #ffebee;
    border: 1px solid #ffcdd2;
    border-radius: var(--radius);
    padding: 9px 12px;
    font-size: 13px;
    margin-bottom: 12px;
    display: none;
    font-weight: 600;
}
.form-error.show { display: block; }

.form-info {
    color: var(--success);
    background: var(--green-faint);
    border: 1px solid #c8e6c9;
    border-radius: var(--radius);
    padding: 9px 12px;
    font-size: 13px;
    margin-bottom: 12px;
    display: none;
    font-weight: 600;
}
.form-info.show { display: block; }

/* Login-modal specific: disabled state during 10s lockout */
.modal-body.locked input,
.modal-body.locked button[type="submit"] { opacity: 0.5; pointer-events: none; }

.lockout-counter {
    display: none;
    font-size: 12px;
    color: var(--danger);
    margin-top: -6px;
    margin-bottom: 10px;
    font-weight: 600;
}
.lockout-counter.show { display: block; }

/* ══════════════════════════════════════════════
   Responsive
══════════════════════════════════════════════ */
@media (max-width: 1400px) {
    .cards-row { grid-template-columns: repeat(3, 1fr); max-width: 1100px; }
}
@media (max-width: 1100px) {
    .cards-row { grid-template-columns: repeat(2, 1fr); max-width: 760px; }
}
@media (max-width: 900px) {
    :root { --logo-size: 200px; }
    .tagline-overlay { font-size: 12px; top: 14px; right: 14px; }
}
@media (max-width: 640px) {
    .cards-row { grid-template-columns: 1fr; max-width: 420px; }
    :root { --logo-size: 140px; }
    .logo-overlay { top: 8px; left: 8px; }
    .tagline-overlay { display: none; }
    .hero { flex: 0 0 42vh; min-height: 260px; }
}

/* Toast (used for waitlist submission feedback) */
#kr-toast {
    position: fixed;
    bottom: 24px; right: 24px;
    padding: 12px 20px;
    border-radius: var(--radius);
    font-size: 13px;
    color: white;
    z-index: 9999;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.25s, transform 0.25s;
    pointer-events: none;
    max-width: 340px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.25);
    font-weight: 600;
}
#kr-toast.show         { opacity: 1; transform: translateY(0); }
#kr-toast.toast-success { background: var(--success); }
#kr-toast.toast-error   { background: var(--danger); }
#kr-toast.toast-info    { background: #1565c0; }
