/* ==========================================================================
   Digitvilla Quotation Portal
   Mobile-first · no frameworks · CSS-driven motion
   ========================================================================== */

:root {
    --blue: #2563EB;
    --blue-600: #1D4ED8;
    --blue-50: #EFF4FF;
    --navy: #0F172A;
    --navy-800: #1E293B;
    --green: #10B981;
    --green-600: #059669;
    --green-50: #ECFDF5;
    --white: #FFFFFF;
    --bg: #F8FAFC;
    --ink: #0F172A;
    --ink-2: #334155;
    --muted: #64748B;
    --line: #E2E8F0;
    --line-2: #EEF2F7;

    --radius: 20px;
    --radius-sm: 12px;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, .05), 0 2px 8px rgba(15, 23, 42, .04);
    --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 12px 32px -12px rgba(15, 23, 42, .12);
    --shadow-lg: 0 2px 4px rgba(15, 23, 42, .04), 0 24px 48px -16px rgba(37, 99, 235, .25);
    --ease: cubic-bezier(.22, .61, .36, 1);
    --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --header-h: 64px;
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: calc(var(--header-h) + 16px);
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { letter-spacing: -0.025em; line-height: 1.15; }

:focus-visible {
    outline: 2px solid var(--blue);
    outline-offset: 3px;
    border-radius: 6px;
}

.container {
    width: 100%;
    max-width: 1240px;
    margin-inline: auto;
    padding-inline: 20px;
}

.icon { width: 1.15em; height: 1.15em; flex: none; }

.skip-link {
    position: absolute;
    left: 16px;
    top: -60px;
    z-index: 100;
    padding: 10px 16px;
    background: var(--navy);
    color: var(--white);
    border-radius: 10px;
    transition: top .2s;
}
.skip-link:focus { top: 12px; }

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55em;
    padding: .8em 1.35em;
    border: 1px solid transparent;
    border-radius: 12px;
    font: inherit;
    font-weight: 600;
    font-size: .95rem;
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
    transition: transform .25s var(--ease), box-shadow .25s var(--ease), background-color .25s, color .25s, border-color .25s;
}
.btn .icon { transition: transform .25s var(--ease); }
.btn:hover .icon { transform: translateX(3px); }
.btn:active { transform: translateY(0) scale(.98); }

.btn-sm { padding: .6em 1em; font-size: .875rem; border-radius: 10px; }
.btn-sm:hover .icon { transform: translate(2px, -2px); }
.btn-lg { padding: .95em 1.6em; font-size: 1rem; }

.btn-primary {
    background: var(--blue);
    color: var(--white);
    box-shadow: 0 1px 2px rgba(15, 23, 42, .08), 0 8px 20px -8px rgba(37, 99, 235, .6);
}
.btn-primary:hover {
    background: var(--blue-600);
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(15, 23, 42, .08), 0 14px 28px -10px rgba(37, 99, 235, .7);
}

.btn-ghost {
    background: rgba(255, 255, 255, .7);
    color: var(--ink);
    border-color: var(--line);
    backdrop-filter: blur(8px);
}
.btn-ghost:hover {
    border-color: #CBD5E1;
    background: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.btn-dark { background: var(--navy); color: var(--white); }
.btn-dark:hover { background: var(--navy-800); transform: translateY(-1px); }

.btn-light { background: var(--white); color: var(--navy); }
.btn-light:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px -12px rgba(0, 0, 0, .45);
}

/* ---------- Header ---------- */

.site-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 50;
    height: var(--header-h);
    border-bottom: 1px solid transparent;
    transition: background-color .3s, border-color .3s, box-shadow .3s, backdrop-filter .3s;
}
.site-header.is-scrolled,
.site-header.is-open {
    background: rgba(255, 255, 255, .78);
    border-bottom-color: rgba(226, 232, 240, .8);
    box-shadow: 0 4px 24px -12px rgba(15, 23, 42, .12);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    backdrop-filter: saturate(180%) blur(14px);
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand { display: flex; align-items: center; }
.brand-logo { width: auto; height: 22px; }

.nav-toggle {
    position: relative;
    width: 44px;
    height: 44px;
    margin-right: -8px;
    border: 0;
    background: transparent;
    border-radius: 10px;
    cursor: pointer;
}
.nav-toggle span {
    position: absolute;
    left: 12px;
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: var(--navy);
    transition: transform .3s var(--ease), opacity .2s;
}
.nav-toggle span:nth-child(1) { top: 15px; }
.nav-toggle span:nth-child(2) { top: 21px; }
.nav-toggle span:nth-child(3) { top: 27px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.site-nav {
    position: absolute;
    top: var(--header-h);
    left: 0;
    right: 0;
    padding: 12px 20px 20px;
    background: rgba(255, 255, 255, .97);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 20px 30px -20px rgba(15, 23, 42, .2);
    display: flex;
    flex-direction: column;
    gap: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity .25s, transform .25s var(--ease), visibility .25s;
}
.site-header.is-open .site-nav { opacity: 1; visibility: visible; transform: none; }
.no-js .site-nav { position: static; opacity: 1; visibility: visible; transform: none; }

.site-nav ul { display: flex; flex-direction: column; }
.site-nav ul a {
    display: block;
    padding: 12px 4px;
    font-weight: 500;
    color: var(--ink-2);
    border-bottom: 1px solid var(--line-2);
}
.site-nav .btn { align-self: flex-start; }

@media (min-width: 820px) {
    :root { --header-h: 72px; }
    .brand-logo { height: 26px; }
    .nav-toggle { display: none; }
    .site-nav {
        position: static;
        padding: 0;
        background: none;
        border: 0;
        box-shadow: none;
        flex-direction: row;
        align-items: center;
        gap: 28px;
        opacity: 1;
        visibility: visible;
        transform: none;
    }
    .site-nav ul { flex-direction: row; gap: 4px; }
    .site-nav ul a {
        position: relative;
        padding: 8px 14px;
        border: 0;
        font-size: .95rem;
        border-radius: 8px;
        transition: color .2s, background-color .2s;
    }
    .site-nav ul a:hover { color: var(--blue); background: rgba(37, 99, 235, .06); }
}

/* ---------- Hero ---------- */

.hero {
    position: relative;
    padding: calc(var(--header-h) + 64px) 0 72px;
    overflow: hidden;
    isolation: isolate;
    background: linear-gradient(180deg, #F3F7FF 0%, var(--bg) 100%);
}

.hero-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }

.hero-bg .grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(37, 99, 235, .07) 1px, transparent 1px),
        linear-gradient(90deg, rgba(37, 99, 235, .07) 1px, transparent 1px);
    background-size: 44px 44px;
    -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, #000 25%, transparent 75%);
    mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, #000 25%, transparent 75%);
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: .55;
    will-change: transform;
}
.blob-1 {
    width: 420px; height: 420px;
    top: -120px; left: -120px;
    background: radial-gradient(circle, rgba(37, 99, 235, .55), transparent 70%);
    animation: float-a 22s ease-in-out infinite;
}
.blob-2 {
    width: 380px; height: 380px;
    top: 10%; right: -140px;
    background: radial-gradient(circle, rgba(16, 185, 129, .45), transparent 70%);
    animation: float-b 26s ease-in-out infinite;
}
.blob-3 {
    width: 300px; height: 300px;
    bottom: -140px; left: 40%;
    background: radial-gradient(circle, rgba(99, 102, 241, .32), transparent 70%);
    animation: float-a 30s ease-in-out infinite reverse;
}

@keyframes float-a {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(60px, 40px) scale(1.08); }
}
@keyframes float-b {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-50px, 50px) scale(.94); }
}

.particles i {
    position: absolute;
    bottom: -10px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--blue);
    opacity: 0;
    box-shadow: 0 0 10px rgba(37, 99, 235, .6);
    animation: rise 18s linear infinite;
}
.particles i:nth-child(3n) { background: var(--green); box-shadow: 0 0 10px rgba(16, 185, 129, .6); }
.particles i:nth-child(4n) { width: 3px; height: 3px; }
.particles i:nth-child(1)  { left: 6%;  animation-delay: 0s;   animation-duration: 19s; }
.particles i:nth-child(2)  { left: 14%; animation-delay: -6s;  animation-duration: 23s; }
.particles i:nth-child(3)  { left: 22%; animation-delay: -12s; animation-duration: 17s; }
.particles i:nth-child(4)  { left: 30%; animation-delay: -3s;  animation-duration: 25s; }
.particles i:nth-child(5)  { left: 38%; animation-delay: -15s; animation-duration: 21s; }
.particles i:nth-child(6)  { left: 46%; animation-delay: -9s;  animation-duration: 18s; }
.particles i:nth-child(7)  { left: 54%; animation-delay: -1s;  animation-duration: 24s; }
.particles i:nth-child(8)  { left: 62%; animation-delay: -13s; animation-duration: 20s; }
.particles i:nth-child(9)  { left: 70%; animation-delay: -7s;  animation-duration: 22s; }
.particles i:nth-child(10) { left: 78%; animation-delay: -17s; animation-duration: 19s; }
.particles i:nth-child(11) { left: 86%; animation-delay: -4s;  animation-duration: 26s; }
.particles i:nth-child(12) { left: 93%; animation-delay: -11s; animation-duration: 18s; }
.particles i:nth-child(13) { left: 50%; animation-delay: -20s; animation-duration: 27s; }
.particles i:nth-child(14) { left: 10%; animation-delay: -22s; animation-duration: 24s; }

@keyframes rise {
    0%   { transform: translateY(0); opacity: 0; }
    10%  { opacity: .55; }
    80%  { opacity: .35; }
    100% { transform: translateY(-110vh); opacity: 0; }
}

.hero-content {
    position: relative;
    max-width: 860px;
    text-align: center;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px 6px 10px;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--green-600);
    background: rgba(255, 255, 255, .8);
    border: 1px solid rgba(16, 185, 129, .3);
    border-radius: 999px;
    box-shadow: var(--shadow-sm);
}

.pulse-dot {
    position: relative;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--green);
}
.pulse-dot::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--green);
    animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
    0% { transform: scale(1); opacity: .6; }
    100% { transform: scale(3); opacity: 0; }
}

.hero h1 {
    margin-top: 22px;
    font-size: clamp(2.25rem, 7vw, 4.25rem);
    font-weight: 800;
    letter-spacing: -0.035em;
    line-height: 1.05;
    color: var(--navy);
}

.text-gradient {
    display: inline-block;
    background: linear-gradient(100deg, var(--blue) 10%, #3B82F6 45%, var(--green) 95%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-lead {
    margin-top: 20px;
    font-size: clamp(1.1rem, 2.4vw, 1.3rem);
    font-weight: 500;
    color: var(--ink-2);
}
.hero-sub {
    max-width: 600px;
    margin: 10px auto 0;
    color: var(--muted);
}

.hero-actions {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
}

.hero-meta {
    margin-top: 32px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 22px;
    font-size: .875rem;
    color: var(--muted);
}
.hero-meta li { display: inline-flex; align-items: center; gap: 6px; }
.hero-meta .icon { color: var(--green); }

@media (min-width: 560px) {
    .hero-actions { flex-direction: row; justify-content: center; }
}
@media (min-width: 820px) {
    .hero { padding: calc(var(--header-h) + 96px) 0 112px; }
    .blob-1 { width: 560px; height: 560px; }
    .blob-2 { width: 480px; height: 480px; }
}

/* Entrance animations use fill-mode "backwards" so hover transforms stay free afterwards. */
@keyframes rise-in {
    from { opacity: 0; transform: translateY(var(--rise, 16px)); }
    to   { opacity: 1; transform: none; }
}
@keyframes pop-in {
    from { opacity: 0; transform: scale(.7); }
    to   { opacity: 1; transform: none; }
}

/* Load-in sequence (JS adds .is-loaded to <html>) */
.js:not(.is-loaded) .load-in { opacity: 0; }
.js.is-loaded .load-in { animation: rise-in .8s var(--ease) backwards; }
.js.is-loaded .load-in:nth-child(2) { animation-delay: .08s; }
.js.is-loaded .load-in:nth-child(3) { animation-delay: .16s; }
.js.is-loaded .load-in:nth-child(4) { animation-delay: .24s; }
.js.is-loaded .load-in:nth-child(5) { animation-delay: .32s; }
.js.is-loaded .load-in:nth-child(6) { animation-delay: .40s; }

/* ---------- Sections ---------- */

.section { padding: 72px 0; }
.section-tight { padding: 24px 0 48px; }
@media (min-width: 820px) {
    .section { padding: 104px 0; }
    .section-tight { padding: 32px 0 64px; }
}

.section-head {
    max-width: 640px;
    margin: 0 auto 44px;
    text-align: center;
}
.kicker {
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--blue);
}
.section-head h2 {
    margin-top: 10px;
    font-size: clamp(1.85rem, 4.5vw, 2.75rem);
    font-weight: 800;
    color: var(--navy);
}
.section-head p:last-child { margin-top: 12px; color: var(--muted); font-size: 1.05rem; }

.quotations { padding-top: 56px; }

/* Scroll reveal */
.js .reveal:not(.is-visible) { opacity: 0; }
.js .reveal.is-visible { --rise: 24px; animation: rise-in .7s var(--ease) backwards; }

/* ---------- Quotation cards ---------- */

.card-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}
@media (min-width: 640px) { .card-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; } }
@media (min-width: 1180px) { .card-grid { grid-template-columns: repeat(4, 1fr); } }

.js .card-grid .reveal:nth-child(2) { animation-delay: .1s; }
.js .card-grid .reveal:nth-child(3) { animation-delay: .2s; }
.js .card-grid .reveal:nth-child(4) { animation-delay: .3s; }

.q-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 28px 24px 22px;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    isolation: isolate;
    transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .45s;
}
.q-card::before {
    /* soft gradient glow revealed on hover */
    content: "";
    position: absolute;
    inset: -1px;
    z-index: -1;
    border-radius: inherit;
    background: radial-gradient(120% 80% at 0% 0%, rgba(37, 99, 235, .08), transparent 55%),
                radial-gradient(100% 70% at 100% 100%, rgba(16, 185, 129, .07), transparent 55%);
    opacity: 0;
    transition: opacity .45s var(--ease);
}
.q-card::after {
    /* thin top accent */
    content: "";
    position: absolute;
    top: -1px;
    left: 24px;
    right: 24px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, var(--blue), var(--green), transparent);
    opacity: 0;
    transition: opacity .45s var(--ease);
}

@media (hover: hover) {
    .q-card:hover {
        transform: translateY(-6px);
        border-color: rgba(37, 99, 235, .25);
        box-shadow: var(--shadow-lg);
    }
    .q-card:hover::before,
    .q-card:hover::after { opacity: 1; }
    .q-card:hover .q-icon {
        transform: scale(1.08) rotate(-3deg);
        background: var(--blue);
        color: var(--white);
        box-shadow: 0 10px 22px -8px rgba(37, 99, 235, .7);
    }
    .q-card:hover .btn-download:not(.is-disabled) {
        background: var(--blue);
        border-color: var(--blue);
        color: var(--white);
        box-shadow: 0 10px 22px -10px rgba(37, 99, 235, .8);
    }
}

.q-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 22px;
}

.q-icon {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 16px;
    color: var(--blue);
    background: var(--blue-50);
    border: 1px solid rgba(37, 99, 235, .12);
    transition: transform .45s var(--ease), background-color .35s, color .35s, box-shadow .35s;
}
.q-icon .icon { width: 26px; height: 26px; }
.js .q-card:not(.is-visible) .q-icon { opacity: 0; }
.js .q-card.is-visible .q-icon { animation: pop-in .6s cubic-bezier(.34, 1.56, .64, 1) .25s backwards; }
.js .card-grid .q-card:nth-child(2) .q-icon { animation-delay: .35s; }
.js .card-grid .q-card:nth-child(3) .q-icon { animation-delay: .45s; }
.js .card-grid .q-card:nth-child(4) .q-icon { animation-delay: .55s; }

.badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--green-600);
    background: var(--green-50);
    border: 1px solid rgba(16, 185, 129, .25);
    border-radius: 999px;
    white-space: nowrap;
}

.q-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--navy);
}
.q-text {
    margin-top: 10px;
    color: var(--muted);
    font-size: .95rem;
    line-height: 1.6;
}
.q-price {
    margin-top: 16px;
    font-size: .875rem;
    font-weight: 600;
    color: var(--ink-2);
}

.q-foot { margin-top: auto; padding-top: 24px; }

.btn-download {
    width: 100%;
    justify-content: space-between;
    padding: .9em 1.15em;
    background: var(--bg);
    color: var(--blue);
    border-color: var(--line);
}
.btn-download:focus-visible { background: var(--blue); color: var(--white); }
.btn-download.is-disabled {
    color: var(--muted);
    cursor: not-allowed;
    justify-content: center;
}

.q-status {
    min-height: 1.5em;
    margin-top: 10px;
    font-size: .825rem;
    font-weight: 500;
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 8px;
}
.q-status.is-done { color: var(--green-600); }
.q-status.is-error { color: #DC2626; }
.q-status .spinner {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(37, 99, 235, .2);
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: spin .8s linear infinite;
}
.q-status .icon { width: 16px; height: 16px; }
@keyframes spin { to { transform: rotate(360deg); } }

.q-status span { animation: fade-in .3s var(--ease); }
@keyframes fade-in { from { opacity: 0; transform: translateY(3px); } to { opacity: 1; transform: none; } }

.btn-download.is-busy { pointer-events: none; }
.btn-download.is-busy .icon { animation: nudge 1s var(--ease) infinite; }
@keyframes nudge { 50% { transform: translateX(4px); } }

/* ---------- Custom CTA ---------- */

.cta-panel {
    position: relative;
    display: grid;
    gap: 32px;
    padding: 40px 24px;
    color: #CBD5E1;
    background: var(--navy);
    border-radius: 24px;
    overflow: hidden;
    isolation: isolate;
}
.cta-glow {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(60% 90% at 100% 0%, rgba(37, 99, 235, .35), transparent 60%),
        radial-gradient(50% 80% at 0% 100%, rgba(16, 185, 129, .22), transparent 60%);
}
.cta-panel::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image: radial-gradient(rgba(255, 255, 255, .08) 1px, transparent 1px);
    background-size: 22px 22px;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 60%);
    mask-image: linear-gradient(90deg, transparent, #000 60%);
}
.cta-copy h2 {
    font-size: clamp(1.75rem, 4vw, 2.4rem);
    font-weight: 800;
    color: var(--white);
}
.cta-copy p { margin: 14px 0 28px; max-width: 520px; font-size: 1.05rem; line-height: 1.65; }

.trust-list { display: grid; gap: 12px; align-content: center; }
.trust-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    color: var(--white);
    font-weight: 500;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 14px;
    transition: background-color .3s, border-color .3s, transform .3s var(--ease);
}
.trust-list li:hover { background: rgba(255, 255, 255, .07); border-color: rgba(16, 185, 129, .35); transform: translateX(3px); }
.trust-list span {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    color: var(--green);
    background: rgba(16, 185, 129, .15);
}
.trust-list .icon { width: 16px; height: 16px; stroke-width: 2.4; }

@media (min-width: 900px) {
    .cta-panel { grid-template-columns: 1.2fr 1fr; gap: 56px; padding: 64px; }
    .trust-list { grid-template-columns: 1fr 1fr; }
}

/* ---------- QR / Expo ---------- */

.qr-panel {
    display: grid;
    gap: 32px;
    align-items: center;
    justify-items: center;
    padding: 40px 24px;
    text-align: center;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
}
.qr-copy h2 {
    margin-top: 10px;
    font-size: clamp(1.75rem, 4vw, 2.4rem);
    font-weight: 800;
    color: var(--navy);
}
.qr-copy p { margin-top: 12px; color: var(--muted); font-size: 1.05rem; max-width: 460px; }
.qr-link {
    display: inline-block;
    margin-top: 18px;
    font-weight: 600;
    color: var(--blue);
    border-bottom: 1px solid rgba(37, 99, 235, .3);
    transition: border-color .2s;
}
.qr-link:hover { border-color: var(--blue); }

.qr-frame {
    position: relative;
    display: grid;
    place-items: center;
    width: 220px;
    height: 220px;
    padding: 16px;
    border-radius: 20px;
    background: var(--bg);
    overflow: hidden;
    transition: transform .4s var(--ease);
}
.qr-frame:hover { transform: scale(1.02); }
.qr-frame img { width: 100%; height: 100%; object-fit: contain; border-radius: 8px; background: var(--white); }

.qr-placeholder {
    display: grid;
    place-items: center;
    gap: 8px;
    color: #94A3B8;
}
.qr-placeholder .icon { width: 96px; height: 96px; stroke-width: 1.2; color: #CBD5E1; }
.qr-placeholder small { font-size: .75rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }

.qr-corner {
    position: absolute;
    width: 28px;
    height: 28px;
    border: 3px solid var(--blue);
    animation: corner 3s ease-in-out infinite;
}
.qr-corner.tl { top: 8px; left: 8px; border-right: 0; border-bottom: 0; border-top-left-radius: 12px; }
.qr-corner.tr { top: 8px; right: 8px; border-left: 0; border-bottom: 0; border-top-right-radius: 12px; }
.qr-corner.bl { bottom: 8px; left: 8px; border-right: 0; border-top: 0; border-bottom-left-radius: 12px; }
.qr-corner.br { bottom: 8px; right: 8px; border-left: 0; border-top: 0; border-bottom-right-radius: 12px; }
@keyframes corner { 50% { border-color: var(--green); } }

.qr-scan {
    position: absolute;
    left: 14px;
    right: 14px;
    top: 14px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, var(--green), transparent);
    box-shadow: 0 0 12px rgba(16, 185, 129, .7);
    animation: scan 3.2s ease-in-out infinite;
}
@keyframes scan {
    0%, 100% { transform: translateY(0); opacity: 0; }
    10%, 90% { opacity: 1; }
    50% { transform: translateY(190px); }
}

@media (min-width: 820px) {
    .qr-panel {
        grid-template-columns: 1fr auto;
        justify-items: start;
        text-align: left;
        padding: 56px 64px;
        gap: 48px;
    }
}

/* ---------- Footer ---------- */

.site-footer {
    margin-top: 32px;
    padding: 64px 0 28px;
    color: #94A3B8;
    background: var(--navy);
}
.footer-grid { display: grid; gap: 36px; }
.footer-logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: .08em;
    color: var(--white);
}
.footer-tag { margin-top: 8px; }
.footer-h {
    margin-bottom: 14px;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #CBD5E1;
}
.footer-links { display: grid; gap: 10px; }
.footer-links a, .footer-contact a, .footer-bottom a { transition: color .2s; }
.footer-links a:hover, .footer-contact a:hover, .footer-bottom a:hover { color: var(--white); }
.footer-contact { display: grid; gap: 12px; }
.footer-contact li { display: flex; align-items: center; gap: 10px; }
.footer-contact .icon { color: var(--green); }

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px 24px;
    margin-top: 48px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, .08);
    font-size: .875rem;
}

@media (min-width: 720px) {
    .footer-grid { grid-template-columns: 1.6fr 1fr 1.2fr; gap: 48px; }
}

/* ---------- Error page (download.php) ---------- */

.error-page {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
    background: radial-gradient(60% 50% at 50% 0%, rgba(37, 99, 235, .1), transparent), var(--bg);
}
.error-card {
    max-width: 480px;
    padding: 40px 32px;
    text-align: center;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
}
.error-card .error-logo { width: 190px; height: auto; margin: 0 auto 28px; }
.error-card h1 { font-size: 1.5rem; color: var(--navy); }
.error-card p { margin: 14px 0 28px; color: var(--muted); }
.error-card p a { color: var(--blue); font-weight: 600; }

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        transition-delay: 0s !important;
    }
    .blob, .particles, .qr-scan, .pulse-dot::after { display: none; }
    .js .load-in, .js .reveal, .js .q-card .q-icon { opacity: 1 !important; animation: none !important; }
}
