:root {
    /* Defaults. theme.css.php overrides these per tenant when it is
       linked after this file; anything it doesn't set falls back here. */
    --accent: #5b6cff;
    --accent-2: #a86bff;
    --accent-hover: #4a58e0;
    --accent-shadow: rgba(91, 108, 255, 0.12);
    --page-bg-from: #f4f5f7;
    --page-bg-to: #e8eaf0;

    /* Brand block: hidden unless a tenant theme supplies these. */
    --brand-shown: none;
    --brand-logo: none;
    --brand-name: "";
}

* { box-sizing: border-box; }

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, var(--page-bg-from) 0%, var(--page-bg-to) 100%);
    min-height: 100vh;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
    padding: 40px;
    width: 100%;
    max-width: 380px;
}

.card h2 {
    margin: 0 0 24px;
    font-size: 22px;
    font-weight: 600;
    color: #1a1a1a;
}

/* --- Shared brand block ---------------------------------------------
   Driven entirely by CSS variables, so the markup is identical on every
   page and every tenant. Pages just include:

       <div class="brand-logo"><div class="brand-mark"></div>
       <div class="brand-name"></div></div>

   With no tenant theme loaded, --brand-shown is none and it disappears.
   -------------------------------------------------------------------- */
.brand-logo {
    display: var(--brand-shown);
    text-align: center;
    margin-bottom: 22px;
}

.brand-logo .brand-mark {
    height: 60px;
    max-width: 220px;
    margin: 0 auto 8px;
    background-image: var(--brand-logo);
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

.brand-logo .brand-name::after {
    content: var(--brand-name);
    font-size: 18px;
    font-weight: 700;
    background: linear-gradient(90deg, var(--accent) 0%, var(--accent-2) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.field {
    margin-bottom: 18px;
}

.field label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: #444;
    margin-bottom: 6px;
}

.field input {
    width: 100%;
    padding: 11px 14px;
    border: 1px solid #dcdfe4;
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.15s, box-shadow 0.15s;
}

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

button {
    width: 100%;
    padding: 12px;
    /* Gradient across the tenant's two accent colours, matching the
       buttons on the product landing pages. A tenant with no accent_2
       configured falls back to the :root default above, so this still
       renders as a solid-looking button rather than breaking. */
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: filter 0.15s;
}

button:hover {
    /* Darkening the whole gradient keeps both stops in step - swapping
       to a flat --accent-hover here would drop the gradient on hover. */
    filter: brightness(0.92);
}

.result {
    margin-top: 16px;
    font-size: 14px;
    color: #444;
    text-align: center;
}

.links {
    margin-top: 20px;
    text-align: center;
    font-size: 13px;
}

.links a {
    color: var(--accent);
    text-decoration: none;
}

.links a:hover {
    text-decoration: underline;
}

@media (max-width: 480px) {
    body {
        padding: 12px;
        align-items: flex-start;
        padding-top: 40px;
    }

    .card {
        padding: 24px 20px;
        border-radius: 12px;
        max-width: 100%;
    }

    .card h2 {
        font-size: 19px;
        margin-bottom: 18px;
    }

    .field input {
        font-size: 16px; /* prevents iOS Safari from auto-zooming on focus */
    }

    button {
        font-size: 16px;
        padding: 13px;
    }
}
