/* ==========================================================================
   bitmapped - www.bitmapped.com
   Blue-themed landing + admin login
   ========================================================================== */

:root {
    --blue-900: #003a6b;
    --blue-800: #0b5394;
    --blue-700: #1565c0;
    --blue-600: #1976d2;
    --blue-500: #1e88e5;
    --blue-400: #42a5f5;
    --blue-300: #90caf9;
    --blue-100: #e3f2fd;
    --blue-50:  #f4faff;

    --sky-gradient: linear-gradient(180deg, #cfe8ff 0%, #eaf5ff 45%, #ffffff 100%);
    --hero-gradient: linear-gradient(135deg, #1e88e5 0%, #1565c0 60%, #0b5394 100%);

    --ink:        #0f1e2e;
    --ink-soft:   #3b4a5c;
    --ink-muted:  #6b7a8d;
    --border:     #d7e5f3;
    --bg:         #ffffff;
    --bg-alt:     #f4faff;

    --shadow-sm: 0 2px 6px rgba(10, 60, 110, 0.08);
    --shadow-md: 0 10px 25px rgba(10, 60, 110, 0.12);
    --shadow-lg: 0 25px 60px rgba(10, 60, 110, 0.22);

    --radius:    14px;
    --radius-sm: 8px;
    --radius-lg: 22px;

    --container: 1180px;

    /* Fonts */
    --font-ui:    "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-brand: "Comfortaa", "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

    /* Custom cursor: arrow + blue waypoint pin.  Hotspot at (2,2). */
    --bm-cursor: url("cursor.svg") 2 2, auto;
}

/* ---------- Base ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font-ui);
    color: var(--ink);
    background: var(--bg);
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    cursor: var(--bm-cursor);
}

/* The bitmapped wordmark uses Comfortaa everywhere it is written out. */
.brand-text,
.bm-name {
    font-family: var(--font-brand);
    font-weight: 700;
    letter-spacing: -0.01em;
}

/* Apply the waypoint cursor everywhere (including interactive elements). */
a, button, input, textarea, select, label, [role="button"] {
    cursor: var(--bm-cursor);
}

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

a { color: var(--blue-700); text-decoration: none; }
a:hover { color: var(--blue-900); }

h1, h2, h3 { color: var(--ink); letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.2rem, 4.6vw, 3.8rem); font-weight: 800; line-height: 1.08; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); font-weight: 700; line-height: 1.15; }
h3 { font-size: 1.15rem; font-weight: 700; }

p { margin: 0 0 1em; color: var(--ink-soft); }
.muted { color: var(--ink-muted); }

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

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid transparent;
    padding: 10px 18px;
    border-radius: 999px;
    font: inherit;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: transform .12s ease, box-shadow .2s ease, background-color .2s ease, color .2s ease, border-color .2s ease;
    white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn-lg { padding: 14px 26px; font-size: 1rem; }
.btn-block { width: 100%; justify-content: center; }

.btn-primary {
    background: var(--blue-600);
    color: #fff;
    box-shadow: 0 6px 18px rgba(21, 101, 192, 0.35);
}
.btn-primary:hover {
    background: var(--blue-700);
    color: #fff;
    box-shadow: 0 10px 24px rgba(21, 101, 192, 0.45);
}

.btn-ghost {
    background: transparent;
    color: var(--blue-800);
    border-color: var(--blue-300);
}
.btn-ghost:hover {
    background: var(--blue-100);
    color: var(--blue-900);
    border-color: var(--blue-500);
}

/* ---------- Header / Nav ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: saturate(160%) blur(10px);
    -webkit-backdrop-filter: saturate(160%) blur(10px);
    border-bottom: 1px solid var(--border);
}
.nav-row {
    display: flex;
    align-items: center;
    gap: 24px;
    height: 72px;
}
.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}
.brand-mark { width: 26px; height: 32px; flex-shrink: 0; }
.brand-text { font-size: 1.45rem; }
.brand-bit { color: var(--blue-600); }
.brand-mapped { color: #546e7a; }

.site-nav {
    display: flex;
    align-items: center;
    gap: 28px;
    margin-left: auto;
}
.site-nav a {
    color: var(--ink-soft);
    font-weight: 500;
    font-size: 0.95rem;
}
.site-nav a:hover { color: var(--blue-700); }

.site-header .btn-primary { margin-left: 8px; }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    background: var(--sky-gradient);
    overflow: hidden;
    padding: 72px 0 56px;
}
.hero::before {
    content: "";
    position: absolute;
    inset: auto -10% -40% auto;
    width: 60%;
    aspect-ratio: 1;
    background: radial-gradient(circle at center, rgba(30, 136, 229, 0.18), transparent 65%);
    pointer-events: none;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 56px;
    align-items: center;
}
.eyebrow {
    display: inline-block;
    color: var(--blue-700);
    background: rgba(30, 136, 229, 0.1);
    border: 1px solid rgba(30, 136, 229, 0.25);
    padding: 6px 12px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 18px;
}
.hero h1 .accent { color: var(--blue-600); display: inline-block; }
.lede { font-size: 1.12rem; color: var(--ink-soft); max-width: 56ch; }

.cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 26px 0 20px;
}

.hero-bullets {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    color: var(--ink-soft);
    font-weight: 500;
}
.hero-bullets li { display: inline-flex; align-items: center; gap: 8px; }
.dot {
    width: 10px; height: 10px; border-radius: 50%;
    background: var(--blue-500);
    box-shadow: 0 0 0 4px rgba(30, 136, 229, 0.18);
}

.hero-art {
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-lg);
    transform: rotate(-1deg);
    transition: transform .4s ease;
}
.hero-art:hover { transform: rotate(0); }
.hero-art img { width: 100%; height: auto; display: block; }

/* ---------- Section basics ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 48px;
}
.section-head p { font-size: 1.08rem; }

/* ---------- Features ---------- */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 22px;
}
.feature-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px 26px;
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--blue-300);
}
.feature-icon {
    width: 46px; height: 46px;
    border-radius: 12px;
    background: var(--blue-100);
    color: var(--blue-700);
    display: grid; place-items: center;
    margin-bottom: 16px;
}
.feature-icon svg { width: 24px; height: 24px; }
.feature-card h3 { margin-bottom: 6px; }
.feature-card p { margin: 0; color: var(--ink-soft); }

/* ---------- How it works ---------- */
.steps {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 22px;
    counter-reset: step;
}
.steps li {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px 26px;
    position: relative;
    box-shadow: var(--shadow-sm);
}
.step-num {
    display: inline-grid;
    place-items: center;
    width: 38px; height: 38px;
    border-radius: 50%;
    background: var(--hero-gradient);
    color: #fff;
    font-weight: 800;
    margin-bottom: 14px;
    box-shadow: 0 6px 14px rgba(21, 101, 192, 0.35);
}
.steps h3 { margin-bottom: 6px; }
.steps p { margin: 0; }

/* ---------- Devices ---------- */
.devices-row {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 48px;
    align-items: center;
}
.devices-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: flex-start;
}
.badge {
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--blue-100);
    color: var(--blue-800);
    font-weight: 600;
    border: 1px solid var(--blue-300);
}

/* ---------- CTA band ---------- */
.cta-band { background: var(--hero-gradient); color: #fff; }
.cta-band h2, .cta-band p { color: #fff; }
.cta-band-inner { text-align: center; }
.cta-band-inner p { opacity: 0.9; margin-bottom: 24px; }
.cta-band .btn-primary {
    background: #fff;
    color: var(--blue-800);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}
.cta-band .btn-primary:hover { background: var(--blue-100); color: var(--blue-900); }

/* ---------- Footer banner image ---------- */
.footer-banner {
    width: 100%;
    background: #ffffff;
    display: flex;
    justify-content: center;
    padding: 0 24px;
    line-height: 0;
}
.footer-banner img {
    display: block;
    width: 100%;
    max-width: 720px;
    height: auto;
}

@media (max-width: 600px) {
    .footer-banner { padding: 0 12px; }
    .footer-banner img { max-width: 100%; }
}

/* ---------- Footer ---------- */
.site-footer {
    padding: 28px 0;
    border-top: 1px solid var(--border);
    background: var(--bg-alt);
}
.footer-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}
.footer-row .muted { margin: 0; font-size: 0.9rem; }

/* ---------- Modal (Login) ---------- */
.modal {
    position: fixed;
    inset: 0;
    z-index: 100;
    display: grid;
    place-items: center;
    padding: 20px;
}
.modal[hidden] { display: none; }
.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 30, 55, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: fade 0.2s ease;
}
.modal-panel {
    position: relative;
    width: 100%;
    max-width: 420px;
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 32px 30px 28px;
    box-shadow: var(--shadow-lg);
    animation: pop 0.22s cubic-bezier(.2,.9,.3,1.25);
}
.modal-close {
    position: absolute;
    top: 10px; right: 14px;
    width: 36px; height: 36px;
    border: none; background: transparent;
    font-size: 1.7rem; line-height: 1;
    color: var(--ink-muted);
    border-radius: 50%;
}
.modal-close:hover { background: var(--blue-100); color: var(--blue-800); }

.modal-head { text-align: center; margin-bottom: 22px; }
.modal-head .brand-mark { width: 34px; height: 42px; margin: 0 auto 8px; display: block; }
.modal-head h2 { margin-bottom: 4px; }
.modal-head p { margin: 0; color: var(--ink-muted); font-size: 0.95rem; }

.login-form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field > span {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--ink-soft);
}
.field input {
    -webkit-appearance: none;
    appearance: none;
    border: 1px solid var(--border);
    background: var(--blue-50);
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    font: inherit;
    color: var(--ink);
    width: 100%;
    transition: border-color .15s ease, box-shadow .15s ease, background-color .15s ease;
}
.field input:focus {
    outline: none;
    border-color: var(--blue-500);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(30, 136, 229, 0.18);
}
.field-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.9rem;
}
.remember { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-soft); }
.link { color: var(--blue-700); font-weight: 500; }
.login-message {
    min-height: 1.2em;
    font-size: 0.9rem;
    color: var(--ink-muted);
}
.login-message.error { color: #c62828; }
.login-message.success { color: #2e7d32; }
.fineprint {
    text-align: center;
    font-size: 0.8rem;
    color: var(--ink-muted);
    margin: 4px 0 0;
}

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop {
    from { opacity: 0; transform: translateY(10px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0)    scale(1); }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .hero { padding: 56px 0 40px; }
    .hero-grid { grid-template-columns: 1fr; gap: 36px; }
    .hero-art { order: -1; transform: none; }
    .devices-row { grid-template-columns: 1fr; }
    .site-nav { display: none; }
    .section { padding: 64px 0; }
    .footer-row { flex-direction: column; text-align: center; }
}

@media (max-width: 520px) {
    .nav-row { height: 64px; gap: 12px; }
    .cta-row { flex-direction: column; align-items: stretch; }
    .cta-row .btn { justify-content: center; }
}
