﻿/* ---------- Design tokens (mirrors the original palette) ---------- */
:root {
    --paper: #FBF7EF;
    --ink: #20312A;
    --muted: #68766D;
    --green: #2E6B4F;
    --greentint: #E4F0E8;
    --clay: #B45A3C;
    --claytint: #F6E9E1;
    --font-serif: 'Fraunces', serif;
    --font-sans: 'Work Sans', sans-serif;
}

html, body {
    height: 100%;
}

body {
    background: #15201A;
    font-family: var(--font-sans);
    color: var(--ink);
}

/* Utility that mirrors the previously-relied-on Tailwind `.hidden` class, kept so existing show/hide script logic needs no changes. */
.hidden {
    display: none !important;
}

/* Hard "brutalist" border + offset shadow used throughout the design */
.brut,
.oasis .button.brut,
.oasis .input.brut,
.oasis .select.brut select {
    border: 2px solid var(--ink) !important;
    box-shadow: 0 3px 0 var(--ink);
}

.brut-sm {
    border: 2px solid var(--ink) !important;
    box-shadow: 0 2px 0 var(--ink);
}

.brut-lg {
    border: 2px solid var(--ink) !important;
    box-shadow: 0 4px 0 var(--ink);
}

.brut-none {
    border: 2px solid var(--ink) !important;
    box-shadow: 0 0 0 var(--ink);
}

.press:active {
    transform: translateY(2px);
}

.font-serif {
    font-family: var(--font-serif);
}

.radius-lg {
    border-radius: 20px;
}

.radius-md {
    border-radius: 16px;
}

.radius-sm {
    border-radius: 12px;
}

.radius-full {
    border-radius: 999px;
}

/* ---------- App shell ---------- */
.oasis {
    position: relative;
    margin-inline: auto;
    max-width: 430px;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    background: var(--paper);
    padding: 1.25rem 1.25rem 1.5rem;
}

@media (min-width: 640px) {
    .oasis {
        margin-block: 2rem;
        min-height: calc(100dvh - 64px);
        border-radius: 30px;
        border: 2px solid rgba(255,255,255,.1);
        box-shadow: 0 25px 50px -12px rgba(0,0,0,.5);
    }
}

.oasis-view {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    justify-content: space-between;
}

/* ---------- Typography ---------- */
.oasis .title.is-app {
    font-family: var(--font-serif);
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.1;
}

.oasis .eyebrow {
    font-size: .625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .19em;
    color: var(--muted);
}

.oasis .label-field {
    font-size: .6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--muted);
    margin-bottom: .375rem;
    display: block;
}

.oasis p.muted {
    color: var(--muted);
}

/* ---------- Header / brand mark ---------- */
.brand-mark {
    display: grid;
    place-items: center;
    height: 3rem;
    width: 3rem;
    flex-shrink: 0;
    border-radius: 16px;
    background: var(--green);
    color: var(--paper);
    overflow: hidden;
}

    .brand-mark.is-small {
        height: 2.75rem;
        width: 2.75rem;
        border-radius: 14px;
    }

    .brand-mark img {
        height: 100%;
        width: 100%;
        object-fit: cover;
    }

.icon-circle {
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: #fff;
    color: var(--green);
}

/* ---------- Buttons ---------- */
.oasis .button {
    border-radius: 16px;
    font-weight: 700;
    height: auto;
}

    .oasis .button.is-app-primary {
        background: var(--green);
        color: #fff;
    }

        .oasis .button.is-app-primary:hover {
            background: var(--green);
            color: #fff;
        }

    .oasis .button.is-app-ghost {
        background: transparent;
        border: none !important;
        box-shadow: none !important;
        text-decoration: underline;
        text-underline-offset: 4px;
        font-weight: 600;
        color: var(--ink);
        opacity: .8;
    }

/* ---------- Form fields ---------- */
.oasis .input,
.oasis .select select {
    border-radius: 16px;
    background: #fff;
    font-weight: 600;
    box-shadow: none;
}

    .oasis .input:focus,
    .oasis .select select:focus {
        border-color: var(--ink);
        box-shadow: 0 0 0 2px var(--green);
    }

.oasis input#shortCode {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 1.125rem;
}

/* ---------- Notifications / status ---------- */
.oasis .notification.is-app-error {
    background: var(--claytint);
    color: var(--clay);
    border: 2px solid var(--ink);
    border-radius: 16px;
    box-shadow: 0 2px 0 var(--ink);
    font-weight: 600;
    font-size: .8125rem;
    padding: .875rem;
}

/* ---------- Action tiles (check-in / pay bill) ---------- */
.action-tile {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    text-align: left;
    padding: 1.15rem;
    border-radius: 20px;
    background: #fff;
    border: 2px solid var(--ink);
    box-shadow: 0 4px 0 var(--ink);
}

    .action-tile[disabled] {
        border-color: rgba(32,49,42,.4);
        background: rgba(255,255,255,.6);
        box-shadow: none;
        cursor: not-allowed;
        opacity: .6;
    }

    .action-tile .icon-circle.is-tile {
        height: 54px;
        width: 54px;
        border-radius: 16px;
        background: var(--greentint);
        color: var(--green);
        border: 2px solid var(--ink);
    }

    .action-tile[disabled] .icon-circle.is-tile {
        background: rgba(246,233,225,.5);
        color: var(--clay);
        border-color: rgba(32,49,42,.4);
    }

    .action-tile .tile-title {
        display: block;
        font-family: var(--font-serif);
        font-size: 1.25rem;
        font-weight: 600;
    }

    .action-tile .tile-sub {
        display: block;
        font-size: .84375rem;
        line-height: 1.4;
        color: var(--muted);
    }

.chip {
    position: absolute;
    top: -11px;
    right: .875rem;
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    border-radius: 999px;
    border: 2px solid var(--ink);
    background: var(--greentint);
    color: var(--green);
    padding: .25rem .625rem;
    font-size: .6875rem;
    font-weight: 700;
}

    .chip.is-muted {
        border-color: rgba(32,49,42,.4);
        background: var(--claytint);
        color: var(--clay);
    }

.status-row {
    display: flex;
    align-items: center;
    gap: .625rem;
    font-size: .8125rem;
    font-weight: 500;
    color: var(--muted);
}

.status-dot {
    height: .5rem;
    width: .5rem;
    flex-shrink: 0;
    border-radius: 999px;
    border: 1px solid var(--ink);
}

.divider-dashed {
    border: none;
    border-top: 2px dashed rgba(32,49,42,.2);
    margin: 1.25rem 0;
}

/* ---------- Support media list ---------- */
.contact-link {
    position: relative;
    display: flex;
    align-items: center;
    gap: .875rem;
    border-radius: 16px;
    border: 2px solid rgba(32,49,42,.2);
    background: #fff;
    padding: .875rem;
    margin-bottom: .625rem;
    color: inherit;
}

    .contact-link.disabled {
        border-color: rgba(32,49,42,.15);
        background: rgba(255,255,255,.6);
        cursor: not-allowed;
        opacity: .7;
        pointer-events: none;
    }

    .contact-link .contact-title {
        display: block;
        font-size: .96875rem;
        font-weight: 600;
    }

    .contact-link .contact-sub {
        display: block;
        font-size: .78125rem;
        color: var(--muted);
    }

    .contact-link .chip.is-muted {
        position: static;
        flex-shrink: 0;
    }

.fact-list {
    display: grid;
    gap: .25rem;
    border-radius: 16px;
    border: 2px dashed rgba(32,49,42,.3);
    padding: .875rem;
    font-size: .84375rem;
    margin: 0;
}

    .fact-list > div {
        display: flex;
        justify-content: space-between;
        gap: .75rem;
        padding: .25rem 0;
    }

    .fact-list dt {
        color: var(--muted);
    }

    .fact-list dd {
        font-weight: 600;
        text-align: right;
        margin: 0;
    }

/* ---------- Bottom sheets (native <dialog>) ---------- */
dialog.sheet {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    margin: 0 auto;
    width: 100%;
    max-width: 490px;
    max-height: 88dvh;
    border-radius: 26px 26px 0 0;
    border: 2px solid var(--ink);
    border-bottom: none;
    background: var(--paper);
    padding: 0;
    transform: translateY(100%);
    transition: transform .3s cubic-bezier(.16,1,.3,1);
}

    dialog.sheet.slide-out {
        transform: translateY(100%);
        transition: transform .25s ease-in;
    }

    dialog.sheet::backdrop {
        background: rgba(32,49,42,.4);
        backdrop-filter: blur(2px);
    }

@media (min-width: 640px) {
    dialog.sheet {
        bottom: 1.5rem;
        border-radius: 26px;
        border-bottom: 2px solid var(--ink);
    }
}

.sheet-body {
    display: flex;
    max-height: 88dvh;
    flex-direction: column;
}

.sheet-grab {
    display: grid;
    place-items: center;
    padding: .75rem 0;
    cursor: grab;
}

    .sheet-grab span {
        height: .375rem;
        width: 2.75rem;
        border-radius: 999px;
        background: rgba(32,49,42,.25);
    }

.sheet-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.25rem .875rem;
}

.sheet-scroll {
    overflow-y: auto;
    padding: 0 1.25rem 1.5rem;
}

.icon-btn {
    display: grid;
    place-items: center;
    height: 2.25rem;
    width: 2.25rem;
    border-radius: 999px;
    border: 2px solid var(--ink);
    background: #fff;
    box-shadow: 0 2px 0 var(--ink);
}

/* Check-in step states */
.locating-ring-wrap {
    position: relative;
    display: grid;
    place-items: center;
    height: 140px;
    margin-bottom: .875rem;
}

.locating-ping {
    position: absolute;
    height: 92px;
    width: 92px;
    border-radius: 999px;
    border: 2px solid var(--green);
    animation: ping 1.4s cubic-bezier(0,0,.2,1) infinite;
}

@keyframes ping {
    75%,100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

.locating-core {
    z-index: 1;
    display: grid;
    place-items: center;
    height: 58px;
    width: 58px;
    border-radius: 999px;
    background: var(--greentint);
    color: var(--green);
    border: 2px solid var(--ink);
    box-shadow: 0 2px 0 var(--ink);
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%,100% {
        transform: translateY(-6%);
        animation-timing-function: cubic-bezier(.8,0,1,1);
    }

    50% {
        transform: none;
        animation-timing-function: cubic-bezier(0,0,.2,1);
    }
}

.result-badge {
    margin: 0 auto .875rem;
    display: grid;
    place-items: center;
    height: 4rem;
    width: 4rem;
    border-radius: 999px;
    border: 2px solid var(--ink);
    box-shadow: 0 3px 0 var(--ink);
}

    .result-badge.is-success {
        background: var(--green);
        color: #fff;
    }

    .result-badge.is-error {
        background: var(--claytint);
        color: var(--clay);
    }

#toast {
    position: fixed;
    left: 50%;
    top: calc(env(safe-area-inset-top) + 16px);
    z-index: 90;
    transform: translate(-50%, -0.875rem);
    white-space: nowrap;
    border-radius: 999px;
    border: 2px solid rgba(251,247,239,.9);
    background: var(--ink);
    color: var(--paper);
    padding: .625rem 1.25rem;
    font-size: .875rem;
    font-weight: 600;
    opacity: 0;
    transition: all .3s ease;
}

    #toast.is-visible {
        opacity: 1;
        transform: translate(-50%, 0);
    }
