:root {
    --blue-900: #062b61;
    --blue-800: #073b7a;
    --blue-600: #1767d2;
    --orange: #ff7a00;
    --orange-soft: #fff1df;
    --sky: #eaf5ff;
    --mint: #e5f7ed;
    --paper: #ffffff;
    --ink: #101828;
    --muted: #667085;
    --line: #d8e0ec;
    --shadow: 0 18px 60px rgba(6, 43, 97, 0.14);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: #f7fbff;
}

body {
    min-height: 100%;
    margin: 0;
    color: var(--ink);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 16px;
    line-height: 1.5;
    background:
        linear-gradient(180deg, rgba(234, 245, 255, 0.96), rgba(255, 255, 255, 0.98) 42%),
        #f7fbff;
}

a {
    color: inherit;
}

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

button,
input,
textarea,
select {
    font: inherit;
}

.site-header,
.site-footer,
.home-shell,
.trust-band,
.result-shell,
.status-shell,
.legal-shell,
.admin-shell {
    width: min(1160px, calc(100% - 32px));
    margin-inline: auto;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 0 10px;
}

.brand img {
    width: min(240px, 54vw);
    height: auto;
}

.top-nav,
.site-footer nav {
    display: flex;
    align-items: center;
    gap: 8px 16px;
    flex-wrap: wrap;
}

.top-nav a,
.site-footer a {
    color: var(--blue-800);
    font-weight: 800;
    text-decoration: none;
}

.top-nav a:hover,
.site-footer a:hover {
    color: var(--orange);
}

.home-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    padding: 18px 0 34px;
}

.hero-copy {
    display: grid;
    gap: 16px;
    align-content: start;
}

.eyebrow {
    margin: 0;
    color: var(--orange);
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.82rem;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    max-width: 760px;
    margin-bottom: 12px;
    color: var(--blue-900);
    font-size: clamp(2.2rem, 9vw, 4.8rem);
    line-height: 1.02;
    letter-spacing: 0;
}

h2 {
    margin-bottom: 0;
    color: var(--blue-900);
    font-size: 1.35rem;
    line-height: 1.15;
    letter-spacing: 0;
}

.lead {
    max-width: 720px;
    color: #34415d;
    font-size: 1.05rem;
}

.price-strip {
    display: grid;
    gap: 8px;
}

.price-strip span {
    display: block;
    padding: 11px 13px;
    border: 1px solid rgba(23, 103, 210, 0.18);
    border-left: 5px solid var(--orange);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--blue-900);
    font-weight: 850;
}

.poster-preview {
    margin: 4px 0 0;
    overflow: hidden;
    border: 1px solid rgba(23, 103, 210, 0.16);
    border-radius: 8px;
    box-shadow: var(--shadow);
    background: var(--paper);
}

.poster-preview img {
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    object-position: top center;
}

.trip-tool,
.admin-login,
.admin-panel {
    border: 1px solid rgba(23, 103, 210, 0.18);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
}

.trip-tool {
    display: grid;
    gap: 18px;
    padding: 18px;
}

.form-heading span,
.names-head span,
label span,
legend {
    color: var(--blue-800);
    font-weight: 900;
}

.form-heading h2 {
    margin-top: 3px;
}

.form-alert {
    padding: 12px 14px;
    border: 1px solid #ffd4a6;
    border-radius: 8px;
    background: #fff7ed;
    color: #9a3412;
    font-weight: 800;
}

.field-grid {
    display: grid;
    gap: 12px;
}

.place-field {
    position: relative;
}

.place-suggestions {
    position: absolute;
    z-index: 20;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 18px 34px rgba(6, 43, 97, 0.16);
}

.place-suggestions button {
    display: grid;
    width: 100%;
    min-height: 50px;
    padding: 10px 12px;
    border: 0;
    border-bottom: 1px solid #edf2f7;
    background: #fff;
    color: var(--ink);
    cursor: pointer;
    text-align: left;
}

.place-suggestions button:hover,
.place-suggestions button.active {
    background: var(--sky);
}

.place-suggestions strong {
    color: var(--blue-800);
    font-size: 0.96rem;
}

.place-suggestion-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.place-suggestion-top em {
    flex: 0 0 auto;
    border-radius: 999px;
    background: #fff3e6;
    color: #9a3412;
    font-size: 0.72rem;
    font-style: normal;
    font-weight: 800;
    padding: 4px 8px;
}

.place-suggestions small,
.place-state {
    color: var(--muted);
    font-size: 0.84rem;
}

.place-state {
    padding: 13px 12px;
}

label {
    display: grid;
    gap: 7px;
}

input,
textarea,
select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--paper);
    color: var(--ink);
    padding: 12px 13px;
    outline: 0;
}

textarea {
    resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
    border-color: var(--blue-600);
    box-shadow: 0 0 0 4px rgba(23, 103, 210, 0.13);
}

.package-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    border: 0;
}

.package-list legend {
    margin-bottom: 2px;
}

.package-option {
    position: relative;
    grid-template-columns: auto 1fr auto;
    align-items: start;
    gap: 10px 12px;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
}

.package-option:has(input:checked) {
    border-color: var(--orange);
    background: linear-gradient(90deg, #fff8ef, #fff);
    box-shadow: inset 4px 0 0 var(--orange);
}

.package-option input {
    width: 20px;
    height: 20px;
    margin-top: 3px;
    accent-color: var(--orange);
}

.package-option strong,
.package-option small,
.package-option b,
.package-option em {
    display: block;
}

.package-option strong {
    color: var(--blue-900);
    font-size: 1.05rem;
}

.package-option small {
    color: var(--muted);
    font-weight: 750;
}

.package-option b {
    color: var(--orange);
    font-size: 1.12rem;
}

.package-option em {
    grid-column: 2 / -1;
    color: #34415d;
    font-size: 0.9rem;
    font-style: normal;
}

.segmented-field {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    border: 0;
}

.segmented-field label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
}

.segmented-field input {
    width: auto;
    accent-color: var(--orange);
}

.segmented-field label:has(input:checked) {
    border-color: var(--orange);
    background: var(--orange-soft);
}

.names-panel {
    display: grid;
    gap: 12px;
    padding: 14px;
    border: 1px solid rgba(255, 122, 0, 0.26);
    border-radius: 8px;
    background: var(--orange-soft);
}

.names-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.names-head small {
    color: var(--muted);
    font-weight: 700;
}

.name-inputs {
    display: grid;
    gap: 10px;
}

.names-textarea {
    display: none;
}

.primary-button,
.secondary-button,
.card-actions a,
.card-actions button,
.item-form button,
.voucher-form button,
.item-list button,
.play-bottom button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 8px;
    padding: 12px 16px;
    font-weight: 900;
    text-decoration: none;
    cursor: pointer;
}

.primary-button {
    background: linear-gradient(135deg, var(--blue-900), var(--blue-600));
    color: #fff;
    box-shadow: 0 12px 26px rgba(23, 103, 210, 0.26);
}

.secondary-button,
.card-actions a,
.card-actions button,
.item-list button,
.play-bottom button {
    border: 1px solid rgba(23, 103, 210, 0.22);
    background: #fff;
    color: var(--blue-800);
}

.primary-button:hover,
.secondary-button:hover,
.card-actions a:hover,
.card-actions button:hover {
    transform: translateY(-1px);
}

.microcopy {
    margin: -6px 0 0;
    color: var(--blue-800);
    font-weight: 850;
    text-align: center;
}

.trust-band {
    display: grid;
    gap: 12px;
    padding: 18px 0 40px;
}

.trust-band div {
    padding: 16px;
    border: 1px solid rgba(16, 185, 129, 0.18);
    border-radius: 8px;
    background: var(--mint);
}

.trust-band strong,
.trust-band span {
    display: block;
}

.trust-band strong {
    color: var(--blue-900);
}

.trust-band span {
    color: #34415d;
}

.result-shell {
    padding: 24px 0 46px;
}

.result-hero,
.status-shell,
.legal-shell {
    padding: 24px;
    border: 1px solid rgba(23, 103, 210, 0.18);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow);
}

.result-hero h1,
.status-shell h1,
.legal-shell h1 {
    font-size: clamp(2rem, 7vw, 3.4rem);
}

.result-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.card-link-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.card-link {
    display: grid;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.card-link span,
.card-link strong {
    display: block;
}

.card-link span {
    color: var(--orange);
    font-weight: 900;
}

.card-link strong {
    color: var(--blue-900);
    font-size: 1.1rem;
}

.card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.status-shell,
.legal-shell {
    max-width: 760px;
    margin-top: 38px;
    margin-bottom: 52px;
    text-align: center;
}

.legal-shell {
    text-align: left;
}

.status-icon {
    display: grid;
    width: 62px;
    height: 62px;
    margin: 0 auto 16px;
    place-items: center;
    border-radius: 50%;
    background: var(--mint);
    color: #047857;
    font-size: 2rem;
    font-weight: 950;
}

.status-icon.soft {
    background: var(--orange-soft);
    color: var(--orange);
}

.site-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    padding: 24px 0 32px;
    border-top: 1px solid rgba(23, 103, 210, 0.16);
    color: #34415d;
}

.site-footer strong,
.site-footer span {
    display: block;
}

.site-footer strong {
    color: var(--blue-900);
}

.play-page {
    background: #f0f8ff;
}

.play-page .site-header,
.play-page .site-footer {
    display: none;
}

.play-shell {
    display: grid;
    min-height: 100vh;
    grid-template-rows: auto auto 1fr auto;
    gap: 12px;
    width: min(620px, 100%);
    margin: 0 auto;
    padding: 12px;
}

.play-top {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 8px 26px rgba(6, 43, 97, 0.11);
}

.play-top img {
    width: 142px;
}

.play-top span,
.play-top strong {
    display: block;
}

.play-top span {
    color: var(--muted);
    font-size: 0.85rem;
    font-weight: 800;
}

.play-top strong {
    color: var(--blue-900);
    font-size: 1.1rem;
}

.play-message {
    min-height: 44px;
    padding: 10px 12px;
    border-radius: 8px;
    background: #fff;
    color: var(--blue-900);
    font-weight: 950;
    text-align: center;
}

.play-message.win {
    background: var(--orange);
    color: #fff;
}

.play-message.full {
    background: linear-gradient(135deg, var(--blue-900), var(--orange));
}

.play-message.pop {
    animation: bingoPop 0.52s ease both;
}

.mobile-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-auto-rows: 1fr;
    gap: 6px;
    aspect-ratio: 1 / 1;
    min-height: 0;
}

.mobile-grid button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-width: 0;
    min-height: 0;
    border: 1px solid rgba(6, 43, 97, 0.26);
    border-radius: 8px;
    background: #fff;
    color: var(--ink);
    padding: 6px;
    font-size: clamp(0.62rem, 2.4vw, 0.9rem);
    font-weight: 850;
    line-height: 1.12;
    text-align: center;
    cursor: pointer;
}

.mobile-grid button img {
    width: min(34px, 42%);
    height: min(34px, 42%);
    object-fit: contain;
    flex: 0 0 auto;
}

.mobile-grid button span {
    display: block;
}

.mobile-grid button.checked {
    border-color: var(--orange);
    background: var(--orange-soft);
    color: var(--blue-900);
    box-shadow: inset 0 0 0 3px rgba(255, 122, 0, 0.18);
}

.mobile-grid button.free {
    background: linear-gradient(135deg, var(--blue-900), var(--blue-600));
    color: #fff;
}

.play-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    color: var(--blue-800);
    font-weight: 850;
}

.confetti-bit {
    position: fixed;
    top: 6px;
    width: 9px;
    height: 15px;
    border-radius: 2px;
    background: var(--orange);
    pointer-events: none;
    animation: confettiFall 1.1s ease-in forwards;
}

.confetti-bit:nth-of-type(3n) {
    background: var(--blue-600);
}

.confetti-bit:nth-of-type(4n) {
    background: #12b76a;
}

@keyframes bingoPop {
    0% { transform: scale(0.94); }
    45% { transform: scale(1.04); }
    100% { transform: scale(1); }
}

@keyframes confettiFall {
    0% { transform: translateY(-12px) rotate(0deg); opacity: 1; }
    100% { transform: translateY(84vh) rotate(280deg); opacity: 0; }
}

.admin-shell {
    padding: 24px 0 46px;
}

.admin-login {
    display: grid;
    max-width: 420px;
    gap: 14px;
    margin: 40px auto;
    padding: 22px;
}

.admin-login img {
    width: 220px;
}

.admin-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.admin-panel {
    padding: 18px;
    margin-top: 18px;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}

.status-grid div {
    display: grid;
    gap: 4px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    padding: 12px;
}

.status-grid span {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.status-grid strong {
    color: var(--blue-800);
}

.places-test {
    display: grid;
    gap: 10px;
}

.places-test select {
    max-width: 220px;
}

.admin-json {
    overflow: auto;
    max-height: 260px;
    margin: 0;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #0d1b2a;
    color: #dbeafe;
    font-size: 0.82rem;
    line-height: 1.45;
    padding: 12px;
}

.table-wrap {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
}

th,
td {
    padding: 10px;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

th {
    color: var(--blue-800);
    font-size: 0.86rem;
}

.item-form,
.voucher-form {
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr;
    margin-bottom: 18px;
}

.checkline {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
}

.checkline input {
    width: auto;
}

.item-list,
.log-list {
    display: grid;
    gap: 8px;
}

.item-list article,
.log-list div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
}

.item-list article.muted {
    opacity: 0.56;
}

.item-list span,
.log-list span,
.log-list small {
    display: block;
    color: var(--muted);
}

@media (min-width: 720px) {
    .field-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .trust-band {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .card-link {
        grid-template-columns: 1fr auto;
        align-items: center;
    }

    .item-form {
        grid-template-columns: 1.3fr 0.8fr 1fr 0.8fr 0.7fr auto auto auto;
        align-items: end;
    }

    .voucher-form {
        grid-template-columns: 1fr 1.2fr 0.7fr 0.7fr 1fr 0.7fr 0.7fr 1fr auto auto;
        align-items: end;
    }
}

@media (min-width: 980px) {
    .home-shell {
        grid-template-columns: minmax(0, 0.92fr) minmax(420px, 0.78fr);
        align-items: start;
        gap: 34px;
        padding-top: 36px;
    }

    .trip-tool {
        position: sticky;
        top: 18px;
        padding: 22px;
    }

    .price-strip {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .site-header {
        align-items: flex-start;
    }

    .top-nav {
        justify-content: flex-end;
        font-size: 0.88rem;
    }

    h1 {
        font-size: clamp(2rem, 13vw, 3rem);
    }

    .poster-preview img {
        max-height: 260px;
    }

    .package-option {
        grid-template-columns: auto 1fr;
    }

    .package-option b {
        grid-column: 2;
    }

    .package-option em {
        grid-column: 2;
    }

    .result-actions,
    .card-actions {
        display: grid;
    }

    .primary-button,
    .secondary-button,
    .card-actions a,
    .card-actions button {
        width: 100%;
    }

    .play-bottom {
        align-items: stretch;
        flex-direction: column;
        text-align: center;
    }
}

.footer-link {
    appearance: none;
    border: 0;
    background: transparent;
    color: inherit;
    cursor: pointer;
    font: inherit;
    padding: 0;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.cookie-consent {
    position: fixed;
    right: 18px;
    bottom: 18px;
    left: 18px;
    z-index: 50;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    max-width: 980px;
    margin: 0 auto;
    padding: 16px;
    border: 1px solid rgba(7, 59, 122, 0.16);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 18px 44px rgba(7, 47, 102, 0.16);
}

.cookie-consent p {
    margin: 0;
    color: #24324b;
    font-size: 0.95rem;
    line-height: 1.45;
}

.cookie-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.cookie-actions button,
.cookie-modal button {
    min-height: 40px;
    border-radius: 8px;
    border: 1px solid #cbd8ea;
    background: #fff;
    color: #073b7a;
    cursor: pointer;
    font-weight: 800;
    padding: 0 14px;
}

.cookie-actions [data-cookie-accept] {
    border-color: #073b7a;
    background: #073b7a;
    color: #fff;
}

.cookie-modal-backdrop {
    position: fixed;
    inset: 0;
    z-index: 60;
    display: grid;
    place-items: center;
    padding: 18px;
    background: rgba(13, 27, 42, 0.36);
}

.cookie-modal {
    width: min(520px, 100%);
    max-height: min(640px, calc(100vh - 36px));
    overflow: auto;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 64px rgba(7, 47, 102, 0.22);
    padding: 20px;
}

.cookie-modal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.cookie-modal h2 {
    margin: 0;
    color: #073b7a;
    font-size: 1.25rem;
}

.cookie-modal-head button {
    width: 40px;
    padding: 0;
    font-size: 1.4rem;
}

.cookie-toggle {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    border: 1px solid #e1e8f2;
    border-radius: 8px;
    padding: 14px;
    margin: 10px 0;
}

.cookie-toggle strong,
.cookie-toggle small {
    display: block;
}

.cookie-toggle strong {
    color: #0d1b2a;
}

.cookie-toggle small {
    color: #5d6b82;
    margin-top: 3px;
    line-height: 1.35;
}

.cookie-toggle input {
    width: 24px;
    height: 24px;
    accent-color: #ff7a00;
}

.cookie-toggle.disabled {
    background: #f4f8fc;
}

@media (max-width: 760px) {
    .cookie-consent {
        grid-template-columns: 1fr;
        bottom: 10px;
        left: 10px;
        right: 10px;
        max-height: 46vh;
        overflow: auto;
    }

    .cookie-actions {
        justify-content: stretch;
    }

    .cookie-actions button {
        flex: 1 1 130px;
    }
}
