/**
 * Copyright (C) 2026 PatrikMol Solutions Kft. All rights reserved.
 *
 * Shared styles for public-facing pages (login, password reset) and
 * anything not specific to the authenticated admin shell (see admin.css).
 * Layered on top of the CDN-hosted Bootstrap 5.3.8 + Bootstrap Icons 1.13.1
 * CSS (see partials/vendor_head.php).
 */

:root {
    --tfl-bg: #f4f5f7;
    --tfl-surface: #ffffff;
    --tfl-border: #dee2e6;
    --tfl-text-muted: #6c757d;
}

body {
    background-color: var(--tfl-bg);
    min-height: 100vh;
}

/* ---------------------------------------------------------------------- */
/* Auth pages (login, password reset/set, message)                         */
/* ---------------------------------------------------------------------- */

.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1.5rem;
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--tfl-surface);
    border: 1px solid var(--tfl-border);
    border-radius: 0.5rem;
    padding: 2rem;
    box-shadow: 0 0.5rem 1.5rem rgba(0, 0, 0, 0.06);
}

.auth-card__title {
    text-align: center;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.auth-card__footer {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.9rem;
}

.auth-card__error {
    display: none;
}

.auth-card__error.is-visible {
    display: block;
}

/* ---------------------------------------------------------------------- */
/* Generic error pages (404/403 — rendered with layout 'none')             */
/* ---------------------------------------------------------------------- */

.error-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.error-page__content {
    text-align: center;
}

.error-page__content h1 {
    font-size: 4rem;
    font-weight: 700;
    color: var(--tfl-text-muted);
    margin-bottom: 0.5rem;
}

/* ---------------------------------------------------------------------- */
/* Toast stacking — Bootstrap's own .toast-container declares             */
/* --bs-toast-zindex:1090 on the element itself, so a :root override      */
/* would lose to that same-specificity, later-declared rule. Overriding   */
/* it here, on the element, keeps every TFL.toast() above the app's other */
/* fixed-position UI (e.g. lib/BackupRestore's .br-toast-container).      */
/* ---------------------------------------------------------------------- */

.toast-container { --bs-toast-zindex: 99999; }

/* ---------------------------------------------------------------------- */
/* ZIP -> city/county autocomplete dropdown, injected by                  */
/* public/js/zip-autocomplete.js next to any [data-zip-autocomplete] ZIP  */
/* input — the input's immediate parent (a .position-relative wrapper)    */
/* becomes the positioning anchor. See that file for the wiring           */
/* convention.                                                             */
/* ---------------------------------------------------------------------- */

.zip-autocomplete-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000;
    max-height: 220px;
    overflow-y: auto;
    background: #fff;
    border: 1px solid var(--tfl-border, #dee2e6);
    border-radius: 0.375rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}
.zip-autocomplete-item { padding: .4rem .75rem; cursor: pointer; font-size: .9rem; }
.zip-autocomplete-item:hover { background: #f1f3f5; }
.zip-autocomplete-item strong { font-weight: 600; }
