/* =============================================
   CUSTOM PROPERTIES
   ============================================= */
:root {
    --primary: #0f172a;
    --accent: #22c55e;
    --accent-dark: #16a34a;
    /* Button fills: white text needs >= 4.5:1 (WCAG AA).
       #15803d = 5.0:1, #166534 = 7.1:1 (vs 2.3:1 for --accent). */
    --accent-button: #15803d;
    --accent-button-hover: #166534;
    --gold: #f59e0b;
    --light: #f8fafc;
    --white: #ffffff;
    --muted: #64748b;
    --border: #e2e8f0;
    --shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    --radius: 18px;
}

/* =============================================
   RESET & BASE
   ============================================= */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    /* keep anchor targets clear of the sticky 80px header */
    scroll-padding-top: 80px;
}

body {
    font-family: Arial, Helvetica, sans-serif;
    background: var(--light);
    color: var(--primary);
    line-height: 1.6;
}

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

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* =============================================
   LAYOUT
   ============================================= */
.section {
    padding: 90px 0;
}

/* =============================================
   TYPOGRAPHY HELPERS
   ============================================= */
.section-title {
    font-size: clamp(2rem, 4vw, 2.8rem);
    margin-bottom: 14px;
    text-align: center;
}

/* Left-aligned variant (replaces inline style="text-align:left") */
.section-title--left {
    text-align: left;
    margin-bottom: 18px;
}

.section-subtitle {
    max-width: 700px;
    margin: 0 auto 50px;
    text-align: center;
    color: var(--muted);
    font-size: 1.05rem;
}

/* Box headings (replaces inline style="margin-bottom:14px") */
.box-heading {
    margin-bottom: 14px;
}

/* Muted subtitle inside location box (replaces inline color:var(--muted)) */
.box-subtitle {
    color: var(--muted);
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 24px;
    border-radius: 999px;
    font-weight: 700;
    border: 2px solid transparent;
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease,
        box-shadow 0.3s ease, transform 0.3s ease;
    cursor: pointer;
}

/* Bootstrap's .btn state rules (:hover/:active/:focus-visible) read these
   variables; pin them to the brand colours so Bootstrap's blue/grey never shows. */
.btn-primary {
    --bs-btn-color: var(--white);
    --bs-btn-hover-color: var(--white);
    --bs-btn-hover-bg: var(--accent-button-hover);
    --bs-btn-hover-border-color: transparent;
    --bs-btn-active-color: var(--white);
    --bs-btn-active-bg: var(--accent-button-hover);
    --bs-btn-active-border-color: transparent;
    --bs-btn-focus-shadow-rgb: 34, 197, 94;
    background: var(--accent-button);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--accent-button-hover);
    transform: translateY(-2px);
}

.btn-secondary {
    --bs-btn-color: var(--white);
    --bs-btn-hover-color: var(--white);
    --bs-btn-hover-bg: rgba(255, 255, 255, 0.12);
    --bs-btn-hover-border-color: rgba(255, 255, 255, 0.35);
    --bs-btn-active-color: var(--white);
    --bs-btn-active-bg: rgba(255, 255, 255, 0.12);
    --bs-btn-active-border-color: rgba(255, 255, 255, 0.35);
    --bs-btn-focus-shadow-rgb: 255, 255, 255;
    background: transparent;
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.35);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
}

/* =============================================
   HEADER / NAV
   ============================================= */
header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-wrapper {
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    color: var(--white);
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.logo span {
    color: var(--gold);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 600;
    margin: 0;
    padding: 0;
}

.nav-links a:hover {
    color: var(--gold);
}

.menu-toggle {
    display: none;
    background: transparent;
    border: 0;
    cursor: pointer;
    width: 44px;
    height: 44px;
    position: relative;
}

.menu-toggle span,
.menu-toggle::before,
.menu-toggle::after {
    content: "";
    position: absolute;
    left: 10px;
    width: 24px;
    height: 2px;
    background: var(--white);
    transition: 0.3s ease;
}

.menu-toggle span {
    top: 21px;
}

.menu-toggle::before {
    top: 14px;
}

.menu-toggle::after {
    top: 28px;
}

/* =============================================
   HERO
   ============================================= */
/* Hero photo (Unsplash, self-hosted in images/hero/): 800px for phones,
   1600px from 769px up. AVIF where supported, WebP otherwise.
   The gradient is repeated literally (no var()) so browsers without
   image-set() keep the plain WebP declaration as a fallback. */
.hero {
    background-color: var(--primary);
    background-image: linear-gradient(rgba(15, 23, 42, 0.82), rgba(15, 23, 42, 0.9)), url('../images/hero/hero-800.webp');
    background-image: linear-gradient(rgba(15, 23, 42, 0.82), rgba(15, 23, 42, 0.9)), image-set(url('../images/hero/hero-800.avif') type('image/avif'),
            url('../images/hero/hero-800.webp') type('image/webp'));
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: var(--white);
    padding: 110px 0 90px;
}

@media (min-width: 769px) {
    .hero {
        background-image: linear-gradient(rgba(15, 23, 42, 0.82), rgba(15, 23, 42, 0.9)), url('../images/hero/hero-1600.webp');
        background-image: linear-gradient(rgba(15, 23, 42, 0.82), rgba(15, 23, 42, 0.9)), image-set(url('../images/hero/hero-1600.avif') type('image/avif'),
                url('../images/hero/hero-1600.webp') type('image/webp'));
    }
}

.hero-badge {
    display: inline-block;
    margin-bottom: 16px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.16);
    color: #fde68a;
    font-size: 0.95rem;
    font-weight: 700;
}

.hero h1 {
    font-size: clamp(2.4rem, 6vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 18px;
}

.hero p {
    font-size: 1.08rem;
    max-width: 620px;
    color: rgba(255, 255, 255, 0.88);
    margin-bottom: 28px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 28px;
}

.feature-pill {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 14px;
    text-align: center;
    font-size: 0.95rem;
}

.hero-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 24px;
    padding: 28px;
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
}

.hero-card h2,
.hero-card h3 {
    margin-bottom: 16px;
    font-size: 1.35rem;
}

.quick-info {
    display: grid;
    gap: 16px;
}

.quick-info-item {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 16px;
}

.quick-info-item small {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 6px;
}

/* =============================================
   KURSNA LISTA
   ============================================= */
.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.rates-table {
    width: 100%;
    border-collapse: collapse;
}

.rates-table thead {
    background: var(--primary);
    color: var(--white);
}

.rates-table th,
.rates-table td {
    padding: 18px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.rates-table tbody tr:hover {
    background: var(--light);
}

.rate-note {
    padding: 18px;
    color: var(--muted);
    font-size: 0.95rem;
}

.highlight-box {
    padding: 28px;
}

.highlight-box h3 {
    margin-bottom: 16px;
    font-size: 1.5rem;
}

.highlight-list {
    display: grid;
    gap: 14px;
    margin-top: 18px;
}

.highlight-list li {
    padding: 14px 16px;
    border-radius: 14px;
    background: var(--light);
    border: 1px solid var(--border);
    font-weight: 600;
}

/* =============================================
   O NAMA
   ============================================= */
.about-content p {
    color: var(--muted);
    margin-bottom: 16px;
}

.stat-box {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
    text-align: center;
    box-shadow: var(--shadow);
}

.stat-box strong {
    display: block;
    font-size: 1.8rem;
    margin-bottom: 6px;
}

/* =============================================
   PARTNERI
   ============================================= */
.partners-section {
    background: var(--white);
}

.partner-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 30px;
    min-height: 140px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.3s;
    box-shadow: var(--shadow);
}

.partner-card:hover {
    transform: translateY(-5px);
}

.partner-card img {
    /* min() keeps logos inside the card on narrow screens */
    max-width: min(180px, 100%);
    max-height: 80px;
    object-fit: contain;
}

/* =============================================
   USLUGE
   ============================================= */
.service-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease;
    cursor: pointer;
    height: 100%;
}

.service-card:hover {
    transform: translateY(-6px);
}

.service-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: rgba(34, 197, 94, 0.12);
    color: var(--accent-dark);
    font-size: 1.4rem;
    font-weight: 900;
    margin-bottom: 16px;
}

.service-card h3 {
    margin-bottom: 10px;
}

.service-card p {
    color: var(--muted);
}

/* =============================================
   LOKACIJA & KONTAKT
   ============================================= */
.location-box,
.contact-card,
.form-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    height: 100%;
}

.contact-card p {
    color: var(--muted);
    margin-bottom: 16px;
}

.location-list,
.contact-list {
    display: grid;
    gap: 14px;
    margin-top: 18px;
}

.location-list li,
.contact-list li {
    padding: 14px 16px;
    background: var(--light);
    border-radius: 14px;
    border: 1px solid var(--border);
}

.map-placeholder {
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.map-placeholder iframe {
    display: block;
    width: 100%;
    border: 0;
}

/* Click-to-load map: same 450px box the iframe uses */
.map-consent {
    height: 450px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
    background-color: #eef2f7;
    /* faint street-grid pattern */
    background-image:
        linear-gradient(rgba(15, 23, 42, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.05) 1px, transparent 1px),
        linear-gradient(35deg, transparent 47%, rgba(255, 255, 255, 0.9) 47%, rgba(255, 255, 255, 0.9) 53%, transparent 53%),
        linear-gradient(-55deg, transparent 48%, rgba(255, 255, 255, 0.9) 48%, rgba(255, 255, 255, 0.9) 52%, transparent 52%);
    background-size: 32px 32px, 32px 32px, 100% 100%, 100% 100%;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.map-consent-inner {
    max-width: 360px;
    padding: 24px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.map-consent-pin {
    font-size: 2rem;
    line-height: 1;
    margin-bottom: 8px;
}

.map-consent-address {
    margin-bottom: 16px;
}

.map-consent-btn {
    width: 100%;
}

.map-consent-note {
    margin: 14px 0 8px;
    color: var(--muted);
    font-size: 0.85rem;
}

.map-consent-note a,
.map-consent-link {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.map-consent-link {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent-button);
}

.map-consent-note a:hover,
.map-consent-link:hover {
    color: var(--accent-button-hover);
}

/* =============================================
   FORM
   ============================================= */
form {
    display: grid;
    gap: 14px;
}

input,
textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 14px;
    outline: none;
    font: inherit;
    background: var(--white);
}

input:focus,
textarea:focus {
    border-color: var(--accent);
}

textarea {
    min-height: 140px;
    resize: vertical;
}

/* =============================================
   FOOTER
   ============================================= */
footer {
    background: var(--primary);
    color: rgba(255, 255, 255, 0.9);
    padding: 26px 0;
    margin-top: 30px;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
}

.footer-content span {
    color: var(--gold);
}

.footer-content p {
    color: rgba(255, 255, 255, 0.75);
    margin: 0;
}

/* Company registration details: own full-width row under the footer line */
.footer-content .footer-legal {
    flex-basis: 100%;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.85rem;
}

/* =============================================
   MODAL
   ============================================= */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    max-width: 500px;
    width: 100%;
    padding: 30px;
    border-radius: var(--radius);
    position: relative;
}

.close-modal {
    position: absolute;
    right: 15px;
    top: 15px;
    border: none;
    background: none;
    font-size: 28px;
    cursor: pointer;
}

/* =============================================
   REFRESH INDICATOR
   ============================================= */
.refresh-container {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    font-weight: 700;
    flex-wrap: wrap;
    gap: 8px;
}

.refreshing {
    animation: pulse 1s ease;
}

@keyframes pulse {
    0%   { opacity: 1; }
    50%  { opacity: 0.3; }
    100% { opacity: 1; }
}

/* =============================================
   PRIVACY PAGE & PRIVACY LINKS
   ============================================= */
.privacy-content {
    max-width: 820px;
    margin: 0 auto;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(24px, 5vw, 48px);
    box-shadow: var(--shadow);
}

.privacy-content .section-title,
.privacy-content .section-title--left {
    margin-bottom: 6px;
    text-align: left;
}

.privacy-updated {
    color: var(--muted);
    font-size: 0.95rem;
    margin-bottom: 24px;
}

.privacy-content h2 {
    font-size: 1.35rem;
    margin: 32px 0 12px;
}

.privacy-content p {
    color: #334155;
}

.privacy-content .location-list {
    margin: 0 0 16px;
}

.privacy-content a:not(.btn),
.form-note a,
.footer-content a {
    text-decoration: underline;
    text-underline-offset: 2px;
}

.privacy-content a:not(.btn):hover,
.form-note a:hover {
    color: var(--accent-button);
}

.footer-content a:hover {
    color: var(--gold);
}

.privacy-back {
    margin: 32px 0 0;
}

.form-note {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
}

/* =============================================
   ADMIN PAGE (kursna lista editor)
   ============================================= */
.admin-back {
    color: rgba(255, 255, 255, 0.92);
    font-weight: 600;
    white-space: nowrap;
}

.admin-page .nav-wrapper {
    gap: 12px;
}

.admin-page .logo {
    white-space: nowrap;
}

@media (max-width: 420px) {
    .admin-page .logo {
        font-size: 1.1rem;
    }

    .admin-back {
        font-size: 0.9rem;
    }
}

.admin-back:hover {
    color: var(--gold);
}

.admin-main {
    min-height: calc(100vh - 81px);
}

.admin-card {
    max-width: 960px;
    margin: 0 auto;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: clamp(20px, 4vw, 40px);
    box-shadow: var(--shadow);
}

.admin-title {
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    margin-bottom: 8px;
}

.admin-lead {
    color: var(--muted);
    margin-bottom: 24px;
}

.admin-lead strong {
    color: var(--primary);
}

.admin-login {
    max-width: 420px;
}

.admin-label {
    font-weight: 700;
    margin-bottom: -6px;
}

.admin-check {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.admin-check input {
    width: 20px;
    height: 20px;
    padding: 0;
    accent-color: var(--accent-button);
}

.admin-head,
.admin-row {
    display: grid;
    grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr) 44px;
    gap: 10px;
    align-items: center;
}

.admin-head {
    padding: 0 2px;
    color: var(--muted);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.admin-rows {
    display: grid;
    gap: 10px;
}

.admin-field {
    margin: 0;
}

.admin-field input {
    padding: 10px 12px;
    border-radius: 12px;
}

.admin-field-label {
    /* labels are announced by screen readers; the column header shows them visually */
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
}

.admin-field input.is-invalid {
    border-color: #dc2626;
    background: #fef2f2;
}

.admin-remove {
    width: 44px;
    height: 44px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--white);
    color: var(--muted);
    font-size: 1rem;
    cursor: pointer;
}

.admin-remove:hover,
.admin-remove:focus-visible {
    color: #dc2626;
    border-color: #fecaca;
    background: #fef2f2;
}

.admin-btn-outline {
    justify-self: start;
    background: var(--white);
    color: var(--primary);
    border: 2px solid var(--border);
}

.admin-btn-outline:hover {
    border-color: var(--accent);
}

.admin-save {
    justify-self: start;
    min-width: 260px;
}

.admin-save:disabled {
    opacity: 0.7;
    cursor: wait;
}

.admin-status {
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid transparent;
    font-weight: 600;
}

.admin-status.is-info {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1e3a8a;
}

.admin-status.is-success {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #166534;
}

.admin-status.is-error {
    background: #fef2f2;
    border-color: #fecaca;
    color: #991b1b;
}

.admin-status a {
    text-decoration: underline;
}

#globalStatus {
    margin-top: 18px;
}

.admin-hint {
    margin: 18px 0 8px;
    color: var(--muted);
    font-size: 0.9rem;
}

.admin-logout {
    padding: 0;
    border: 0;
    background: none;
    color: var(--muted);
    font-size: 0.9rem;
    text-decoration: underline;
    cursor: pointer;
}

.admin-logout:hover {
    color: #dc2626;
}

/* Phones: one small card per currency, rates side by side */
@media (max-width: 640px) {
    .admin-head {
        display: none;
    }

    .admin-rows {
        gap: 16px;
    }

    .admin-row {
        position: relative;
        grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr) minmax(0, 1fr);
        gap: 10px;
        padding: 14px;
        background: var(--light);
        border: 1px solid var(--border);
        border-radius: 14px;
    }

    .admin-field-label {
        position: static;
        width: auto;
        height: auto;
        overflow: visible;
        clip: auto;
        display: block;
        margin-bottom: 4px;
        color: var(--muted);
        font-size: 0.8rem;
        font-weight: 700;
    }

    .admin-field--name {
        grid-column: 1 / -1;
        padding-right: 44px;
    }

    .admin-remove {
        position: absolute;
        top: 10px;
        right: 10px;
        width: 36px;
        height: 36px;
    }

    .admin-save {
        min-width: 0;
    }
}

/* =============================================
   404 PAGE
   ============================================= */
.error-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.error-page footer {
    margin-top: 0;
}

.error-hero {
    flex: 1;
    display: flex;
    align-items: center;
    padding: 80px 0;
}

.error-content {
    max-width: 640px;
    margin: 0 auto;
    text-align: center;
}

.hero .error-code {
    font-size: clamp(6rem, 22vw, 11rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: 4px;
    margin: 0 auto 8px;
    color: var(--white);
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.error-code span {
    color: var(--gold);
}

.hero .error-content h1 {
    font-size: clamp(1.9rem, 5vw, 2.8rem);
}

.hero .error-text {
    margin: 0 auto 28px;
}

.error-actions {
    justify-content: center;
}

.error-card {
    margin-top: 12px;
    text-align: left;
}

.hero-card.error-card h2 {
    font-size: 1.1rem;
    margin-bottom: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.error-links {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.error-links .feature-pill {
    display: block;
    font-weight: 600;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.error-links .feature-pill:hover,
.error-links .feature-pill:focus-visible {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(245, 158, 11, 0.6);
}

.hero .error-phone {
    margin: 18px 0 0;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.7);
}

.error-phone a {
    color: var(--gold);
    font-weight: 700;
}

@media (max-width: 480px) {
    .error-links {
        grid-template-columns: 1fr;
    }
}

/* =============================================
   ACCESSIBILITY
   ============================================= */
.skip-link:focus {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 10000;
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--accent-button);
    color: var(--white);
    font-weight: 700;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *, *::before, *::after {
        animation: none !important;
        transition: none !important;
    }

    .btn-primary:hover,
    .partner-card:hover,
    .service-card:hover {
        transform: none;
    }
}

/* =============================================
   MOBILE NAV (custom toggle, not Bootstrap navbar)
   ============================================= */
/* Logo + six links need ~772px; below Bootstrap's lg container (960px)
   they wrap, so the toggle menu is used up to 991.98px. */
@media (max-width: 991.98px) {
    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 80px;
        left: 0;
        right: 0;
        background: var(--primary);
        flex-direction: column;
        align-items: flex-start;
        padding: 20px 16px 28px;
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        display: none;
    }

    .nav-links.active {
        display: flex;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 70px 0;
    }

    .hero {
        padding: 85px 0 70px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .btn {
        width: 100%;
    }

    /* Responsive table on mobile */
    .rates-table thead {
        display: none;
    }

    .rates-table,
    .rates-table tbody,
    .rates-table tr,
    .rates-table td {
        display: block;
        width: 100%;
    }

    .rates-table tr {
        padding: 10px 0;
        border-bottom: 1px solid var(--border);
    }

    .rates-table td {
        padding: 10px 18px;
        border-bottom: none;
    }

    .rates-table td::before {
        content: attr(data-label);
        display: block;
        font-size: 0.85rem;
        color: var(--muted);
        margin-bottom: 4px;
        font-weight: 700;
    }

    .footer-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .section-title--left {
        text-align: center;
    }
}

/* Three stat boxes side by side are ~86px wide at 320px: tighten the
   side padding and scale the text so "1000+" and "najtraženije" fit. */
@media (max-width: 400px) {
    .stat-box {
        padding: 20px 8px;
    }

    .stat-box strong {
        font-size: clamp(1.25rem, 7vw, 1.8rem);
    }

    .stat-box span {
        font-size: clamp(0.8125rem, 4vw, 1rem);
    }
}
