html {
    overflow-y: visible;
    /* The wallpaper: a 500x500 tile, fixed while the page scrolls. */
    background: url("/assets/shattered.png") repeat fixed;
}

/* Dark mode: no wallpaper, just Bulma's dark background. */
html.theme-dark {
    background-image: none;
    background-color: var(--bulma-scheme-main);
}

body {
    font-family: "Quicksand", sans-serif;
    font-weight: 900;
}

.fixed {
    position: fixed;
}

.main-navbar {
    width: 100%;
    top: 0;
    left: 0;
    z-index: 999;
}

.navbar-burger {
    margin-left: 0;
}

#app.container {
    margin-top: 70px !important;
}

.footer {
    position: fixed;
    width: 100%;
    bottom: 0;
    left: 0;
}

.divider-top {
    margin-top: 15px;
    padding-top: 10px;
    border-top: 2px solid hsl(0deg, 0%, 96%);
}

.theme-dark .divider-top {
    border-top: 2px solid#222;
}

.bottom-spacer {
    margin-bottom: 125px !important;
}

.vis-toggle {
    position: absolute;
    z-index: 1;
    margin-top: 9px;
    margin-left: 9px;
}

.floatify {
    position: fixed;
    bottom: 3px;
    left: 5px;
}

.right {
    float: right;
}

.bell {
    margin-left: auto;
}

.theme-dark .navbar-dropdown .navbar-item:not(.is-active, .is-selected) {
    background-color: hsl(221, 14%, 9%) !important;
    color: white !important;
}

.navbar-dropdown .navbar-item:hover,
.navbar-dropdown .navbar-item:active,
.navbar-dropdown .navbar-item:focus,
.navbar-dropdown .navbar-item:hover,
.navbar-dropdown .navbar-item:active,
.navbar-dropdown .navbar-item:focus,
.theme-dark .navbar-dropdown .navbar-item:hover,
.theme-dark .navbar-dropdown .navbar-item:active,
.theme-dark .navbar-dropdown .navbar-item:focus {
    background-color: whitesmoke !important;
    color: #0a0a0a !important;
}

.navbar-dropdown .navbar-item:not(.is-active, .is-selected) {
    color: #4a4a4a !important;
}

.tag {
    margin: 2px;
}

/* Navbar counts (unread messages): a small badge over the icon's top-right corner, so it takes
   no room of its own. */
.main-navbar .navbar-item:has(.nav-badge) {
    position: relative;
}
.main-navbar .nav-badge {
    position: absolute;
    top: 5px;
    left: calc(0.75rem + 13px);
    margin: 0;
    min-width: 1.1rem;
    height: 1.1rem;
    padding: 0 0.3rem;
    border-radius: 999px;
    font-size: 0.65rem;
    font-weight: 700;
    line-height: 1;
    pointer-events: none;
}








.message-header {
    background-color: #32de84;
    color: #fff;
}

.swerve-success {
    border: 2px solid #32de84;
    color: #32de84;
}

.swerve-danger {
    border: 2px solid #D45F7C;
    color: #D45F7C;
}




.mirror {
    -webkit-transform: scaleX(-1);
    transform: scaleX(-1);
}



/* Time's up: Swerve on the left, Match on the right, well apart and labelled. */
.swerve-buttons {
    display: flex;
    justify-content: space-between;
    max-width: 320px;
    margin: 1.5rem auto 0;
}
.swerve-buttons .choice {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    font-weight: 600;
}


.profile-buttons {
    position: absolute;
    right: 5px;
    top: 5px;
}

.users-buttons {
    margin-left: 3px;
}

.message-box-header {
    margin-bottom: 0 !important;
    border-bottom-right-radius: 0;
    border-bottom-left-radius: 0;
}

.message-list-box {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
    height: 80vh;
    overflow: auto;
}

.backToTop {
    cursor: pointer;
}

.theme-dark .backToTop {
    color: black;
}

.messages-box {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    border-bottom-left-radius: 0;
    height: 80vh;
}

.messages-content {
    height: calc(80vh - 100px);
    overflow: auto;
}

.theme-dark .message-active a {
    color: white;
}

.messageSwitchBtn {
    display: none;
    margin-left: 5px;
}

@media (max-width: 1023px) {
    .nav-move1 {
        display: flex;
    }

    .nav-move2 {
        display: none;
    }

}

@media (min-width: 1024px) {
    .nav-move1 {
        display: none;
    }

    .nav-move2 {
        display: flex;
    }
}

@media (max-width: 768px) {
    .messageSwitchBtn {
        display: inline;
    }

    .absolute-hide {
        display: none !important;
    }

}
/* Profile photos (profile page) and photo strips (dates, matches, moderation). */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.75rem;
}
.photo-tile {
    position: relative;
    aspect-ratio: 1;
    border-radius: 10px;
    overflow: hidden;
    background: var(--bulma-background);
}
.photo-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.photo-main {
    position: absolute;
    top: 6px;
    left: 6px;
}
.photo-actions {
    position: absolute;
    right: 6px;
    bottom: 0;
}
.photo-add {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    cursor: pointer;
    border: 2px dashed var(--bulma-border);
    color: var(--bulma-text-weak);
}
.photo-add:hover {
    color: var(--bulma-text-strong);
}
.photo-strip {
    display: flex;
    gap: 6px;
    overflow-x: auto;
}
.photo-strip.is-centered {
    justify-content: center;
}
.photo-strip img {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 8px;
    flex: none;
}

/* Swipe mode (js/swipe.js). */
.swipe-page {
    max-width: 420px;
    margin: 0 auto;
}
.swipe-stack {
    position: relative;
    height: min(70vh, 560px);
}
.swipe-card {
    position: absolute;
    inset: 0;
    border-radius: 16px;
    overflow: hidden;
    background: #222;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    touch-action: pan-y; /* horizontal drags are swipes; vertical still scrolls the page */
    user-select: none;
    cursor: grab;
}
.swipe-card.is-next {
    transform: scale(0.95) translateY(10px);
    filter: brightness(0.8);
    cursor: default;
}
.swipe-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}
.swipe-info {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 2.5rem 1rem 1rem;
    color: #fff;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.75));
}
.swipe-info strong {
    color: #fff;
    font-size: 1.5rem;
    display: block;
}
.swipe-dots {
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    display: flex;
    gap: 4px;
}
.swipe-dots span {
    flex: 1;
    height: 3px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.4);
}
.swipe-dots span.is-on {
    background: #fff;
}
.swipe-stamp {
    position: absolute;
    top: 28px;
    padding: 4px 12px;
    border: 4px solid;
    border-radius: 8px;
    font-size: 2rem;
    font-weight: 900;
    transform: rotate(-12deg);
}
.swipe-stamp.is-like {
    left: 20px;
    color: #32de84;
}
.swipe-stamp.is-pass {
    right: 20px;
    color: #D45F7C;
    transform: rotate(12deg);
}
.swipe-empty {
    position: absolute;
    inset: auto 0;
    top: 30%;
}
.swipe-buttons {
    display: flex;
    justify-content: center;
    gap: 5rem; /* pass and like far enough apart not to hit the wrong one */
    margin-top: 1rem;
}

/* --- The /swerve page (js/live.js) -------------------------------------------------------
   Your camera previews in the stage; on a date their video fills it, yours sits in the top
   corner, and a see-through bar along the bottom holds who they are, the time left, Report and
   Block, and the swerve / like / chat buttons. The chat slides in over the right side. */
.date-stage {
    position: relative;
    overflow: hidden;
    border-radius: 14px;
    background: #000;
    max-width: 720px;
    margin: 0 auto 1rem;
    aspect-ratio: 4 / 3;
    max-height: 55vh;
}
.date-stage.is-live {
    max-width: none;
    aspect-ratio: auto;
    max-height: none;
    height: calc(100dvh - 90px);
    min-height: 360px;
}
.date-stage video {
    display: block;
}
.date-stage .localVideo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.date-stage .peerVideo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}
/* your camera, in the corner during a date */
.date-stage.is-live .localVideo {
    position: absolute;
    z-index: 3;
    top: 14px;
    right: 14px;
    width: clamp(96px, 18vw, 220px);
    height: auto;
    aspect-ratio: 4 / 3;
    border-radius: 10px;
    border: 2px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
    transition: right 0.3s ease;
}
/* Desktop: the open chat sits beside their video and the bar instead of covering them. */
.date-stage.chat-open .peerVideo,
.date-stage.chat-open .date-bar {
    right: 360px;
}
.date-stage.chat-open .localVideo {
    right: calc(360px + 14px);
}
.date-stage .peerVideo,
.date-stage .date-bar {
    transition: right 0.3s ease;
}
.date-timer {
    position: absolute;
    z-index: 4;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: rgba(255, 255, 255, 0.15);
}
.date-timer span {
    display: block;
    height: 100%;
    background: #D45F7C;
    transition: width 0.5s linear;
}

.date-bar {
    position: absolute;
    z-index: 4;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.9rem 1.25rem;
    color: #fff;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.35));
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}
.date-who {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: center;
    column-gap: 0.75rem;
    min-width: 0;
    text-align: center;
}
.date-who strong {
    color: #fff;
    font-size: 1.35rem;
}
.date-time {
    font-variant-numeric: tabular-nums;
    font-size: 1.1rem;
    opacity: 0.9;
}
.date-links {
    flex-basis: 100%;
    font-size: 0.85rem;
}
.date-links a {
    color: rgba(255, 255, 255, 0.75);
}
.date-links a:hover {
    color: #fff;
    text-decoration: underline;
}
.date-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: none;
}
.date-btn {
    position: relative;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: 2px solid currentColor;
    background: rgba(0, 0, 0, 0.35);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.12s, background 0.12s;
}
.date-btn .material-symbols-outlined {
    font-size: 30px;
}
.date-btn:hover:not(:disabled) {
    transform: scale(1.08);
}
.date-btn.is-swerve { color: #ff6b81; }
.date-btn.is-like { color: #32de84; }
.date-btn.is-like:disabled {
    cursor: default;
    background: #32de84;
    color: #fff;
    border-color: #32de84;
}
.date-btn.is-like:disabled .material-symbols-outlined {
    font-variation-settings: 'FILL' 1;
}
.date-btn.is-chat {
    color: #fff;
    width: 46px;
    height: 46px;
}
.date-btn.is-chat .material-symbols-outlined {
    font-size: 22px;
}
.date-unseen {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 10px;
    background: #D45F7C;
    color: #fff;
    font-size: 0.75rem;
    line-height: 20px;
}

/* the chat panel */
.date-chat {
    position: absolute;
    z-index: 5;
    top: 4px;
    right: 0;
    bottom: 0;
    width: min(360px, 100%);
    display: flex;
    flex-direction: column;
    background: rgba(16, 16, 20, 0.82);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #fff;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}
.date-chat.is-open {
    transform: none;
}
.date-chat-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.9rem 1rem 0.6rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.date-chat-head strong {
    color: #fff;
}
.date-chat-bio {
    font-size: 0.85rem;
    opacity: 0.8;
}
.date-chat-head .photo-strip img {
    width: 44px;
    height: 44px;
}
.date-chat-thread {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    padding: 0.75rem;
}
.date-chat .dm-bubble:not(.is-mine) {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}
.date-chat-empty {
    text-align: center;
    opacity: 0.6;
    margin-top: 1rem;
}
.date-chat-input {
    display: flex;
    gap: 0.4rem;
    padding: 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}
.date-chat-input .input {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}
.date-chat-input .input::placeholder {
    color: rgba(255, 255, 255, 0.55);
}

/* Phones: a smaller bar; the chat takes the whole stage. */
@media (max-width: 768px) {
    .date-stage.is-live {
        height: calc(100dvh - 76px);
        border-radius: 0;
    }
    .date-stage .peerVideo { object-fit: cover; } /* phones are portrait: fill, don't letterbox */
    .date-stage.chat-open .peerVideo,
    .date-stage.chat-open .date-bar { right: 0; }
    .date-bar {
        padding: 0.7rem 0.8rem;
        gap: 0.5rem;
    }
    .date-who strong { font-size: 1.1rem; }
    .date-btn { width: 50px; height: 50px; }
    .date-btn.is-chat { width: 42px; height: 42px; }
    .date-stage.chat-open .localVideo { right: 14px; }
    .date-chat { width: 100%; bottom: 72px; } /* above the bar, so like/swerve stay reachable */
}
/* the preferences and lobby boxes line up under the camera preview */
.swerve-preferences,
.swerve-lobby {
    max-width: 720px;
    margin-left: auto;
    margin-right: auto;
}
.swerve-preferences .box { margin-top: 0 !important; }

/* ==== Footer (like Simul's) ====================================================== */
/* One slim line, fixed to the bottom of the info pages. */
.app-footer {
    padding: 0 16px;
    z-index: 20;
    border-top: 1px solid rgba(127, 127, 127, 0.18);
    background: rgba(255, 255, 255, 0.82);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
}
.theme-dark .app-footer { background: rgba(20, 22, 26, 0.82); }
.app-footer-line {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    height: 40px;
    font-size: 13px;
    white-space: nowrap;
}
.app-footer-brand { display: inline-flex; align-items: center; gap: 0.3rem; font-weight: 700; color: inherit; }
.app-footer-brand img { width: 20px; height: 20px; }
.app-footer-brand:hover { color: #D45F7C; }
.app-footer-year { opacity: 0.6; }
.app-footer-links { display: flex; align-items: center; }
.app-footer-links a { color: inherit; opacity: 0.75; transition: color 0.15s, opacity 0.15s; }
.app-footer-links a:hover { color: #D45F7C; opacity: 1; }
/* dots between the links (only between the ones showing) */
.app-footer-links a + a::before { content: '·'; display: inline-block; margin: 0 0.5rem; opacity: 0.5; color: var(--bulma-text, currentColor); }
.app-footer-year + .app-footer-links::before { content: '·'; margin-right: 0.75rem; opacity: 0.5; }
.app-footer-line > * { flex-shrink: 0; }
@media (max-width: 420px) {
    .app-footer-from { display: none; } /* "© 2027" on phones */
}
@media (max-width: 359px) {
    .app-footer-line { gap: 0.5rem; font-size: 12px; }
    .app-footer-year + .app-footer-links::before { margin-right: 0.5rem; }
}
/* Swerve's name in its logo font. */
.app-footer-brand .navbar-logo { font-size: 17px; font-weight: 400; color: #D45F7C; }

/* ==== Home page ============================================================================ */
.home-hero {
    position: relative;
    padding: 2.5rem 2rem 2.25rem;
    border-radius: 18px;
    background:
        radial-gradient(circle at 85% 20%, rgba(212, 95, 124, 0.22), transparent 45%),
        radial-gradient(circle at 10% 90%, rgba(212, 95, 124, 0.12), transparent 40%),
        rgba(127, 127, 127, 0.07);
    border: 1px solid rgba(127, 127, 127, 0.16);
    overflow: hidden;
}

.home-title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 0.9rem;
}

.home-title span { color: #D45F7C; }

.home-lead {
    max-width: 640px;
    font-size: 1.15rem;
    line-height: 1.55;
    opacity: 0.85;
}

.home-cta { margin-top: 1.5rem; }
.home-cta .button { border-radius: 999px; gap: 0.35rem; font-weight: 700; }
.home-cta .button .material-symbols-outlined { font-size: 20px; }
.home-ghost { background: transparent; border: 1px solid rgba(127, 127, 127, 0.35); }
.home-ghost:hover { border-color: #D45F7C; color: #D45F7C; }

.home-features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin: 1.5rem 0 2.5rem;
}

.home-feature {
    padding: 1.1rem 1.2rem;
    border-radius: 14px;
    border: 1px solid rgba(127, 127, 127, 0.16);
    background: rgba(127, 127, 127, 0.05);
}

.home-feature > .material-symbols-outlined {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 22px;
    color: #D45F7C;
    background: rgba(212, 95, 124, 0.13);
}

.home-feature h3 { margin: 0.6rem 0 0.25rem; font-size: 1.05rem; font-weight: 700; }
.home-feature p { font-size: 0.92rem; line-height: 1.45; opacity: 0.75; }
/* Three cards side by side; one under another on phones. */
@media (max-width: 768px) { .home-features { grid-template-columns: 1fr; } }


/* Swerve: the cards sit on the wallpaper, so they're solid. */
.sw-home { padding-bottom: 3.5rem; } /* clear of the fixed footer */
.sw-home .home-hero {
    text-align: center;
    background:
        radial-gradient(circle at 85% 15%, rgba(212, 95, 124, 0.2), transparent 45%),
        radial-gradient(circle at 10% 95%, rgba(255, 143, 171, 0.18), transparent 40%),
        var(--bulma-scheme-main);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}
.sw-home .home-lead { margin: 0 auto; }
.sw-home .home-cta .buttons { justify-content: center; }
.home-logo { display: block; font-size: 2.4rem; line-height: 1; margin-bottom: 0.6rem; color: #D45F7C; }
.sw-home .home-feature, .home-step { background: var(--bulma-scheme-main); }
.home-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin-top: 1.5rem; }
.home-step {
    display: flex; gap: 0.85rem; align-items: flex-start; padding: 1.1rem 1.2rem;
    border-radius: 14px; border: 1px solid rgba(127, 127, 127, 0.16);
}
.home-step-no {
    flex: none; display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 50%;
    background: #D45F7C; color: #fff; font-weight: 700;
}
.home-step h3 { margin: 0.2rem 0 0.25rem; font-size: 1.05rem; font-weight: 700; }
.home-step p { font-size: 0.92rem; line-height: 1.45; opacity: 0.75; }
.sw-home .home-features { margin-top: 1rem; }
@media (max-width: 768px) { .home-steps { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .sw-home .home-hero { padding: 1.75rem 1.1rem 1.5rem; } .home-logo { font-size: 2rem; } }

/* --- Icon-only navbar ---------------------------------------------------------------------- */
.navbar-item.nav-icon { justify-content: center; }
.navbar-item.nav-icon .material-symbols-outlined, .nav-account .material-symbols-outlined { font-size: 26px; transition: color 0.15s, transform 0.15s; }
.navbar-item.nav-icon:hover .material-symbols-outlined, .nav-account:hover .material-symbols-outlined { color: #D45F7C; }
.navbar-item.nav-icon.is-current .material-symbols-outlined { color: #D45F7C; font-variation-settings: 'FILL' 1; }
.navbar .navbar-item.nav-icon:hover, .navbar .navbar-item.nav-icon:focus { background-color: transparent; }
.nav-home { padding-left: 0.4rem; }
@media (min-width: 1024px) {
    .navbar-end > .navbar-item.nav-icon { padding-left: 0.85rem; padding-right: 0.85rem; }
    .nav-account { padding-right: 2.2rem; }
}
@media (max-width: 1023px) {
    .nav-account .is-hidden-desktop { margin-left: 0.35rem; }
}
/* Tight phones: logo, home, four icons and the burger. */
@media (max-width: 400px) {
    .main-navbar .navbar-brand > .navbar-item.nav-icon { padding-left: 0.4rem; padding-right: 0.4rem; }
    .main-navbar .navbar-brand > .navbar-item.nav-icon .material-symbols-outlined { font-size: 24px; }
}
@media (max-width: 359px) {
    .main-navbar .navbar-brand > .navbar-item.nav-icon { padding-left: 0.25rem; padding-right: 0.25rem; }
}

/* Hover: a soft pink circle behind the icon (box-shadow, so nothing moves and badges stay put). */
.navbar-item.nav-icon .material-symbols-outlined, .nav-account .material-symbols-outlined {
    border-radius: 50%;
    transition: color 0.15s, background-color 0.15s, box-shadow 0.15s, transform 0.1s;
}
.navbar-item.nav-icon:hover .material-symbols-outlined, .nav-account:hover .material-symbols-outlined,
.navbar-item.nav-icon:focus-visible .material-symbols-outlined {
    background-color: rgba(212, 95, 124, 0.16);
    box-shadow: 0 0 0 7px rgba(212, 95, 124, 0.16);
}
.navbar-item.nav-icon.is-current:hover .material-symbols-outlined {
    background-color: rgba(212, 95, 124, 0.24);
    box-shadow: 0 0 0 7px rgba(212, 95, 124, 0.24);
}
.navbar-item.nav-icon:active .material-symbols-outlined { transform: scale(0.9); }

