/* ============================================
   WALL OF FAME — styles.css
   Mobile-first · DM Sans · Figma-accurate
   ============================================ */

:root {
    /* Colors */
    --bg: #ffffff;
    --bg-board: #D9D9D9;
    --bg-soft: #f9f9f9;
    --nav-pill-border: #DEDEDE;
    --nav-active: #f2f2f2;
    --action-pill-bg: #f6edff;
    --text-primary: #1A1A1A;
    --text-secondary: #555555;
    --text-muted: #999999;
    --dashed-line: #D4D4D4;
    --border-light: #EBEBEB;

    /* Scrapbook palette */
    --tape: #E8DCC5;
    --tape-dark: #D4C8AA;
    --sticky-yellow: #FFF9A0;
    --sticky-pink: #FFD0E0;
    --sticky-blue: #C8EEFF;
    --sticky-green: #D4FFCB;

    /* Typography */
    --font-ui: 'DM Sans', -apple-system, sans-serif;
    --font-hand: SFMono-Regular, Consolas, 'Liberation Mono', Menlo, monospace;
    --font-serif: 'Instrument Serif', serif;

    /* Radii */
    --r-pill: 999px;
    --r-card: 12px;
    --r-sm: 8px;

    /* Shadows */
    --shadow-xs: 0 1px 4px rgba(0, 0, 0, 0.08);
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.10);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.14);
    --shadow-xl: 0 12px 40px rgba(0, 0, 0, 0.18);

    /* Transitions */
    --t: 0.2s ease;

    /* Wall layout */
    --wall-frame-width: min(calc(100% - 32px), 430px);
}

/* =====================
   RESET & BASE
   ===================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    height: 100%;
}

body {
    font-family: var(--font-ui);
    background: #EBEBEB;
    color: var(--text-primary);
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    overflow: hidden;
}

@media (pointer: coarse) {
    html,
    body,
    #app {
        touch-action: pan-y;
    }

    body.board-editing-mode .top-nav {
        display: none;
    }

    body.board-editing-mode .board-header {
        display: none;
    }

    body.board-editing-mode .board-canvas-wrap {
        margin-top: 16px;
    }

    .layer-palette {
        display: none !important;
    }

    body.mobile-layer-reordering .layer-palette {
        display: block !important;
        left: 16px;
        opacity: 1;
        pointer-events: auto;
        transform: translateY(-50%) scale(1);
    }

    .board-canvas-wrap.has-active-layer {
        transform: none;
    }
}

#app {
    width: 100%;
    max-width: 430px;
    height: 100vh;
    height: 100dvh;
    background: var(--bg);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

@media (min-width: 431px) {
    #app {
        border-radius: 40px;
        margin: 20px auto;
        width: calc(100% - 40px);
        max-width: 430px;
        height: calc(100vh - 40px);
        height: calc(100dvh - 40px);
        box-shadow: var(--shadow-xl);
        overflow: hidden;
    }

    body {
        align-items: center;
        justify-content: center;
    }

    .layer-palette {
        left: 19px;
    }
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.hidden {
    display: none !important;
}

/* =====================
   FULLSCREEN AUTH SCREENS
   ===================== */
.fullscreen-screen {
    position: absolute;
    inset: 0;
    z-index: 60;
    background: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 28px;
    overflow-y: auto;
}

/* Onboarding */
.app-loading-wrap {
    text-align: center;
    width: 100%;
    max-width: 340px;
}

.app-loading-mark {
    display: block;
    width: 72px;
    height: 72px;
    margin: 0 auto 14px;
    object-fit: contain;
    filter: drop-shadow(0 8px 16px rgba(12, 147, 52, 0.16));
    animation: loadingPulse 1.2s ease-in-out infinite;
}

.app-loading-text {
    margin: 0;
    font-family: var(--font-ui);
    font-size: 1rem;
    font-weight: 700;
}

.app-loading-track {
    position: relative;
    width: 118px;
    height: 8px;
    margin: 18px auto 0;
    overflow: hidden;
    border: 1px solid #e6d0ff;
    border-radius: 999px;
    background: #f8f1ff;
    box-shadow: inset 0 1px 2px rgba(126, 34, 206, 0.08);
}

.app-loading-fill {
    position: absolute;
    inset: 1px auto 1px 1px;
    width: 42px;
    border-radius: inherit;
    background: linear-gradient(90deg, #e9d5ff, #c084fc, #f9a8d4);
    box-shadow: 0 0 10px rgba(192, 132, 252, 0.32);
    animation: loadingSlide 1.35s ease-in-out infinite;
}

@keyframes loadingPulse {

    0%,
    100% {
        opacity: 0.45;
        transform: scale(0.96);
    }

    50% {
        opacity: 1;
        transform: scale(1.04);
    }
}

@keyframes loadingSlide {

    0% {
        transform: translateX(0);
    }

    50% {
        transform: translateX(72px);
    }

    100% {
        transform: translateX(0);
    }
}

.onboarding-wrap {
    text-align: center;
    width: 100%;
    max-width: 340px;
}

.onboarding-badge {
    font-size: 2.8rem;
    margin-bottom: 20px;
    display: block;
    animation: floatBob 3s ease-in-out infinite;
}

@keyframes floatBob {

    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-8px) rotate(10deg);
    }
}

.onboarding-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 14px;
    letter-spacing: -0.5px;
}

.onboarding-sub {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 36px;
}

/* Setup */
.setup-wrap {
    width: 100%;
    max-width: 340px;
    text-align: center;
}

.btn-back {
    position: absolute;
    top: 20px;
    left: 20px;
    background: none;
    border: none;
    font-family: var(--font-ui);
    font-size: 0.9rem;
    color: var(--text-muted);
    cursor: pointer;
}

.setup-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 28px;
}

.avatar-upload {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    cursor: pointer;
}

.avatar-circle {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    background: #f0f0f0;
    border: 2px dashed #ccc;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: border-color var(--t);
}

.avatar-circle:hover {
    border-color: #c084fc;
}

.avatar-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ring-selector-container {
    margin: -10px 0 16px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.ring-selector-label {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.ring-colors-row {
    display: grid;
    grid-template-columns: repeat(5, 24px);
    gap: 10px 12px;
    justify-content: center;
    align-items: center;
    max-width: 168px;
    margin: 0 auto;
}

.ring-color-swatch {
    position: relative;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform var(--t), border-color var(--t);
    padding: 0;
    outline: none;
    overflow: visible;
}

.ring-color-swatch .premium-star-badge {
    right: -5px;
    bottom: -4px;
    width: 10px;
    height: 10px;
    border-color: rgba(192, 132, 252, 0.45);
    background: rgba(255, 255, 255, 0.96);
    color: #8b5cf6;
    -webkit-text-stroke: 0;
    font-size: 0.5rem;
    box-shadow: 0 1px 2px rgba(124, 58, 237, 0.16);
    text-shadow: none;
    z-index: 4;
}

.ring-color-swatch:hover {
    transform: scale(1.1);
}

.ring-color-swatch.active {
    border-color: #7c3aed;
    transform: scale(1.2);
}

.avatar-plus {
    font-size: 1.8rem;
    color: #bbb;
    line-height: 1;
}

.avatar-hint {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.setup-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 24px;
}

.field-input {
    width: 100%;
    padding: 13px 18px;
    border: 1.5px solid var(--border-light);
    border-radius: var(--r-card);
    font-family: var(--font-ui);
    font-size: 0.95rem;
    text-align: center;
    outline: none;
    transition: border-color var(--t);
    background: var(--bg);
}

.field-input:focus {
    border-color: #c084fc;
}

.field-input.error {
    border-color: #f87171;
}

/* =====================
   SHARED BUTTONS
   ===================== */
.btn-primary {
    display: block;
    width: 100%;
    padding: 14px 24px;
    border-radius: var(--r-pill);
    background: var(--text-primary);
    color: white;
    border: none;
    font-family: var(--font-ui);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform var(--t), box-shadow var(--t);
    margin-bottom: 12px;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-ghost {
    display: block;
    width: 100%;
    padding: 12px 24px;
    border-radius: var(--r-pill);
    background: transparent;
    color: var(--text-muted);
    border: 1.5px solid var(--border-light);
    font-family: var(--font-ui);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--t);
}

.btn-ghost:hover {
    border-color: #ccc;
    color: var(--text-secondary);
}

.icon-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    border-radius: var(--r-sm);
    transition: background var(--t);
}

.icon-btn:hover {
    background: #f5f5f5;
}

/* =====================
   MAIN APP LAYOUT
   ===================== */
#main-app {
    display: flex;
    flex-direction: column;
    height: 100%;
    position: absolute;
    inset: 0;
    z-index: 10;
}

/* =====================
   TOP NAV PILL
   ===================== */
.top-nav {
    flex-shrink: 0;
    padding: 16px 16px 6px;
    background: var(--bg);
    z-index: 50;
}

.nav-pill {
    display: flex;
    align-items: stretch;
    border: 1.5px solid var(--nav-pill-border);
    border-radius: var(--r-pill);
    padding: 0;
    gap: 0;
    background: var(--bg);
    overflow: hidden;
}

.nav-separator {
    width: 1.5px;
    align-self: stretch;
    margin: 0;
    background-color: var(--nav-pill-border);
    flex-shrink: 0;
}

.nav-tab {
    flex: 1;
    border: none;
    background: none;
    cursor: pointer;
    border-radius: 0;
    padding: 6px 4px;
    font-family: var(--font-serif);
    font-size: 20px;
    font-weight: 400;
    color: var(--text-primary);
    white-space: nowrap;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    position: relative;
    transition: background var(--t), font-weight var(--t);
    letter-spacing: 0;
    outline: none;
}

.nav-tab.active {
    background: var(--nav-active);
    font-weight: 600;
}

/* Avatar tab and settings tab */
#tab-board, #btn-settings {
    flex: 0 0 44px;
    padding: 3px;
}

.nav-avatar-ring {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid transparent;
    transition: border-color var(--t), transform var(--t), box-shadow var(--t);
}

.visitor-wall-header {
    flex-shrink: 0;
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 44px;
    align-items: center;
    gap: 8px;
    padding: 14px 16px 8px;
    background: var(--bg);
    z-index: 50;
}

.visitor-back-btn {
    width: 38px;
    height: 38px;
    border: 1.5px solid var(--nav-pill-border);
    border-radius: 50%;
    background: white;
    color: var(--text-primary);
    font-family: var(--font-ui);
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
}

.visitor-wall-label {
    color: var(--text-primary);
    font-family: var(--font-serif);
    font-size: 1.55rem;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.visitor-follow-btn {
    min-width: 68px;
    height: 28px;
    padding: 0 10px;
    border: 1.5px solid #111111;
    border-radius: 999px;
    background: #111111;
    color: white;
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 700;
    cursor: pointer;
}

.board-user-row .visitor-follow-btn {
    justify-self: end;
    align-self: center;
    flex-shrink: 0;
}

.visitor-follow-btn.is-following {
    background: white;
    color: #111111;
}

#tab-board.active .nav-avatar-ring {
    transform: scale(1.1);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.nav-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}

.nav-avatar-initial {
    font-size: 1rem;
    font-weight: 700;
    color: white;
}

.inbox-badge {
    background: #e8453c;
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    margin-left: 2px;
}

/* =====================
   SCREENS CONTAINER
   ===================== */
.screens-wrap {
    flex: 1;
    position: relative;
    overflow: hidden;
}

.main-screen {
    position: absolute;
    inset: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    animation: screenIn 0.2s ease;
}

@keyframes screenIn {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* =====================
   BOARD SCREEN
   ===================== */
#screen-board {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    background-color: var(--bg);
    transition: background-color 0.4s ease;
}

/* Spotlight Vignette Overlay */
#screen-board::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.4) 0%, rgba(0, 0, 0, 0.15) 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: 0;
}

/* Edit Mode Desk Shift */
#screen-board.edit-active {
    background-color: #D3D3D3; /* Light grey workspace desk */
}

#screen-board.edit-active::before {
    opacity: 1;
}

/* Make headers legible */
.board-username, .board-followers, #btn-settings {
    transition: color 0.4s ease;
}

#screen-board.edit-active .board-followers {
    color: #4b5563; /* Slightly darker for contrast on grey */
}

.board-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0 6px;
    width: var(--wall-frame-width);
    max-width: calc(100% - 32px);
    margin: 0 auto;
    flex-shrink: 0;
}

.board-user-row {
    display: grid;
    grid-template-columns: minmax(0, auto) 1fr auto auto;
    align-items: baseline;
    gap: 6px;
    width: 100%;
}

.board-username {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: -0.2px;
}

.board-followers {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-weight: 400;
}

.board-canvas-wrap {
    flex: 1 1 auto;
    min-height: 0;
    max-width: calc(100% - 32px);
    width: var(--wall-frame-width);
    align-self: center;
    margin: 4px auto 16px;
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    /* Elevation shadow — stronger on sides and bottom */
    box-shadow:
        -6px 0 16px rgba(0, 0, 0, 0.10),
        6px 0 16px rgba(0, 0, 0, 0.10),
        0 12px 24px rgba(0, 0, 0, 0.16),
        0 20px 40px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.board-canvas-wrap.has-active-layer {
    transform: none;
}

.board-canvas {
    width: 100%;
    height: 100%;
    /* White pegboard with custom background image */
    background-image: url('Component/board.png');
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
}

.board-profile-circle {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 130px;
    height: 130px;
    border-radius: 50%;
    border: 8px solid #e2bbf0;
    background: white;
    z-index: 0;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    pointer-events: auto;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease;
}

.board-profile-circle:hover {
    transform: translate(-50%, -50%) scale(1.05);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.16);
}

.board-profile-circle:active {
    transform: translate(-50%, -50%) scale(0.98);
}

.board-profile-circle img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.fab-edit {
    height: 32px;
    border-radius: 50px;
    background: #F7EEFF;
    border: 1px solid #D9B8FF;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 4px 16px;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    color: #1f1f1f;
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease, transform var(--t);
    font-family: 'DM Sans', sans-serif;
    font-size: 18px;
    font-weight: 400;
    white-space: nowrap;
    flex-shrink: 0;
}

.fab-edit svg {
    width: 20px !important;
    height: 20px !important;
}

.fab-share {
    background: #f0e3ff;
    border-color: #cf9fff;
}

#btn-edit-board {
    background: #e7c5ff;
    border-color: #b56cff;
    font-weight: 600;
}

.fab-edit:hover {
    transform: scale(1.04);
    background: #f1d7ff;
    border-color: #c991ff;
    color: #111111;
}

.fab-edit.active-fab {
    background: #e7c5ff;
    border-color: #b56cff;
    color: black;
}

.fab-edit.active-fab .icon-pencil {
    display: none !important;
}

.fab-edit.active-fab .icon-check {
    display: block !important;
}

@keyframes editBoardAttention {
    0%, 100% {
        transform: scale(1);
        border-color: #d1d5db;
        box-shadow: var(--shadow-sm);
    }
    35% {
        transform: scale(1.08);
        border-color: #a855f7;
        box-shadow: 0 0 0 5px rgba(168, 85, 247, 0.18);
    }
    70% {
        transform: scale(1.02);
        border-color: #c084fc;
        box-shadow: 0 0 0 3px rgba(192, 132, 252, 0.14);
    }
}

.fab-edit.edit-board-attention {
    animation: editBoardAttention 0.85s ease;
}

.board-edit-cancel {
    border-color: #d1d5db;
    background: #ffffff;
    color: #4b5563;
    box-shadow: none;
}

.board-edit-cancel:hover {
    border-color: #9ca3af;
    background: #f9fafb;
    color: #111111;
}

.board-dock {
    position: absolute;
    top: 66px;
    right: max(18px, calc((100% - var(--wall-frame-width)) / 2 + 10px));
    margin: 0;
    padding: 0;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    display: none;
    flex-direction: column;
    align-items: center;
    z-index: 25;
    pointer-events: none;
    transition: opacity var(--t), transform var(--t);
}

#screen-board.edit-active .board-dock {
    display: flex;
}

.board-cta-label {
    display: none;
}

#screen-board.edit-active .board-cta-label {
    color: rgba(255, 255, 255, 0.95);
}

.action-row {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 14px;
    padding: 0;
    width: auto;
    pointer-events: auto;
}

.action-pill-btn {
    flex: 0 0 auto;
    width: 48px;
    max-width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #6D6A6A;
    border: 2px solid #464444;
    cursor: pointer;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0;
    color: #FFFFFF;
    transition: transform var(--t), box-shadow var(--t);
    padding: 0;
}

.action-btn-label {
    display: none;
}

.action-pill-btn:hover {
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.18);
}

.action-pill-btn:active {
    transform: scale(0.96);
}

/* =====================
   BOARD ITEMS
   ===================== */
.board-item {
    position: absolute;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease, z-index 0s;
    touch-action: none;
}

.board-item:hover {
    z-index: calc(var(--item-z-index, 1) + 10) !important;
    filter: brightness(1.02);
}

.premium-board-preview {
    outline: 1.5px dashed rgba(168, 85, 247, 0.75);
    outline-offset: 5px;
}

.premium-board-preview-badge {
    position: absolute;
    right: -8px;
    bottom: -18px;
    z-index: 20;
    padding: 3px 6px;
    border: 1px solid #d8b4fe;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.96);
    color: #7e22ce;
    font-family: var(--font-ui);
    font-size: 0.58rem;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    pointer-events: none;
}

.premium-board-item-badge {
    position: absolute;
    right: -8px;
    bottom: -8px;
    z-index: 20;
    width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(192, 132, 252, 0.38);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    color: #a855f7;
    -webkit-text-stroke: 0.6px #7c3aed;
    font-family: var(--font-ui);
    font-size: 0.95rem;
    line-height: 1;
    pointer-events: none;
    box-shadow: 0 2px 8px rgba(126, 34, 206, 0.14);
}

/* Sticky note */
.item-sticky {
    width: 110px;
    height: 110px;
    padding: 14px 12px;
    font-family: var(--font-hand);
    font-size: 0.95rem;
    line-height: 1.3;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    word-break: break-word;
    box-shadow: none;
    border: none;
    background: transparent;
    z-index: 1;
}

.item-sticky::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url('Component/sticky note.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    z-index: -1;
    transition: filter var(--t);
}

.item-sticky.yellow::before {
    filter: none;
}

.item-sticky.pink::before {
    filter: hue-rotate(-65deg) saturate(1.4) brightness(1.05);
}

.item-sticky.blue::before {
    filter: hue-rotate(145deg) saturate(1.4) brightness(1.05);
}

/* Masking tape note */
.item-tape {
    width: 140px;
    height: 70px;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background-image: url('Component/masking tape.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-color: transparent;
    font-family: var(--font-hand);
    font-size: 0.9rem;
    line-height: 1.2;
    word-break: break-word;
    box-shadow: none;
    border: none;
}

/* Plain text note */
.item-plain-text {
    width: 130px;
    min-height: 34px;
    padding: 2px 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    box-shadow: none;
    color: #000;
    font-family: var(--font-ui);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.2;
    word-break: break-word;
}

.item-plain-text .item-note-text {
    display: block;
    width: 100%;
}

/* CD / Vinyl Player & Disc */
.item-cd-wrap {
    display: inline-block;
}

.item-vinyl-player {
    width: 88px;
    height: 88px;
    position: relative;
    display: inline-block;
    vertical-align: middle;
    --vinyl-left: 18%;
    --vinyl-top: 19%;
    --vinyl-size: 54%;
}

.vinyl-player-img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    pointer-events: none;
}

.vinyl-record-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    pointer-events: none;
}

.rotating-vinyl {
    animation: rotateVinyl 4s linear infinite;
    transform-origin: center center;
}

@keyframes rotateVinyl {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.item-cd-song-label {
    position: absolute;
    bottom: -18px;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--font-hand);
    font-size: 0.72rem;
    white-space: nowrap;
    color: rgba(0, 0, 0, 0.55);
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Large Vinyl Player for Timeline and Inbox */
.item-vinyl-player.large-vinyl-player {
    width: 150px;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.large-vinyl-player .cd-tl-overlay {
    color: rgba(255, 255, 255, 0.9) !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8) !important;
    z-index: 5;
    pointer-events: none;
}

/* Voice note */
.item-voice {
    width: 130px;
    background: white;
    border-radius: 10px;
    padding: 10px 10px;
    box-shadow: 2px 4px 12px rgba(0, 0, 0, 0.12);
}

.voice-mini-row {
    display: flex;
    align-items: center;
    gap: 7px;
}

.voice-mini-play {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--text-primary);
    color: white;
    border: none;
    font-size: 0.65rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.voice-mini-waveform {
    display: flex;
    align-items: center;
    gap: 2px;
    height: 22px;
    flex: 1;
}

.voice-mini-waveform span {
    flex: 1;
    min-width: 2px;
    background: #ccc;
    border-radius: 2px;
}

.voice-mini-dur {
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 4px;
    text-align: right;
}

/* Decoration */
.item-decor {
    font-size: 1.8rem;
    line-height: 1;
    background: none !important;
    box-shadow: none !important;
    filter: drop-shadow(1px 2px 4px rgba(0, 0, 0, 0.18));
}

.item-decor:hover {
    filter: drop-shadow(2px 4px 6px rgba(0, 0, 0, 0.25)) !important;
}

/* =====================
   FOLDER & CONTAINER ITEMS
   ===================== */
.item-folder {
    width: 80px;
    height: 112px;
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    cursor: default;
    user-select: none;
    transition: transform var(--t);
}

.board-canvas.edit-active .item-folder {
    cursor: pointer;
}

.board-canvas.edit-active .item-folder:hover {
    transform: scale(1.05) rotate(1deg);
}

/* Visual graphical box for containers */
.folder-visual {
    width: 80px;
    height: 80px;
    position: relative;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    transition: box-shadow var(--t);
}

.item-folder:hover .folder-visual {
    box-shadow: 0 6px 14px rgba(0,0,0,0.22);
}

/* Manila Folder skin */
.folder-visual.skin-folder {
    background: linear-gradient(135deg, #f7dfaf 0%, #ecd099 100%);
    border: 1.5px solid #d4b882;
    border-radius: 4px 10px 10px 10px;
}

/* Manila Folder tab */
.folder-visual.skin-folder::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 0;
    width: 38px;
    height: 8px;
    background: #f7dfaf;
    border-top: 1.5px solid #d4b882;
    border-left: 1.5px solid #d4b882;
    border-right: 1.5px solid #d4b882;
    border-radius: 5px 5px 0 0;
}

/* Jeans Pocket & Files skin */
.folder-visual.skin-pocket,
.folder-visual.skin-file {
    background: transparent;
    border: none;
    box-shadow: none;
}

/* Highlighted sticker label under object */
.folder-label-block {
    margin-top: 5px;
    padding: 4px 9px 5px;
    font-family: var(--font-serif);
    font-size: 0.72rem;
    font-weight: 400;
    color: var(--text-primary);
    text-align: center;
    border: 1.5px solid #a855f7;
    border-radius: 999px;
    background: #f7e8ff;
    max-width: 112px;
    min-width: 54px;
    box-sizing: border-box;
    word-break: break-word;
    box-shadow: none;
    transform: none;
    transition: transform var(--t);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.board-canvas.edit-active .item-folder:hover .folder-label-block {
    transform: scale(1.03);
}

/* Container hover highlight on drag-over ingestion */
.item-folder.drag-over-receive .folder-visual {
    box-shadow: 0 0 0 3px #7c3aed, 0 8px 20px rgba(124, 58, 237, 0.4);
    outline: 3px solid #7c3aed;
    outline-offset: 2px;
    transform: scale(1.08);
}

.item-folder.drag-over-receive .folder-visual img {
    opacity: 0.85;
}

.item-folder.drag-over-receive .folder-label-block {
    transform: rotate(0deg) scale(1.04);
    background-color: rgba(124, 58, 237, 0.15) !important;
    border-left: 3px solid #7c3aed !important;
    color: #7c3aed;
}

/* Folder capacity colors */
#folder-detail-count {
    transition: color var(--t);
}

#folder-detail-count.warning {
    color: #f97316 !important;
    font-weight: 400;
}

#folder-detail-count.danger {
    color: #ef4444 !important;
    font-weight: 400;
}

/* Folder Notification Count Badge */
.folder-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ffffff;
    color: #4b5563;
    font-family: var(--font-hand), monospace;
    font-size: 0.58rem;
    font-weight: 400;
    min-width: 26px;
    height: 14px;
    border-radius: 7px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 1px solid #d1d5db;
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    z-index: 5;
    white-space: nowrap;
}

.peek-card-music {
    box-sizing: border-box;
}

.peek-music-row {
    display: flex;
    align-items: center;
    gap: 3px;
    width: 100%;
    min-width: 0;
}

.peek-music-play {
    color: #9aa4b2;
    font-size: 0.42rem;
    line-height: 1;
}

.peek-music-wave {
    display: flex;
    align-items: center;
    gap: 1px;
    flex: 1;
    min-width: 0;
}

.peek-music-wave i {
    display: block;
    width: 2px;
    border-radius: 999px;
    background: #9aa4b2;
}

.peek-music-wave i:nth-child(1) { height: 7px; }
.peek-music-wave i:nth-child(2) { height: 12px; }
.peek-music-wave i:nth-child(3) { height: 16px; background: #69b6e8; }
.peek-music-wave i:nth-child(4) { height: 10px; }
.peek-music-wave i:nth-child(5) { height: 6px; }

.peek-music-title {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: #1f2937;
    font-family: var(--font-sans);
    font-size: 0.34rem;
    font-weight: 700;
    line-height: 1.05;
}

/* View items toggle button styling */
.btn-toggle-contents:hover {
    background-color: #bae6fd !important;
}

.btn-toggle-contents:active {
    transform: scale(0.96);
}

.collection-title-row {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
}

.collection-title-row h2 {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#folder-rename-input {
    width: min(210px, 55vw);
    min-width: 0;
    padding: 4px 7px;
    border: 1.5px solid var(--border-light);
    border-radius: 6px;
    color: var(--text-primary);
    background: white;
    font-family: var(--font-hand);
    font-size: 1.05rem;
    outline: none;
}

#folder-rename-input:focus {
    border-color: #c084fc;
}

.collection-title-edit-btn {
    width: 25px;
    height: 25px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border: none;
    border-radius: 6px;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
}

.collection-title-edit-btn:hover {
    background: var(--bg-soft);
    color: var(--text-primary);
}

/* Folder Details items style (Horizontal Slider Carousel) */
.folder-contents-list {
    display: flex;
    flex-direction: row;
    gap: 14px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 12px 4px 16px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    box-sizing: border-box;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none;  /* IE and Edge */
}

.folder-contents-list::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

/* Folder Organizer (Add from Board) Styling */
.folder-organizer-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 150px;
    overflow-y: auto;
    padding-right: 4px;
    scrollbar-width: thin;
}

.organizer-item-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f9fafb;
    padding: 8px 12px;
    border-radius: 10px;
    border: 1px solid #f3f4f6;
    transition: transform var(--t), box-shadow var(--t), background var(--t);
}

.organizer-item-row:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.04);
    background: #f3f4f6;
}

.organizer-item-preview {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.organizer-preview-badge {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    flex-shrink: 0;
    overflow: hidden;
}

.organizer-preview-text {
    font-size: 0.8rem;
    font-family: 'DM Sans', sans-serif;
    color: #374151;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
}

.organizer-item-add-btn {
    background: #7c3aed;
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'DM Sans', sans-serif;
    transition: background var(--t), transform var(--t);
}

.organizer-item-add-btn:hover {
    background: #6d28d9;
    transform: scale(1.05);
}

.organizer-item-add-btn:active {
    transform: scale(0.98);
}

.folder-contents-list > p {
    width: 100%;
    text-align: center;
    flex-shrink: 0;
    margin: 12px 0;
}

.folder-contents-list .inner-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 12px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    gap: 6px;
    position: relative;
    width: 160px;
    height: 140px;
    flex: 0 0 160px;
    box-sizing: border-box;
    scroll-snap-align: start;
    overflow: hidden;
}

.folder-contents-list .inner-card.inner-message {
    border-left: 4px solid #7c3aed;
}

.folder-contents-list .inner-card.inner-picture {
    border-left: 4px solid #3b82f6;
    padding: 6px;
}

.folder-contents-list .inner-card.inner-picture img {
    width: 100%;
    height: 95px;
    object-fit: cover;
    border-radius: 6px;
}

.folder-contents-list .inner-card .inner-text {
    font-size: 0.72rem;
    color: #334155;
    line-height: 1.35;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.folder-contents-list .inner-card .inner-meta {
    font-size: 0.6rem;
    color: #64748b;
    margin-top: auto;
    display: flex;
    justify-content: space-between;
}

.folder-contents-list .inner-card .btn-delete-inner {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    color: #ef4444;
    cursor: pointer;
    font-size: 0.75rem;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: background-color var(--t);
}

.folder-contents-list .inner-card .btn-delete-inner:hover {
    background: #fee2e2;
}

/* =====================
   TIMELINE SCREEN
   ===================== */
.timeline-list {
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.timeline-card {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tl-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tl-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    flex-shrink: 0;
    overflow: hidden;
}

.tl-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tl-meta {
    font-size: 0.9rem;
    color: var(--text-primary);
    line-height: 1.3;
}

.tl-meta strong {
    font-weight: 700;
}

.tl-body {
    border-radius: var(--r-card);
    overflow: hidden;
    background: var(--bg-soft);
}

/* Tape in timeline */
.tl-tape-wrap {
    padding: 28px 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 110px;
}

.tape-strip-tl {
    background-image: url('Component/masking tape.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-color: transparent;
    padding: 20px 40px;
    transform: rotate(-1.5deg);
    font-family: var(--font-hand);
    font-size: 1.2rem;
    line-height: 1.2;
    max-width: 88%;
    text-align: center;
    box-shadow: none;
    border: none;
}

/* CD in timeline */
.tl-cd-wrap {
    padding: 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: white;
    min-height: 220px;
}

.cd-large-tl {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: conic-gradient(from 0deg,
            #ff9de2 0deg, #c77dff 60deg, #4895ef 120deg,
            #4cc9f0 180deg, #80ffdb 240deg, #ffbe0b 300deg, #ff9de2 360deg);
    box-shadow: 4px 8px 24px rgba(0, 0, 0, 0.2);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cd-large-tl::before {
    content: '';
    position: absolute;
    width: 26%;
    height: 26%;
    border-radius: 50%;
    background: radial-gradient(circle, #f5f5f5, #e2e2e2);
    box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.2);
}

.cd-tl-overlay {
    position: absolute;
    font-family: var(--font-hand);
    font-size: 0.78rem;
    text-align: center;
    font-weight: 700;
    color: rgba(0, 0, 0, 0.55);
    z-index: 2;
    padding: 0 8px;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.5);
}

/* QA in timeline */
.tl-qa-wrap {
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.qa-question {
    background: var(--sticky-pink);
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    display: inline-block;
}

.qa-answer {
    background: var(--sticky-pink);
    padding: 12px 14px;
    border-radius: 8px;
    font-family: var(--font-hand);
    font-size: 1.1rem;
    line-height: 1.5;
}

.qa-answer.default { background: #fafafa; }
.qa-answer.pink { background: var(--sticky-pink); }
.qa-answer.yellow { background: var(--sticky-yellow); }
.qa-answer.blue { background: var(--sticky-blue); }
.qa-answer.green { background: var(--sticky-green); }
.qa-answer.lavender { background: #dfccfb; }

.tl-folder-wrap {
    min-height: 190px;
    padding: 28px 18px;
    background: #fffafc;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.tl-folder-preview {
    width: 150px;
    height: 110px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tl-folder-preview.skin-pocket {
    width: 126px;
    height: 126px;
}

.tl-folder-preview img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.12));
}

.tl-folder-label {
    max-width: 86%;
    padding: 8px 14px;
    border: 1.5px solid #a855f7;
    border-radius: 999px;
    background: #f7e8ff;
    color: var(--text-primary);
    font-family: var(--font-serif);
    font-size: 1.15rem;
    line-height: 1.1;
    text-align: center;
}

/* Sticky in timeline */
.tl-sticky-wrap {
    padding: 24px;
    display: flex;
    justify-content: center;
}

.sticky-in-tl {
    position: relative;
    width: 140px;
    height: 140px;
    padding: 18px 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-family: var(--font-hand);
    font-size: 1.15rem;
    line-height: 1.4;
    box-shadow: none;
    border: none;
    transform: rotate(-1deg);
    background: transparent;
    z-index: 1;
}

.sticky-in-tl::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url('Component/sticky note.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    z-index: -1;
    transition: filter var(--t);
}

.sticky-in-tl.yellow::before {
    filter: none;
}

.sticky-in-tl.pink::before {
    filter: hue-rotate(-65deg) saturate(1.4) brightness(1.05);
}

.sticky-in-tl.blue::before {
    filter: hue-rotate(145deg) saturate(1.4) brightness(1.05);
}

/* =====================
   EXPLORE SCREEN
   ===================== */
.explore-search-wrap {
    position: sticky;
    top: 0;
    z-index: 8;
    padding: 14px 18px 8px;
    background: rgba(255, 255, 255, 0.96);
}

.explore-search-input {
    width: 100%;
    height: 44px;
    padding: 0 16px;
    border: 1.5px solid #d8d1df;
    border-radius: 999px;
    background: #f7f4fa;
    color: var(--text-primary);
    font-family: var(--font-ui);
    font-size: 0.9rem;
    font-weight: 600;
    outline: none;
}

.explore-search-input::placeholder {
    color: var(--text-muted);
    font-weight: 500;
}

.explore-search-input:focus {
    border-color: #c9a8ff;
    background: #fbf8ff;
    box-shadow: 0 0 0 4px rgba(201, 168, 255, 0.16);
}

.explore-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    padding: 10px 18px 120px;
}

.explore-card {
    min-width: 0;
    border-radius: var(--r-card);
    overflow: hidden;
    cursor: pointer;
    border: 1.5px solid #cfc7d8;
    transition: transform var(--t);
    background: #f1edf6;
    box-shadow: 0 4px 0 #e3ddea, 0 10px 20px rgba(84, 70, 100, 0.10);
}

.explore-card:hover {
    transform: scale(0.97);
}

.explore-card:active {
    transform: scale(0.95);
}

.explore-card-board {
    width: 100%;
    aspect-ratio: 1368 / 2160;
    position: relative;
    background-image: url('Component/board.png');
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.explore-card-footer {
    padding: 9px 10px 11px;
    background: #f1edf6;
    border-top: 1.5px solid #cfc7d8;
}

.explore-card-user {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: center;
}

/* Mini items inside explore card */
.explore-mini-sticky {
    position: absolute;
    border-radius: 2px;
    font-family: var(--font-hand);
    font-size: 0.5rem;
    padding: 4px 5px;
    box-shadow: 1px 2px 5px rgba(0, 0, 0, 0.12);
}

.explore-mini-cd {
    position: absolute;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, #ff9de2, #c77dff, #4895ef, #80ffdb, #ff9de2);
}

.explore-mini-cd::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 28%;
    height: 28%;
    border-radius: 50%;
    background: #eee;
    transform: translate(-50%, -50%);
}

.explore-mini-tape {
    position: absolute;
    background: var(--tape);
    height: 10px;
    border-radius: 2px;
    font-size: 0;
}

.explore-decor {
    position: absolute;
    font-size: 0.9rem;
    line-height: 1;
}

.page-empty-state {
    width: min(100%, 520px);
    margin: 42px auto;
    padding: 26px 22px;
    border: 1.5px dashed #d7d7d7;
    border-radius: 18px;
    background: #fafafa;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-align: center;
    font-family: var(--font-sans);
}

.explore-grid .page-empty-state {
    display: flex;
    break-inside: avoid;
}

#screen-inbox .inbox-empty-state {
    width: calc(100% - 36px);
    margin: 32px 18px;
}

.page-empty-state strong {
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 700;
}

.page-empty-state span {
    max-width: 280px;
    font-size: 0.88rem;
    line-height: 1.35;
}

.page-empty-state.is-loading {
    border-color: transparent;
    background: transparent;
    box-shadow: none;
}

.explore-loading-circle {
    width: 34px;
    height: 34px;
    border: 3px solid #efe1ff;
    border-top-color: #a855f7;
    border-right-color: #f9a8d4;
    border-radius: 50%;
    animation: exploreSpin 0.8s linear infinite;
}

@keyframes exploreSpin {
    to {
        transform: rotate(360deg);
    }
}

/* =====================
   INBOX SCREEN
   ===================== */
.inbox-list {
    padding: 8px 0;
}

.anon-insight-bar {
    width: calc(100% - 36px);
    margin: 6px 18px 10px;
    padding: 12px 14px;
    border: 1.5px solid #dac8e8;
    border-radius: 16px;
    background: #f6eefc;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    text-align: left;
    font-family: var(--font-ui);
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(124, 58, 237, 0.08);
}

.anon-insight-bar-copy {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.anon-insight-bar-copy strong {
    font-size: 0.96rem;
    line-height: 1.15;
}

.anon-insight-bar-copy small {
    color: #6f6778;
    font-size: 0.76rem;
    line-height: 1.25;
}

.anon-insight-bar-arrow {
    flex-shrink: 0;
    color: #7c3aed;
    font-family: Arial, sans-serif;
    font-size: 1.6rem;
    line-height: 1;
}

.inbox-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    cursor: pointer;
    transition: background var(--t);
}

.inbox-row:hover {
    background: #fafafa;
}

.inbox-row:active {
    background: #f5f5f5;
}

.inbox-row+.inbox-row {
    border-top: 1px dashed var(--dashed-line);
}

.inbox-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #d9d9d9;
    flex-shrink: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.inbox-avatar.anon-sender {
    border: 1.5px solid #dac8e8;
    background: #f6eefc;
    color: #7c3aed;
    font-family: var(--font-hand);
    font-size: 1.45rem;
    font-weight: 700;
    line-height: 1;
    box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.65);
}

.inbox-avatar.public-sender,
.inbox-sender-link {
    cursor: pointer;
}

.inbox-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.inbox-row-text {
    flex: 1;
    font-size: 0.9rem;
    line-height: 1.35;
}

.inbox-row-text strong {
    font-weight: 700;
}

.inbox-sender-link {
    appearance: none;
    border: 0;
    padding: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 700;
    text-align: left;
}

.inbox-sender-link:active {
    color: #7c3aed;
}

.inbox-row-time {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: block;
    margin-top: 2px;
}

.inbox-insight-btn {
    width: fit-content;
    margin-top: 7px;
    padding: 5px 9px;
    border: 1.5px solid #dac8e8;
    border-radius: 999px;
    background: #f6eefc;
    color: #7c3aed;
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 800;
    line-height: 1;
    cursor: pointer;
}

.inbox-insight-btn:active {
    transform: scale(0.97);
}

.inbox-thumb {
    width: 42px;
    height: 42px;
    border-radius: 6px;
    flex-shrink: 0;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eeeeee;
}

/* Thumbnails */
.th-tape {
    width: 100%;
    height: 100%;
    background: var(--tape);
    background-image: repeating-linear-gradient(90deg, transparent 0, transparent 4px,
            rgba(160, 140, 100, 0.1) 4px, rgba(160, 140, 100, 0.1) 5px);
    position: relative;
}

.th-tape::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 70%;
    height: 30%;
    background: rgba(180, 155, 110, 0.25);
    border-radius: 1px;
    transform: translate(-50%, -50%);
}

.th-sticky {
    width: 28px;
    height: 28px;
    border-radius: 3px;
    box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.1);
}

.th-sticky.yellow {
    background: var(--sticky-yellow);
}

.th-sticky.pink {
    background: var(--sticky-pink);
}

.th-sticky.blue {
    background: var(--sticky-blue);
}

.th-cd {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, #ff9de2, #c77dff, #4895ef, #4cc9f0, #ff9de2);
    position: relative;
}

.th-cd::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30%;
    height: 30%;
    border-radius: 50%;
    background: #eeeeee;
    transform: translate(-50%, -50%);
}

.th-phone {
    font-size: 1.5rem;
    line-height: 1;
}

/* =====================
   BOTTOM SHEETS
   ===================== */
.bottom-sheet {
    position: absolute;
    inset: 0;
    z-index: 200;
    pointer-events: none;
}

.bottom-sheet:not(.hidden) {
    pointer-events: auto;
}

.sheet-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.38);
    animation: bdIn 0.2s ease;
}

@keyframes bdIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.sheet-panel {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-radius: 24px 24px 0 0;
    padding: 14px 22px 36px;
    max-height: 85vh;
    overflow-y: auto;
    animation: sheetUp 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

@keyframes sheetUp {
    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0);
    }
}

.sheet-drag-handle {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: #e0e0e0;
    margin: 0 auto 18px;
}

/* Sheet nav tabs */
.sheet-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
}

.sheet-tab {
    position: relative;
    flex: 1;
    padding: 8px 6px;
    border-radius: var(--r-pill);
    border: 1.5px solid var(--border-light);
    background: white;
    font-family: var(--font-ui);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--t);
}

.sheet-tab.active {
    background: #f6edff;
    border-color: #e4c7ff;
    font-weight: 600;
}

.premium-tab-label .premium-star-badge {
    right: 4px;
    bottom: 4px;
    width: 13px;
    height: 13px;
    font-size: 0.66rem;
    -webkit-text-stroke: 0;
}

/* Panes */
.tab-pane {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.note-type-row {
    display: flex;
    gap: 10px;
}

.note-type-btn {
    position: relative;
    flex: 1;
    border: 1.5px solid var(--border-light);
    border-radius: var(--r-card);
    background: white;
    padding: 10px 8px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    font-family: var(--font-ui);
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all var(--t);
}

.note-type-btn .premium-star-badge {
    right: 5px;
    bottom: 5px;
    width: 13px;
    height: 13px;
    font-size: 0.66rem;
    -webkit-text-stroke: 0;
}

.note-type-btn.active {
    border-color: #c084fc;
    background: #faf5ff;
    color: var(--text-primary);
}

.nt-preview {
    border-radius: 3px;
}

.plain-preview-mini {
    width: 34px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    font-family: var(--font-ui);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1;
}

.tape-preview-mini {
    width: 50px;
    height: 12px;
    background: var(--tape);
    background-image: repeating-linear-gradient(90deg, transparent 0, transparent 4px,
            rgba(160, 140, 100, 0.1) 4px, rgba(160, 140, 100, 0.1) 5px);
}

.sticky-preview-mini {
    width: 22px;
    height: 22px;
    background: var(--sticky-yellow);
    box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1);
}

.sticky-color-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.color-swatch {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid transparent;
    cursor: pointer;
    transition: transform var(--t), border-color var(--t);
}

.color-swatch.active {
    border-color: #7c3aed;
    transform: scale(1.15);
}

.note-textarea {
    width: 100%;
    height: 100%;
    margin: 0 auto;
    resize: none;
    outline: none;
    border: none;
    font-family: var(--font-hand);
    font-size: 1rem;
    line-height: 1.4;
    transition: color var(--t);
    background: transparent;
    overflow: hidden;
}

.note-textarea:focus {
    outline: none;
    border: none;
}

.note-preview-card {
    position: relative;
    z-index: 1;
    transition: all var(--t);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Plain text preview card */
.note-preview-card.preview-plain {
    width: 180px;
    min-height: 110px;
    background: transparent;
    transform: none;
}

.note-preview-card.preview-plain .note-textarea {
    min-height: 110px;
    padding: 12px 10px;
    color: #000;
    font-family: var(--font-ui);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.3;
}

/* Tape preview card */
.note-preview-card.preview-tape {
    width: 180px;
    height: 90px;
    background-image: url('Component/masking tape.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    transform: rotate(-2deg);
}

.note-preview-card.preview-tape .note-textarea {
    padding: 21px 26px;
    font-size: 0.95rem;
    line-height: 1.2;
}

/* Sticky preview card */
.note-preview-card.preview-sticky {
    width: 140px;
    height: 140px;
    transform: rotate(-1.5deg);
}

.note-preview-card.preview-sticky::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url('Component/sticky note.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    z-index: -1;
    transition: filter var(--t);
}

.note-preview-card.preview-sticky.yellow::before {
    filter: none;
}

.note-preview-card.preview-sticky.pink::before {
    filter: hue-rotate(-65deg) saturate(1.4) brightness(1.05);
}

.note-preview-card.preview-sticky.blue::before {
    filter: hue-rotate(145deg) saturate(1.4) brightness(1.05);
}

.note-preview-card.preview-sticky .note-textarea {
    padding: 18px 15px;
    font-size: 1rem;
}

.editor-controls-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: -4px;
    padding: 0 4px;
}

.alignment-row {
    display: flex;
    gap: 4px;
    background: var(--bg-soft);
    padding: 3px;
    border-radius: 8px;
    border: 1px solid var(--border-light);
}

.align-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--t);
}

.align-btn:hover {
    color: var(--text-primary);
    background: rgba(0, 0, 0, 0.05);
}

.align-btn.active {
    color: #7c3aed;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.char-counter {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.item-note-text {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    max-height: 100%;
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    display: inline-block;
    text-align: inherit;
    overflow: hidden;
}

.pane-hint {
    font-size: 0.88rem;
    color: var(--text-muted);
}

.question-pane-hint {
    margin: 0 0 -2px;
}

.question-input-wrap {
    position: relative;
    width: 100%;
}

#question-input {
    width: 100%;
    min-height: 104px;
    margin: 0;
    padding: 12px 14px 28px;
    box-sizing: border-box;
    border: 1.5px solid var(--border-light);
    border-radius: 12px;
    font-family: var(--font-ui);
    resize: none;
    outline: none;
}

#question-input:focus {
    border-color: #c084fc;
}

.question-char-counter {
    position: absolute;
    right: 12px;
    bottom: 9px;
    color: #888888;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    line-height: 1;
    pointer-events: none;
}

.sheet-input {
    width: 100%;
    padding: 13px 14px;
    border: 1.5px solid var(--border-light);
    border-radius: var(--r-card);
    font-family: var(--font-ui);
    font-size: 0.95rem;
    outline: none;
    transition: border-color var(--t);
}

.sheet-input:focus {
    border-color: #c084fc;
}

.sheet-input.input-attention {
    animation: inputAttention 0.75s ease;
}

@keyframes inputAttention {
    0%, 100% {
        border-color: var(--border-light);
        box-shadow: none;
    }
    35%, 70% {
        border-color: #a855f7;
        box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.16);
    }
}

.song-preview-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border-radius: var(--r-card);
    border: 1.5px solid var(--border-light);
    background: #fafafa;
}

.song-cd-sm {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: conic-gradient(from 0deg, #ff9de2, #c77dff, #4895ef, #ff9de2);
    position: relative;
    flex-shrink: 0;
}

.song-cd-sm::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 30%;
    height: 30%;
    border-radius: 50%;
    background: #eee;
    transform: translate(-50%, -50%);
}

.song-preview-title {
    font-size: 0.9rem;
    font-weight: 600;
}

.song-preview-artist {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Voice record */
.record-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: 20px 0;
}

.btn-record-circle {
    width: 78px;
    height: 78px;
    border-radius: 50%;
    background: var(--action-pill-bg);
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: transform var(--t), box-shadow var(--t), background var(--t);
}

.btn-record-circle:hover {
    transform: scale(1.04);
}

.btn-record-circle.recording {
    background: #ffd5d5;
    box-shadow: 0 0 0 8px rgba(232, 69, 60, 0.14);
    animation: recordPulse 1s ease-in-out infinite;
}

@keyframes recordPulse {

    0%,
    100% {
        box-shadow: 0 0 0 8px rgba(232, 69, 60, 0.14);
    }

    50% {
        box-shadow: 0 0 0 14px rgba(232, 69, 60, 0.06);
    }
}

.record-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #e8453c;
}

.record-label-text {
    font-size: 0.65rem;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.2;
}

.record-timer {
    font-size: 1.2rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    letter-spacing: 1px;
}

.voice-preview {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.waveform-player {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 14px;
    background: #f8f8f8;
    border-radius: var(--r-card);
}

.play-circle-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--text-primary);
    color: white;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform var(--t);
}

.play-circle-btn:hover {
    transform: scale(1.08);
}

.waveform-bar-row {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 2px;
    height: 34px;
}

.waveform-bar-row span {
    flex: 1;
    min-width: 2px;
    background: #d0d0d0;
    border-radius: 2px;
    transition: background 0.1s;
}

.waveform-bar-row span.played {
    background: #c084fc;
}

.btn-rerecord {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.85rem;
    cursor: pointer;
    text-decoration: underline;
    align-self: center;
    font-family: var(--font-ui);
}

.btn-submit-sheet {
    width: 100%;
    padding: 14px;
    border-radius: var(--r-pill);
    background: var(--text-primary);
    color: white;
    border: none;
    font-family: var(--font-ui);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform var(--t), box-shadow var(--t);
}

.btn-submit-sheet:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-submit-sheet:active {
    transform: scale(0.98);
}

/* =====================
   INBOX DETAIL
   ===================== */
.inbox-detail-content {
    padding: 8px 0 20px;
    min-height: 140px;
}

.inbox-detail-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 16px;
    border-top: 1px solid #f0f0f0;
}

.btn-publish-action,
.btn-reply-action,
.btn-delete-action {
    width: 100%;
    padding: 13px;
    border-radius: var(--r-pill);
    border: none;
    font-family: var(--font-ui);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform var(--t);
}

.btn-publish-action {
    background: var(--text-primary);
    color: white;
}

.btn-reply-action {
    background: var(--nav-active);
    color: var(--text-primary);
}

.btn-delete-action {
    background: white;
    color: #e8453c;
    border: 1.5px solid #fecaca;
}

.btn-publish-action:hover,
.btn-reply-action:hover,
.btn-delete-action:hover {
    transform: translateY(-1px);
}

/* =====================
   TOAST
   ===================== */
.toast {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(26, 26, 26, 0.9);
    color: white;
    padding: 10px 22px;
    border-radius: var(--r-pill);
    font-size: 0.88rem;
    font-weight: 500;
    backdrop-filter: blur(8px);
    z-index: 999;
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
    white-space: nowrap;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.toast.premium-toast {
    width: min(330px, calc(100% - 36px));
    padding: 11px 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 1px solid rgba(192, 132, 252, 0.65);
    border-radius: 12px;
    background: rgba(31, 20, 43, 0.96);
    white-space: normal;
}

.premium-toast-star {
    flex: 0 0 auto;
    color: #d8b4fe;
    font-size: 1.05rem;
}

.toast.premium-toast strong,
.toast.premium-toast small {
    display: block;
    text-align: left;
}

.toast.premium-toast strong {
    font-size: 0.8rem;
    line-height: 1.2;
}

.toast.premium-toast small {
    margin-top: 2px;
    color: #ddd6fe;
    font-size: 0.7rem;
    line-height: 1.2;
}

/* =====================
   DECOR PREMIUM PAYWALL
   ===================== */
#modal-decor-paywall {
    position: fixed;
}

.decor-paywall-panel {
    position: absolute;
    bottom: 0;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: min(100%, 430px);
    max-width: calc(100vw - 24px);
    margin: 0 auto;
    padding: 12px 22px 20px;
    text-align: center;
    animation: decorPaywallUp 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

@keyframes decorPaywallUp {
    from {
        transform: translate(-50%, 100%);
    }

    to {
        transform: translate(-50%, 0);
    }
}

.decor-paywall-close {
    position: absolute;
    top: 13px;
    right: 16px;
    z-index: 2;
    width: 32px;
    height: 32px;
    padding: 0;
    border: none;
    background: transparent;
    color: #666666;
    font-family: Arial, sans-serif;
    font-size: 1.75rem;
    font-weight: 300;
    line-height: 30px;
    cursor: pointer;
}

.decor-paywall-panel h2 {
    margin: 0 38px 10px;
    color: var(--text-primary);
    font-family: var(--font-hand);
    font-size: clamp(1.35rem, 5.7vw, 1.7rem);
    font-weight: 400;
    letter-spacing: 0;
}

.decor-paywall-stage {
    width: 100%;
    max-width: 300px;
    margin: 0 auto 10px;
    padding: 8px;
    border: 1px solid #e9d5ff;
    border-radius: 12px;
    background: #faf7ff;
}

.decor-paywall-board {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 1px solid #eeeeee;
    border-radius: 8px;
    background-color: #ffffff;
    background-image: radial-gradient(#b9b9b9 1px, transparent 1px);
    background-size: 12px 12px;
}

.paywall-asset,
.paywall-note,
.paywall-player,
.paywall-folder,
.paywall-ring {
    position: absolute;
    opacity: 0;
    animation: paywallItemIn 5.5s ease-in-out infinite;
}

.paywall-ring {
    left: 42%;
    top: 28%;
    width: 25%;
    aspect-ratio: 1;
    padding: 4px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff9de2, #c77dff, #72efdd);
    animation-delay: 0.25s;
}

.paywall-ring img {
    width: 100%;
    height: 100%;
    display: block;
    border: 3px solid white;
    border-radius: 50%;
    object-fit: cover;
}

.paywall-sticker-one {
    left: 8%;
    top: 12%;
    width: 18%;
    animation-delay: 0.75s;
}

.paywall-sticker-two {
    right: 7%;
    top: 12%;
    width: 17%;
    animation-delay: 1.15s;
}

.paywall-note {
    left: 8%;
    bottom: 12%;
    padding: 6px 9px;
    background: #ffd0e0;
    color: #111111;
    font-family: var(--font-hand);
    font-size: 0.66rem;
    transform: rotate(-3deg);
    animation-delay: 1.55s;
}

.paywall-player {
    right: 8%;
    bottom: 8%;
    width: 25%;
    aspect-ratio: 1;
    animation-delay: 1.95s;
}

.paywall-player-base {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.paywall-vinyl {
    position: absolute;
    left: 15%;
    top: 21%;
    width: 58%;
    height: 58%;
    object-fit: contain;
    animation: rotateVinyl 4s linear infinite;
}

.paywall-folder {
    left: 35%;
    bottom: 5%;
    width: 23%;
    animation-delay: 2.35s;
}

@keyframes paywallItemIn {
    0%, 7% {
        opacity: 0;
        transform: translateY(9px) scale(0.82) rotate(-3deg);
    }
    14%, 84% {
        opacity: 1;
        transform: translateY(0) scale(1) rotate(0deg);
    }
    94%, 100% {
        opacity: 0;
        transform: translateY(-3px) scale(0.96);
    }
}

.decor-paywall-price {
    margin-bottom: 13px;
}

.decor-paywall-price strong,
.decor-paywall-price span {
    display: block;
}

.decor-paywall-price strong {
    color: var(--text-primary);
    font-family: var(--font-ui);
    font-size: 1.05rem;
}

.decor-paywall-price span {
    margin-top: 2px;
    color: var(--text-muted);
    font-size: 0.72rem;
}

.decor-paywall-primary {
    width: 100%;
    border: none;
    font-family: var(--font-ui);
    cursor: pointer;
}

.decor-paywall-primary {
    padding: 12px 16px;
    border-radius: 12px;
    background: #171717;
    color: white;
    font-size: 0.92rem;
    font-weight: 700;
}

.decor-paywall-secondary {
    width: 100%;
    margin-top: 9px;
    padding: 11px 16px;
    border: 1.5px solid #dac8e8;
    border-radius: 12px;
    background: #f6eefc;
    color: #7c3aed;
    font-family: var(--font-ui);
    font-size: 0.86rem;
    font-weight: 800;
    cursor: pointer;
}

.decor-pricing-options {
    max-width: 300px;
    margin-bottom: 10px;
}

/* =====================
   ANON INSIGHT PAYWALL
   ===================== */
.anon-insight-panel {
    position: absolute;
    bottom: 0;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: min(100%, 430px);
    max-width: calc(100vw - 24px);
    margin: 0 auto;
    padding: 18px 22px 24px;
    text-align: center;
    animation: decorPaywallUp 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

.anon-insight-peek {
    position: relative;
    width: 100%;
    max-width: 320px;
    height: 130px;
    margin: 0 auto 14px;
    border: 1px solid #e9d5ff;
    border-radius: 18px;
    background:
        radial-gradient(circle at 24% 28%, rgba(255, 208, 224, 0.9), transparent 24%),
        radial-gradient(circle at 74% 34%, rgba(198, 246, 213, 0.9), transparent 22%),
        #faf7ff;
    overflow: hidden;
}

.anon-insight-peek .peek-card {
    position: absolute;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 150px;
    padding: 8px 10px;
    border: 1px solid rgba(124, 58, 237, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: #2b2b2b;
    font-family: var(--font-ui);
    font-size: 0.76rem;
    font-weight: 700;
    box-shadow: 0 8px 18px rgba(17, 17, 17, 0.08);
    animation: anonPeekFloat 4.8s ease-in-out infinite;
}

.anon-insight-peek .peek-card-one {
    left: 15px;
    top: 18px;
}

.anon-insight-peek .peek-card-two {
    right: 14px;
    top: 52px;
    animation-delay: 0.4s;
}

.anon-insight-peek .peek-card-three {
    left: 42px;
    bottom: 16px;
    animation-delay: 0.8s;
}

@keyframes anonPeekFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.anon-insight-panel h2 {
    margin: 0 30px 6px;
    color: var(--text-primary);
    font-family: var(--font-hand);
    font-size: clamp(1.05rem, 5vw, 1.42rem);
    font-weight: 400;
    letter-spacing: 0;
    white-space: nowrap;
}

.anon-insight-copy {
    max-width: 310px;
    margin: 0 auto 14px;
    color: #625c67;
    font-size: 0.88rem;
    line-height: 1.35;
}

.anon-pricing-options {
    width: 100%;
    max-width: 320px;
    margin: 0 auto 12px;
    display: grid;
    gap: 7px;
}

.anon-price-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #eee6f6;
    border-radius: 14px;
    background: #ffffff;
    color: var(--text-primary);
    text-align: left;
    font-family: var(--font-ui);
    font-size: 0.84rem;
    cursor: pointer;
}

.anon-price-row.is-selected {
    border-color: #c084fc;
    background: #f4e8ff;
    box-shadow: 0 5px 14px rgba(124, 58, 237, 0.1);
}

.anon-price-row span,
.anon-price-row strong {
    line-height: 1.2;
}

.anon-price-row strong {
    text-align: right;
}

.anon-price-row em {
    color: #7c3aed;
    font-size: 0.7rem;
    font-style: normal;
    font-weight: 800;
    white-space: nowrap;
}

.anon-price-row:not(.is-best-value) em {
    color: #8b8290;
    font-weight: 700;
}

.anon-insight-note {
    max-width: 300px;
    margin: 0 auto 12px;
    color: #8b8290;
    font-size: 0.75rem;
    line-height: 1.35;
}

.anon-details-panel {
    position: absolute;
    bottom: 0;
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: min(100%, 430px);
    max-width: calc(100vw - 24px);
    margin: 0 auto;
    padding: 20px 22px 24px;
    text-align: center;
    animation: decorPaywallUp 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

.anon-details-panel h2 {
    margin: 2px 36px 6px;
    color: var(--text-primary);
    font-family: var(--font-hand);
    font-size: 1.7rem;
    font-weight: 400;
    letter-spacing: 0;
}

.anon-details-list {
    width: 100%;
    max-width: 330px;
    margin: 14px auto 12px;
    display: grid;
    gap: 9px;
}

.anon-details-list div {
    display: grid;
    grid-template-columns: 34px 1fr;
    grid-template-rows: auto auto;
    column-gap: 10px;
    padding: 12px 13px;
    border: 1px solid #eee6f6;
    border-radius: 16px;
    background: #ffffff;
    text-align: left;
    box-shadow: 0 7px 18px rgba(17, 17, 17, 0.05);
}

.anon-details-list span {
    grid-row: 1 / 3;
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #f4e8ff;
}

.anon-details-list strong {
    color: var(--text-primary);
    font-family: var(--font-ui);
    font-size: 0.9rem;
    line-height: 1.2;
}

.anon-details-list small {
    margin-top: 2px;
    color: #8b8290;
    font-family: var(--font-ui);
    font-size: 0.72rem;
    line-height: 1.2;
}

/* =====================
   LIVE NOTE PREVIEW
   ===================== */
.note-preview-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px;
    background: #FAF8F5;
    border-radius: var(--r-card);
    border: 1.5px dashed var(--dashed-line);
    min-height: 140px;
    margin-bottom: 12px;
    width: 100%;
}

.note-preview-area {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.note-preview-area .board-item {
    position: relative !important;
    left: auto !important;
    top: auto !important;
    transform: rotate(-2deg) !important;
    margin: 0 auto !important;
    box-shadow: 2px 6px 18px rgba(0, 0, 0, 0.12) !important;
    cursor: default !important;
}

/* =====================
   DECORATION / EDIT MODE
   ===================== */
.decor-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
    max-height: 200px;
    overflow-y: auto;
    padding: 10px;
    border-radius: var(--r-card);
    background: #fdfdfd;
    border: 1.5px solid var(--border-light);
}

.decor-item-btn {
    position: relative;
    font-size: 1.8rem;
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    border-radius: var(--r-sm);
    transition: transform var(--t), background var(--t);
}

.decor-item-btn .premium-star-badge,
.skin-option-btn .premium-star-badge,
.premium-upload-area .premium-star-badge {
    right: 3px;
    bottom: 3px;
    width: 15px;
    height: 15px;
    font-size: 0.78rem;
    -webkit-text-stroke: 0.4px #7c3aed;
}

.premium-upload-area {
    position: relative;
}

.decor-item-btn:hover {
    transform: scale(1.18);
    background: #f5f5f5;
}

.decor-item-btn.selected-decor {
    background: #f0e6ff !important;
    border: 2px solid #7c3aed !important;
    transform: scale(1.1);
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.15);
}

.decor-item-btn:active {
    transform: scale(0.95);
}

/* Delete buttons on board items in edit mode */
.board-item .btn-item-delete {
    display: none;
    position: absolute;
    top: -10px;
    right: -10px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ef4444;
    color: white;
    border: 1.5px solid white;
    font-size: 14px;
    line-height: 1;
    font-weight: 700;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
    z-index: 999;
    padding: 0;
}

.board-item .btn-item-delete:hover {
    background: #dc2626;
    transform: scale(1.1);
}



/* Rotate buttons on board items in edit mode */
.board-item .btn-item-rotate {
    display: none;
    position: absolute;
    bottom: -10px;
    right: -10px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #7c3aed;
    color: white;
    border: 1.5px solid white;
    font-size: 14px;
    line-height: 1;
    font-weight: 700;
    align-items: center;
    justify-content: center;
    cursor: alias;
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
    z-index: 999;
    padding: 0;
}

.board-item .btn-item-rotate:hover {
    background: #6d28d9;
    transform: scale(1.1);
}

/* Customization & Edit Mode styles */
.board-canvas.edit-active .board-item {
    cursor: grab;
    user-select: none;
    -webkit-touch-callout: none;
}

#screen-board.edit-active,
#screen-board.edit-active * {
    user-select: none !important;
    -webkit-user-select: none !important;
    -webkit-touch-callout: none !important;
}

.board-canvas .board-item a {
    pointer-events: none;
}

.board-canvas.edit-active .board-item a,
.board-canvas.edit-active .board-item button:not(.btn-item-delete):not(.btn-item-rotate):not(.btn-item-manage) {
    pointer-events: none;
    cursor: default;
}

.board-canvas.edit-active .board-item:active {
    cursor: grabbing;
}

.board-item.active-edit {
    outline: 2px dashed #7c3aed;
    outline-offset: 6px;
    border-radius: 4px;
}

@keyframes itemIdentifyPulse {
    0% {
        outline-color: #7c3aed;
        outline-width: 2px;
        transform: scale(var(--final-scale, 1)) rotate(calc(var(--final-rot-deg, 0) * 1deg));
        box-shadow: 0 0 0 rgba(124, 58, 237, 0);
    }
    30% {
        outline-color: #ff3366;
        outline-width: 6px;
        transform: scale(calc(var(--final-scale, 1) * 1.08)) rotate(calc(var(--final-rot-deg, 0) * 1deg));
        box-shadow: 0 0 20px rgba(255, 51, 102, 0.4);
    }
    100% {
        outline-color: #7c3aed;
        outline-width: 2px;
        transform: scale(var(--final-scale, 1)) rotate(calc(var(--final-rot-deg, 0) * 1deg));
        box-shadow: 0 0 0 rgba(124, 58, 237, 0);
    }
}

.item-identify-pulse {
    animation: itemIdentifyPulse 0.6s ease-in-out !important;
}

/* Manage folder button on board items in edit mode */
.board-item .btn-item-manage {
    display: none;
    position: absolute;
    top: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: #7c3aed;
    color: white;
    border: 1.5px solid white;
    border-radius: 12px;
    padding: 4px 10px;
    font-family: 'DM Sans', sans-serif;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    gap: 4px;
    transition: transform 0.2s ease, background-color 0.2s ease;
}

.board-item .btn-item-manage:hover {
    background: #6d28d9;
    transform: translateX(-50%) scale(1.05);
}

.board-item .btn-item-manage:active {
    transform: translateX(-50%) scale(0.95);
}

.board-canvas.edit-active .board-item.active-edit .btn-item-delete,
.board-canvas.edit-active .board-item.active-edit .btn-item-rotate,
.board-canvas.edit-active .board-item.active-edit .btn-item-manage {
    display: flex !important;
}

@keyframes itemWiggle {
    0% {
        translate: -1px -1px;
    }
    100% {
        translate: 1px 1px;
    }
}

/* Image-based decorations */
.item-decor.has-image {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.item-decor.has-image.is-large-decor {
    width: 120px;
    height: 120px;
}

.explore-decor.has-image {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* =============================================
   VERTICAL LAYER PALETTE (Photoshop-style)
   ============================================= */
.layer-palette {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2000;
    transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1), transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: auto;
}

.layer-palette.hidden {
    opacity: 0;
    transform: translateY(-50%) scale(0.8);
    pointer-events: none;
    display: block !important;
}

.layer-palette-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: rgba(22, 22, 28, 0.82);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    padding: 8px 6px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
    max-height: 330px;
    overflow-y: auto;
    overflow-x: hidden;
    width: 48px;
    align-items: center;
    scrollbar-width: none; /* Hide scrollbars */
    -ms-overflow-style: none;
}

.layer-palette-list::-webkit-scrollbar {
    display: none;
    width: 0 !important;
    height: 0 !important;
}

.layer-item-card {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    cursor: grab;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s, transform 0.12s cubic-bezier(0.2, 0.8, 0.2, 1), background 0.2s;
    user-select: none;
    touch-action: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    flex-shrink: 0;
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Prevent native image drag previews and context menu conflicts on mobile/desktop children */
.layer-item-card * {
    pointer-events: none !important;
    -webkit-user-drag: none !important;
    user-drag: none !important;
    user-select: none !important;
    -webkit-user-select: none !important;
}

.layer-item-card:hover {
    background: rgba(255, 255, 255, 0.18);
    transform: scale(1.06);
}

.layer-item-card.active-layer {
    border-color: #a78bfa; /* Lavender purple highlight for active element */
    background: rgba(167, 139, 250, 0.2);
    box-shadow: 0 0 10px rgba(167, 139, 250, 0.45);
}

.layer-item-card.dragging-layer {
    opacity: 0.5;
    cursor: grabbing;
    transform: scale(1.12);
    z-index: 10;
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.25);
}

/* Dynamic Thumbnail mini previews */
.mini-decor {
    font-size: 1.15rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mini-decor img {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.mini-sticky {
    width: 20px;
    height: 20px;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.18);
}

.mini-sticky.yellow { background: #FFF9A0; }
.mini-sticky.pink   { background: #FFD0E0; }
.mini-sticky.blue   { background: #C8EEFF; }

.mini-tape {
    width: 24px;
    height: 7px;
    background: #f3f0e8;
    border: 1px solid #d4cebe;
    transform: rotate(-12deg);
    box-shadow: 0 1px 1px rgba(0,0,0,0.12);
}

.mini-cd {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: radial-gradient(circle, #2d2d2d 35%, #0f0f12 36%);
    border: 1px solid #1a1a24;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mini-cd::after {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #ffffff;
}

.mini-voice {
    display: flex;
    align-items: center;
    gap: 1px;
}

.mini-voice span {
    width: 2px;
    background: #a78bfa;
    border-radius: 0.8px;
}

.mini-voice span:nth-child(1) { height: 8px; }
.mini-voice span:nth-child(2) { height: 14px; }
.mini-voice span:nth-child(3) { height: 11px; }
.mini-voice span:nth-child(4) { height: 7px; }

/* Dynamic Thumbnail mini preview for picture */
.mini-picture {
    width: 22px;
    height: 22px;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.18);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eee;
}

.mini-picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Mini Folder/Pocket Preview */
.mini-folder {
    width: 14px;
    height: 14px;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.18);
    background: #fdf6e2;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mini-folder img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Mini Q&A Card Preview */
.mini-qa {
    width: 14px;
    height: 14px;
    border-radius: 2px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.18);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mini-qa span {
    width: 100%;
    height: 50%;
}

.mini-qa span.pink { background: var(--sticky-pink); }
.mini-qa span.blue { background: var(--sticky-blue); }
.mini-qa span.yellow { background: var(--sticky-yellow); }
.mini-qa span.green { background: var(--sticky-green); }
.mini-qa span.lavender { background: #dfccfb; }
.mini-qa span.purple { background: #e5beff; }
.mini-qa span.default { background: #fafafa; }
.mini-qa span.white { background: #ffffff; }

/* Polaroid Picture board item */
.item-board-picture {
    width: 120px;
    height: 140px;
    background: #ffffff;
    padding: 6px 6px 8px;
    border-radius: 4px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15), 0 2px 5px rgba(0,0,0,0.06);
    border: 1px solid rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    cursor: grab;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.item-board-picture img {
    width: 100%;
    flex: 1;
    min-height: 0;
    object-fit: cover;
    border-radius: 2px;
    pointer-events: none;
}

.picture-title-label {
    font-family: var(--font-hand), monospace;
    font-size: 0.72rem;
    font-weight: normal;
    text-align: center;
    color: #2c2c2c;
    margin-top: 4px;
    white-space: normal;
    word-break: break-word;
    line-height: 1.2;
}

.popout-picture-caption {
    position: absolute;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.7);
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
    max-width: 80%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: 'DM Sans', sans-serif;
    z-index: 10;
}

/* User Tagging Pills */
.tag-user-pill {
    padding: 6px 12px;
    border-radius: 20px;
    border: 1px solid #e5e7eb;
    font-size: 0.72rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'DM Sans', sans-serif;
    transition: transform var(--t), background var(--t), border-color var(--t), color var(--t);
    outline: none;
}

.tag-user-pill:hover {
    transform: scale(1.05);
}

.tag-user-pill.active {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

/* ===== FLOATING PREVIEW POPOUT (NON-EDIT) ===== */
.popout-overlay {
    position: absolute;
    inset: 0;
    z-index: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.popout-overlay:not(.hidden) {
    opacity: 1;
    pointer-events: auto;
}

.popout-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.22);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.popout-card {
    position: relative;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.18);
    padding: 18px 18px 22px 18px;
    width: min(calc(100vw - 64px), 340px);
    height: min(78vh, 620px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    z-index: 501;
    transform: scale(0.8);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    user-select: none;
    -webkit-user-select: none;
}

.popout-overlay:not(.hidden) .popout-card {
    transform: scale(1);
}

.popout-close-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.05);
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 0.95rem;
    color: #666;
    transition: background 0.2s, transform 0.2s;
    z-index: 502;
}

.popout-close-btn:hover {
    background: rgba(0, 0, 0, 0.1);
    transform: scale(1.1);
}

.popout-slider-container {
    width: 100%;
    flex: 1;
    min-height: 0;
    margin-top: 18px;
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background: #f9fafb;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}

.popout-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transform: translateX(100%);
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
}

.popout-slide.active {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
}

.popout-slide.prev {
    transform: translateX(-100%);
}

.popout-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    pointer-events: none;
}

.popout-note-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
    font-size: 1.15rem;
    font-family: var(--font-hand), monospace;
    line-height: 1.4;
    box-sizing: border-box;
    overflow-y: auto;
}

.popout-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    height: 12px;
}

.popout-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e5e7eb;
    border: none;
    cursor: pointer;
    padding: 0;
    transition: background-color 0.25s ease, transform 0.25s ease;
}

.popout-dot:hover {
    transform: scale(1.2);
}

.popout-dot.active {
    background-color: #7c3aed;
    transform: scale(1.25);
}

/* Newly added item jump animation */
@keyframes itemJumpIn {
    0% {
        opacity: 0;
        transform: translate(0px, 300px) scale(0.2) rotate(calc((var(--final-rot-deg, 0) - 15) * 1deg));
    }
    65% {
        transform: translate(0px, -30px) scale(calc(var(--final-scale, 1) * 1.25)) rotate(calc((var(--final-rot-deg, 0) + 10) * 1deg));
    }
    85% {
        transform: translate(0px, 10px) scale(calc(var(--final-scale, 1) * 0.95)) rotate(calc((var(--final-rot-deg, 0) - 3) * 1deg));
    }
    100% {
        opacity: 1;
        transform: translate(0px, 0px) scale(var(--final-scale, 1)) rotate(calc(var(--final-rot-deg, 0) * 1deg));
    }
}

.item-jump-animation {
    animation: itemJumpIn 0.75s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

/* Unified controls container below the board canvas wrap */
.board-controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 0 16px;
    flex-shrink: 0;
    width: var(--wall-frame-width);
    max-width: calc(100% - 32px);
    margin: 0 auto;
    box-sizing: border-box;
    z-index: 99999;
}

/* Grouped Floating Actions container centered */
.board-actions-group {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

#screen-board.edit-active .board-actions-group {
    width: 100%;
    justify-content: space-between;
}

body.visitor-wall-mode .board-controls-bar,
body.visitor-wall-mode #layer-palette,
body.visitor-wall-mode #btn-open-decor,
body.visitor-wall-mode #btn-open-folder,
.visitor-submit-mode .sheet-tab[data-tab="decor"],
.visitor-submit-mode .sheet-tab[data-tab="folder"],
.visitor-submit-mode #pane-decor,
.visitor-submit-mode #pane-folder {
    display: none !important;
}

body.visitor-wall-mode #board-profile-circle {
    cursor: default;
}

body.visitor-wall-mode .top-nav {
    display: none;
}

body.visitor-wall-mode .board-dock {
    display: flex;
    top: 74px;
    right: max(18px, calc((100% - var(--wall-frame-width)) / 2 + 10px));
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
}

body.visitor-wall-mode .board-cta-label {
    display: none;
}

body.visitor-wall-mode .action-row {
    padding: 0;
    gap: 14px;
}

.visitor-submit-mode .sheet-tabs {
    grid-template-columns: repeat(2, 1fr);
}

.visitor-auth-panel {
    padding: 14px 22px 26px;
    text-align: center;
}

.visitor-auth-panel h2 {
    margin: 8px 0 8px;
    color: var(--text-primary);
    font-family: var(--font-serif);
    font-size: 1.85rem;
    font-weight: 400;
    line-height: 1;
}

.visitor-auth-panel p {
    max-width: 300px;
    margin: 0 auto 18px;
    color: var(--text-secondary);
    font-family: var(--font-ui);
    font-size: 0.86rem;
    line-height: 1.35;
}

.visitor-google-signin {
    margin-top: 0;
}

.visitor-auth-cancel {
    width: 100%;
    margin-top: 10px;
    padding: 10px 16px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-ui);
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
}

/* Profile picture expand overlay specific styles */
.profile-expand-content {
    position: relative;
    z-index: 501;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: scale(0.3);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}

.popout-overlay:not(.hidden) .profile-expand-content {
    transform: scale(1);
    opacity: 1;
}

.profile-expand-circle-ring {
    width: 260px;
    height: 260px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 5px solid transparent;
    background: white;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.profile-expand-circle-ring img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Item expand overlay specific styles */
.item-expand-content-wrap {
    position: relative;
    z-index: 501;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: scale(0.3);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}

.popout-overlay:not(.hidden) .item-expand-content-wrap {
    transform: scale(1);
    opacity: 1;
}

.expanded-item-card {
    width: min(88vw, 420px);
    max-height: min(78vh, 640px);
    box-sizing: border-box;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 22px 48px rgba(0, 0, 0, 0.28);
    overflow: hidden;
}

.expanded-picture-card {
    width: min(calc(100vw - 64px), 340px);
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

.expanded-picture-card img {
    width: 100%;
    max-height: calc(min(78vh, 640px) - 68px);
    object-fit: contain;
    border-radius: 8px;
    display: block;
    background: #f8fafc;
}

.expanded-picture-caption {
    width: 100%;
    text-align: center;
    font-family: var(--font-hand), monospace;
    font-size: clamp(1rem, 3.5vw, 1.35rem);
    line-height: 1.1;
    color: #111827;
    overflow-wrap: anywhere;
}

.expanded-qa-card {
    width: min(calc(100vw - 64px), 340px);
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: clamp(12px, 3vh, 20px);
    background: #fdfbf7;
}

.expanded-qa-question,
.expanded-qa-answer {
    box-sizing: border-box;
    width: 100%;
    max-height: calc((min(78vh, 640px) - 72px) / 2);
    overflow: hidden;
    border-radius: 10px;
    padding: clamp(12px, 3vw, 18px);
    font-family: var(--font-serif), serif;
    line-height: 1.22;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.expanded-qa-question {
    align-self: flex-start;
    font-size: clamp(1.05rem, 4.5vw, 1.55rem);
    font-weight: 700;
    color: #374151;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.expanded-qa-answer {
    align-self: flex-end;
    font-size: clamp(1.1rem, 4.8vw, 1.7rem);
    color: #111827;
    border: 1.5px dashed #cbd5e1;
}

.expanded-qa-question.pink { background: var(--sticky-pink); }
.expanded-qa-question.yellow { background: var(--sticky-yellow); }
.expanded-qa-question.blue { background: var(--sticky-blue); }
.expanded-qa-question.green { background: var(--sticky-green); }
.expanded-qa-question.lavender { background: #dfccfb; }
.expanded-qa-answer.default { background: #ffffff; }
.expanded-qa-answer.pink { background: var(--sticky-pink); border-color: #ffb8d2; }
.expanded-qa-answer.yellow { background: var(--sticky-yellow); border-color: #fff280; }
.expanded-qa-answer.blue { background: var(--sticky-blue); border-color: #a3e0ff; }
.expanded-qa-answer.green { background: var(--sticky-green); border-color: #adffaa; }
.expanded-qa-answer.lavender { background: #dfccfb; border-color: #ccb0ff; }

.expanded-music-card {
    width: min(88vw, 360px);
    max-height: min(78vh, 620px);
    padding: 18px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.expanded-music-card .item-cd-wrap,
.expanded-music-card .item-music-note {
    transform: none !important;
    width: 100%;
    max-width: 300px;
    padding: 0 20px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.expanded-music-card .item-vinyl-player {
    width: min(58vw, 190px);
    height: min(58vw, 190px);
    margin: 0 auto;
    display: block;
}

.expanded-music-card .item-cd-song-label {
    width: 100% !important;
    max-width: 260px !important;
    white-space: normal !important;
    align-items: center !important;
    box-sizing: border-box;
}

.expanded-music-card .item-cd-song-title,
.expanded-music-card .item-cd-sender-note,
.expanded-music-card .item-cd-reply-bubble,
.expanded-music-card .music-note-title {
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    overflow-wrap: anywhere;
}

.expanded-music-card .item-cd-song-title {
    font-size: clamp(0.95rem, 4vw, 1.25rem) !important;
    text-align: center !important;
}

.expanded-music-card .item-cd-wrap a,
.expanded-music-card .item-music-note a {
    width: 100% !important;
    max-width: 220px !important;
    box-sizing: border-box;
    display: flex !important;
    justify-content: center;
    white-space: normal !important;
    text-align: center;
    line-height: 1.15;
}

.expanded-music-card .item-cd-wrap a span,
.popout-cd-content .item-cd-wrap a span {
    white-space: normal;
    overflow-wrap: anywhere;
}

.item-expand-content-wrap .board-item {
    position: relative !important;
    left: auto !important;
    top: auto !important;
    transform: none !important;
    pointer-events: auto !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3) !important;
}

.item-expand-content-wrap .board-item.item-cd-wrap {
    box-shadow: none !important;
    background: transparent !important;
}

.item-expand-content-wrap .board-item.item-cd-wrap .item-vinyl-player {
    filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.35));
}

/* Authentication screen styles */
.auth-wrap {
    max-width: 360px;
}

.auth-preview {
    width: 100%;
    display: flex;
    justify-content: center;
    margin-bottom: 26px;
}

.auth-preview-board {
    position: relative;
    width: min(72vw, 250px);
    aspect-ratio: 4 / 5;
    border: 1.5px solid #d7cbe1;
    border-radius: 14px;
    background-color: #fffdfd;
    background-image: radial-gradient(#111827 0.7px, transparent 0.7px);
    background-size: 14px 14px;
    box-shadow: 0 18px 38px rgba(17, 24, 39, 0.12);
    overflow: hidden;
}

.auth-preview-dot {
    position: absolute;
    left: 20%;
    top: 14%;
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: conic-gradient(from 30deg, #f9a8d4, #a78bfa, #38bdf8, #86efac, #f9a8d4);
    box-shadow: 0 10px 18px rgba(124, 58, 237, 0.18);
}

.auth-preview-dot::after {
    content: '';
    position: absolute;
    inset: 19px;
    border-radius: 50%;
    background: #fffdfd;
}

.auth-preview-note {
    position: absolute;
    right: 11%;
    top: 28%;
    width: 100px;
    min-height: 78px;
    padding: 13px 10px;
    border-radius: 6px;
    background: #ffd1e2;
    color: #1f2937;
    font-family: var(--font-serif), serif;
    font-size: 1.05rem;
    line-height: 1.05;
    transform: rotate(4deg);
    box-shadow: 0 10px 18px rgba(244, 114, 182, 0.18);
}

.auth-preview-tape {
    position: absolute;
    left: 10%;
    bottom: 26%;
    width: 78%;
    height: 16px;
    border-radius: 4px;
    background: #e8dec9;
    transform: rotate(-2deg);
}

.auth-preview-disc {
    position: absolute;
    left: 17%;
    bottom: 12%;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: radial-gradient(circle at center, #fffdfd 0 18%, #111827 19% 28%, #c084fc 29% 48%, #38bdf8 49% 72%, #f9a8d4 73%);
}

.auth-preview-star {
    position: absolute;
    right: 16%;
    bottom: 13%;
    color: #8b5cf6;
    font-size: 1.5rem;
    text-shadow: 0 2px 8px rgba(139, 92, 246, 0.24);
}

.auth-title {
    margin-bottom: 10px;
    font-family: var(--font-serif), serif;
    font-size: 2.15rem;
    font-weight: 400;
    line-height: 1.05;
}

.auth-subtitle {
    max-width: 310px;
    margin: 0 auto 24px;
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.45;
}

.auth-primary-signin {
    margin-top: 0;
}

.auth-footnote {
    max-width: 300px;
    margin: 4px auto 0;
    color: #8a8a8a;
    font-family: var(--font-ui);
    font-size: 0.74rem;
    line-height: 1.45;
}

.btn-google-signin {
    width: 100%;
    height: 48px;
    border-radius: 12px;
    border: 1.5px solid #dadce0;
    background-color: #ffffff;
    color: #3c4043;
    font-family: 'DM Sans', -apple-system, sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 2px 0 rgba(60,64,67,0.3), 0 1px 3px 1px rgba(60,64,67,0.15);
    margin-bottom: 16px;
    outline: none;
}

.btn-google-signin:hover {
    background-color: #f8f9fa;
    border-color: #d2e3fc;
    box-shadow: 0 1px 3px 0 rgba(60,64,67,0.3), 0 4px 8px 3px rgba(60,64,67,0.15);
}

.btn-google-signin:active {
    background-color: #eeeeee;
    box-shadow: 0 1px 2px 0 rgba(60,64,67,0.3);
}

.google-logo {
    flex-shrink: 0;
}

/* Auth Separator */
.auth-separator {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 16px 0 20px;
    color: var(--text-muted);
    font-family: var(--font-ui);
    font-size: 0.8rem;
}

.auth-separator::before,
.auth-separator::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--border-light);
}

.auth-separator:not(:empty)::before {
    margin-right: .75em;
}

.auth-separator:not(:empty)::after {
    margin-left: .75em;
}

/* Spinner inside button */
.btn-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #ffffff;
    animation: btn-spin 0.8s linear infinite;
    display: inline-block;
}

.btn-google-signin .btn-spinner {
    border: 2px solid rgba(60, 64, 67, 0.3);
    border-top-color: #3c4043;
}

@keyframes btn-spin {
    to {
        transform: rotate(360deg);
    }
}

/* Spotify Autocomplete Search & Vinyl Album Artwork */
.song-search-wrap {
    position: relative;
    width: 100%;
}

.song-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 100;
    margin-top: 4px;
    max-height: 240px;
    overflow-y: auto;
}

.song-search-results.hidden {
    display: none;
}

.song-search-item {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    cursor: pointer;
    border: none;
    border-bottom: 1px solid #f1f5f9;
    background: transparent;
    width: 100%;
    text-align: left;
    transition: background-color 0.2s ease;
}

.song-search-item:last-child {
    border-bottom: none;
}

.song-search-item:hover {
    background-color: #f5f3ff; /* Very soft lavender */
}

.song-search-art {
    width: 38px;
    height: 38px;
    border-radius: 6px;
    object-fit: cover;
    margin-right: 12px;
    flex-shrink: 0;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.song-search-info {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.song-search-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}

.song-search-artist {
    font-size: 0.72rem;
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.song-search-status {
    padding: 14px;
    text-align: center;
    font-size: 0.8rem;
    color: #64748b;
    font-family: var(--font-ui);
}

/* Vinyl Album Art Center Spindle */
.vinyl-record-container {
    position: absolute;
    top: var(--vinyl-top);
    left: var(--vinyl-left);
    width: var(--vinyl-size);
    height: var(--vinyl-size);
    z-index: 2;
    pointer-events: none;
}

.item-vinyl-player.player-variant-1 {
    --vinyl-left: 0;
    --vinyl-top: 0;
    --vinyl-size: 100%;
}

.item-vinyl-player.player-variant-2 {
    --vinyl-left: 15%;
    --vinyl-top: 21%;
    --vinyl-size: 58%;
}

.item-vinyl-player.player-variant-3 {
    --vinyl-left: 16%;
    --vinyl-top: 22%;
    --vinyl-size: 53%;
}

.item-vinyl-player.player-variant-4 {
    --vinyl-left: 14%;
    --vinyl-top: 21%;
    --vinyl-size: 58%;
}

.vinyl-art-center {
    position: absolute;
    top: 37.25%;
    left: 37.25%;
    width: 25.5%;
    height: 25.5%;
    border-radius: 50%;
    object-fit: cover;
    z-index: 3;
    pointer-events: none;
    background-color: #121212;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.5);
}

/* Make sure the custom art inside preview card renders cleanly */
.song-preview-art-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

/* Q&A Item on Board */
.item-qa {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 220px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    border-radius: 8px;
}

.item-qa-question {
    color: var(--text-primary);
    padding: 6px 14px;
    font-family: var(--font-serif);
    font-size: 1.1rem;
    line-height: 1;
    z-index: 2;
    border-radius: 4px 4px 0 0;
}

/* Question tag colors */
.item-qa-question.pink { background: var(--sticky-pink); }
.item-qa-question.yellow { background: var(--sticky-yellow); }
.item-qa-question.blue { background: var(--sticky-blue); }
.item-qa-question.green { background: var(--sticky-green); }
.item-qa-question.lavender { background: #dfccfb; }

.item-qa-answer {
    color: var(--text-primary);
    width: 100%;
    box-sizing: border-box;
    padding: 20px 16px;
    margin-top: -1px;
    font-family: var(--font-serif);
    font-size: 1.8rem;
    line-height: 1.25;
    word-break: break-word;
    border-radius: 0 8px 8px 8px;
    text-align: left;
    border: 1px solid #eaeaea;
}

/* Answer box colors */
.item-qa-answer.default { background: #fafafa; }
.item-qa-answer.pink { background: var(--sticky-pink); border-color: #ffd3e2; }
.item-qa-answer.yellow { background: var(--sticky-yellow); border-color: #fff8a6; }
.item-qa-answer.blue { background: var(--sticky-blue); border-color: #c9efff; }
.item-qa-answer.green { background: var(--sticky-green); border-color: #d6ffd0; }
.item-qa-answer.lavender { background: #dfccfb; border-color: #e2ceff; }

/* Sub-tabs styling for decor */
#decor-subtabs .sheet-tab.active {
    background: #f6edff !important;
    border-color: #e4c7ff !important;
    color: #7c3aed !important;
    box-shadow: none !important;
}

/* Nested items inside folder contents list */
.folder-contents-list .inner-card.inner-qa {
    border-left: 4px solid #fbbf24;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.inner-qa-q {
    font-family: var(--font-hand), monospace;
    font-size: 0.62rem;
    font-weight: 700;
    padding: 2px 4px;
    border-radius: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #1e293b;
    align-self: flex-start;
    max-width: 100%;
    box-sizing: border-box;
}
.inner-qa-q.pink { background: var(--sticky-pink); }
.inner-qa-q.yellow { background: var(--sticky-yellow); }
.inner-qa-q.blue { background: var(--sticky-blue); }
.inner-qa-q.green { background: var(--sticky-green); }
.inner-qa-q.lavender { background: #dfccfb; }

.inner-qa-a {
    font-family: var(--font-hand), monospace;
    font-size: 0.68rem;
    line-height: 1.3;
    padding: 4px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    color: #334155;
    word-break: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.inner-qa-a.default { background: #ffffff; }
.inner-qa-a.pink { background: var(--sticky-pink); border-color: #ffb8d2; }
.inner-qa-a.yellow { background: var(--sticky-yellow); border-color: #fff280; }
.inner-qa-a.blue { background: var(--sticky-blue); border-color: #a3e0ff; }
.inner-qa-a.green { background: var(--sticky-green); border-color: #adffaa; }
.inner-qa-a.lavender { background: #dfccfb; border-color: #ccb0ff; }

.folder-contents-list .inner-card.inner-cd {
    border-left: 4px solid #10b981;
    align-items: center;
    justify-content: center;
    padding: 8px;
}
.inner-cd-disk {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: radial-gradient(circle, #334155 30%, #0f172a 70%);
    border: 3px solid #1e293b;
    position: relative;
    box-shadow: 0 3px 6px rgba(0,0,0,0.15);
    margin-bottom: 4px;
    flex-shrink: 0;
    animation: rotateVinyl 6s linear infinite;
    transform-origin: center center;
}
.inner-cd-disk::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 12px;
    background: #ffffff;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    border: 2px solid #0f172a;
}
.inner-cd-title {
    font-family: var(--font-hand), monospace;
    font-size: 0.68rem;
    color: #1e293b;
    font-weight: 600;
    text-align: center;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Popout Slideshow layouts */
.popout-qa-content {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 24px;
    box-sizing: border-box;
    gap: 10px;
    background: #fdfbf7;
    overflow-y: auto;
}
.popout-qa-q {
    font-family: var(--font-serif), serif;
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.2;
    color: #374151;
    padding: 8px 12px;
    border-radius: 6px;
    align-self: flex-start;
    max-width: 90%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    word-break: break-word;
}
.popout-qa-q.pink { background: var(--sticky-pink); }
.popout-qa-q.yellow { background: var(--sticky-yellow); }
.popout-qa-q.blue { background: var(--sticky-blue); }
.popout-qa-q.green { background: var(--sticky-green); }
.popout-qa-q.lavender { background: #dfccfb; }

.popout-qa-a {
    font-family: var(--font-serif), serif;
    font-size: 1.25rem;
    line-height: 1.3;
    color: #111827;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px dashed #cbd5e1;
    align-self: flex-end;
    max-width: 90%;
    width: auto;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
    word-break: break-word;
}
.popout-qa-a.default { background: #ffffff; }
.popout-qa-a.pink { background: var(--sticky-pink); border-color: #ffb8d2; }
.popout-qa-a.yellow { background: var(--sticky-yellow); border-color: #fff280; }
.popout-qa-a.blue { background: var(--sticky-blue); border-color: #a3e0ff; }
.popout-qa-a.green { background: var(--sticky-green); border-color: #adffaa; }
.popout-qa-a.lavender { background: #dfccfb; border-color: #ccb0ff; }

.popout-cd-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    padding: 20px;
    box-sizing: border-box;
    background: #f8fafc;
}
.popout-cd-disk-wrapper {
    flex-shrink: 0;
}
.popout-cd-disk {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: radial-gradient(circle, #334155 30%, #0f172a 70%);
    border: 5px solid #1e293b;
    position: relative;
    box-shadow: 0 8px 16px rgba(0,0,0,0.18);
    transform-origin: center center;
}
.popout-cd-disk::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 24px;
    height: 24px;
    background: #ffffff;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    border: 3px solid #0f172a;
    z-index: 2;
}
.popout-cd-art {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 1;
}
.popout-cd-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 1;
    align-items: flex-start;
}
.popout-cd-title {
    font-family: var(--font-hand), monospace;
    font-size: 1.1rem;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    text-align: left;
}
.popout-cd-artist {
    font-family: var(--font-hand), monospace;
    font-size: 0.85rem;
    color: #475569;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
    text-align: left;
}
.popout-cd-link {
    margin-top: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px 14px;
    background: #10b981;
    color: #ffffff;
    border-radius: 20px;
    font-family: var(--font-hand), monospace;
    font-size: 0.75rem;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.2);
    transition: background-color 0.2s, transform 0.2s;
}
.popout-cd-link:hover {
    transform: translateY(-1px);
    opacity: 0.9;
}

/* Optimize drag performance for layer cards containing image previews */
.layer-palette-list.dragging-active .layer-item-card {
    transition: none !important;
}

/* Floating folder popout slideshow navigation buttons */
.popout-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #475569;
    font-size: 1.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.2s ease;
    z-index: 505;
    padding: 0;
    line-height: 1;
}

.popout-nav-btn:hover {
    background: #f8fafc;
    color: #0f172a;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
    transform: translateY(-50%) scale(1.08);
}

.popout-nav-btn:active {
    transform: translateY(-50%) scale(0.95);
}

.popout-nav-btn.prev {
    left: -18px;
    padding-right: 2px; /* optical alignment for lsaquo */
}

.popout-nav-btn.next {
    right: -18px;
    padding-left: 2px; /* optical alignment for rsaquo */
}

.popout-nav-btn.hidden {
    display: none !important;
}

/* Style overrides for music (CD) items inside the folder preview slideshow */
.popout-cd-content .item-cd-wrap {
    width: 100%;
    max-width: 292px;
    padding: 0 20px;
    box-sizing: border-box;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.popout-cd-content .item-vinyl-player {
    width: min(38vw, 164px);
    height: min(38vw, 164px);
    margin: 0 auto;
    overflow: hidden;
    display: block;
}

.popout-cd-content .vinyl-record-container {
    overflow: hidden;
    border-radius: 50%;
}

.popout-cd-content .vinyl-art-center {
    top: 50%;
    left: 50%;
    width: 27%;
    height: 27%;
    transform: translate(-50%, -50%);
}

.popout-cd-content .item-cd-wrap .item-cd-song-label {
    width: 100% !important;
    max-width: 252px !important;
    margin-top: 12px !important;
    box-sizing: border-box;
    align-items: center !important;
}
.popout-cd-content .item-cd-wrap .item-cd-song-title {
    font-size: clamp(0.95rem, 3.6vw, 1.25rem) !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    max-width: 100% !important;
    text-align: center !important;
}
.popout-cd-content .item-cd-wrap .item-cd-song-artist {
    font-size: 0.72rem !important;
    color: #64748b !important;
    margin-top: 1px !important;
}
.popout-cd-content .item-cd-wrap a {
    font-size: 0.7rem !important;
    font-family: var(--font-hand), monospace !important;
    padding: 5px 12px !important;
    border-radius: 14px !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-top: 6px !important;
    width: 100% !important;
    max-width: 220px !important;
    box-sizing: border-box;
    text-decoration: none !important;
    font-weight: 700 !important;
    transition: all 0.2s ease !important;
}
.popout-cd-content .item-cd-wrap a:hover {
    transform: translateY(-1px) scale(1.05) !important;
    opacity: 0.95 !important;
}
.popout-cd-content .item-cd-wrap a svg {
    width: 10px !important;
    height: 10px !important;
    flex-shrink: 0;
}

/* Specific branding buttons inside popout */
.popout-cd-content .item-cd-wrap a[href*="spotify.com"] {
    background-color: #1ed760 !important;
    color: #ffffff !important;
    box-shadow: 0 3px 8px rgba(30, 215, 96, 0.25) !important;
}
.popout-cd-content .item-cd-wrap a[href*="spotify.com"] svg {
    fill: #ffffff !important;
}

.popout-cd-content .item-cd-wrap a[href*="youtube.com"],
.popout-cd-content .item-cd-wrap a[href*="youtu.be"] {
    background-color: #ef4444 !important;
    color: #ffffff !important;
    box-shadow: 0 3px 8px rgba(239, 68, 68, 0.25) !important;
}
.popout-cd-content .item-cd-wrap a[href*="youtube.com"] svg,
.popout-cd-content .item-cd-wrap a[href*="youtu.be"] svg {
    fill: #ffffff !important;
}

.popout-cd-content .item-cd-wrap a:not([href*="spotify.com"]):not([href*="youtube.com"]):not([href*="youtu.be"]) {
    background-color: #7c3aed !important;
    color: #ffffff !important;
    box-shadow: 0 3px 8px rgba(124, 58, 237, 0.25) !important;
}

/* Anonymous/public submission controls */
.sender-identity-toggle {
    display: flex;
    align-items: center;
    gap: 9px;
    width: 100%;
    margin: 0 0 14px;
    padding: 10px 12px;
    border: 1px solid #eeeeee;
    border-radius: 12px;
    background: #fafafa;
    color: var(--text-primary);
    font-family: var(--font-ui);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
}

.sender-identity-toggle input,
.settings-radio-row input {
    accent-color: #7c3aed;
}

.settings-section {
    width: 100%;
    margin-bottom: 18px;
    padding: 16px;
    border: 1px solid #eeeeee;
    border-radius: 16px;
    background: #fafafa;
    font-family: var(--font-ui);
    text-align: left;
}

.settings-section-title {
    margin: 0 0 5px;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 700;
}

.settings-section-copy {
    margin: 0 0 12px;
    color: var(--text-secondary);
    font-size: 0.78rem;
    line-height: 1.4;
}

.settings-radio-row {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 10px 0;
    color: var(--text-primary);
    font-size: 0.86rem;
    font-weight: 600;
    cursor: pointer;
}

.music-player-selector {
    width: 100%;
    margin: 0 0 14px;
    text-align: left;
}

#pane-music {
    gap: 10px;
}

.music-link-label {
    margin: 0 0 -4px;
    color: #666666;
    font-size: 0.75rem;
    font-weight: 600;
}

#song-url-input {
    margin: 0 0 2px;
}

.music-receiver-preview {
    width: 100%;
    padding: 12px;
    border: 1.5px solid var(--border-light);
    border-radius: 12px;
    background: #fafafa;
}

.music-receiver-preview-label {
    margin: 0 0 8px;
    color: var(--text-muted);
    font-family: var(--font-ui);
    font-size: 0.72rem;
    font-weight: 600;
}

.music-receiver-preview-content {
    min-height: 82px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.music-receiver-preview-content .item-cd-wrap,
.music-receiver-preview-content .item-music-note {
    position: relative;
    left: auto;
    top: auto;
    transform: none;
}

.music-receiver-preview-content .item-cd-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.music-note-field {
    width: 100%;
}

.music-note-field label {
    display: block;
    margin-bottom: 5px;
    color: #666666;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    font-weight: 600;
}

.music-note-input-wrap {
    position: relative;
}

#music-note-input {
    width: 100%;
    height: 42px;
    padding: 9px 52px 9px 12px;
    box-sizing: border-box;
    border: 1.5px solid var(--border-light);
    border-radius: 10px;
    color: var(--text-primary);
    background: white;
    font-family: var(--font-ui);
    font-size: 0.84rem;
    outline: none;
}

#music-note-input:focus {
    border-color: #c084fc;
}

.music-note-counter {
    position: absolute;
    right: 11px;
    top: 50%;
    color: #999999;
    font-family: var(--font-ui);
    font-size: 0.7rem;
    line-height: 1;
    transform: translateY(-50%);
    pointer-events: none;
}

.music-player-selector-label {
    margin: 0 0 8px;
    color: #666666;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    font-weight: 600;
}

.premium-choice-note {
    width: 100%;
    margin: 0 0 10px;
    padding: 9px 12px;
    border: 1.5px solid #dac8e8;
    border-radius: 12px;
    background: #f6eefc;
    color: #8b5cf6;
    font-family: var(--font-ui);
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1.3;
    text-align: center;
    box-sizing: border-box;
    animation: premiumNoteIn 180ms ease-out both;
}

.premium-choice-note-spaced {
    margin: 0 0 10px;
}

#pane-decor #decor-subtabs {
    margin-bottom: 8px !important;
}

@keyframes premiumNoteIn {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.music-player-options {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
}

.music-player-option {
    position: relative;
    aspect-ratio: 1;
    padding: 4px;
    border: 2px solid #eeeeee;
    border-radius: 12px;
    background: #ffffff;
    cursor: pointer;
    overflow: hidden;
}

.music-player-option.active {
    border-color: #7c3aed;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}

.music-player-option img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    pointer-events: none;
}

.music-player-thumb {
    position: relative;
    width: 100%;
    height: 100%;
    display: block;
    --vinyl-left: 18%;
    --vinyl-top: 19%;
    --vinyl-size: 54%;
}

.music-player-thumb-img {
    position: relative;
    z-index: 1;
}

.music-player-thumb.player-variant-1 {
    --vinyl-left: 0;
    --vinyl-top: 0;
    --vinyl-size: 100%;
}

.music-player-thumb.player-variant-2 {
    --vinyl-left: 15%;
    --vinyl-top: 21%;
    --vinyl-size: 58%;
}

.music-player-thumb.player-variant-3 {
    --vinyl-left: 16%;
    --vinyl-top: 22%;
    --vinyl-size: 53%;
}

.music-player-thumb.player-variant-4 {
    --vinyl-left: 14%;
    --vinyl-top: 21%;
    --vinyl-size: 58%;
}

.premium-star-badge {
    position: absolute;
    right: 5px;
    bottom: 5px;
    z-index: 6;
    width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(192, 132, 252, 0.38);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.88);
    color: #a855f7;
    -webkit-text-stroke: 0.6px #7c3aed;
    font-size: 1rem;
    line-height: 1;
    text-shadow:
        0 0 2px #ffffff,
        0 1px 2px rgba(109, 40, 217, 0.18);
    box-shadow: 0 1px 4px rgba(124, 58, 237, 0.18);
    pointer-events: none;
}

.basic-music-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    background: #ffffff;
}

.basic-music-option-play {
    color: #9ca3af;
    font-size: 0.74rem;
    line-height: 1;
}

.basic-music-option-bars {
    height: 24px;
    display: flex;
    align-items: center;
    gap: 1.5px;
}

.basic-music-option-bars span {
    width: 2px;
    border-radius: 999px;
    background: #9ca3af;
}

.basic-music-option-bars span.played {
    background: #38bdf8;
}

.item-cd-reply-bubble,
.item-cd-sender-note {
    display: block;
    width: max-content;
    max-width: 92px;
    margin-top: 6px;
    padding: 5px 8px 6px;
    border: 1px solid #e7e1ee;
    border-radius: 9px 9px 9px 3px;
    background: #ffffff;
    color: #4b4454;
    font-family: var(--font-sans);
    font-size: 0.55rem;
    font-weight: 600;
    line-height: 1.22;
    text-align: left;
    white-space: normal;
    overflow: visible;
    overflow-wrap: anywhere;
}

.item-cd-sender-note {
    margin-left: 0;
    margin-right: auto;
    border-color: #e4ddec;
    background: #ffffff;
    border-radius: 9px 9px 9px 3px;
}

.item-cd-reply-bubble {
    margin-left: auto;
    margin-right: 0;
    max-width: 82px;
    border-color: #c9b1eb;
    background: #f1e4ff;
    color: #5a2f91;
    border-radius: 9px 9px 3px 9px;
}

.item-music-note {
    width: 178px;
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 9px;
    border: 1px solid #ececec;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    font-family: var(--font-ui);
}

.music-note-play {
    width: 24px;
    height: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 50%;
    color: #9ca3af;
    text-decoration: none;
    font-size: 0.82rem;
    line-height: 1;
}

.music-note-body {
    min-width: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.music-note-waveform {
    height: 24px;
    display: flex;
    align-items: center;
    gap: 2px;
}

.music-note-waveform span {
    width: 2px;
    border-radius: 999px;
    background: #9ca3af;
}

.music-note-waveform span.played {
    background: #38bdf8;
}

.music-note-title {
    max-width: 100%;
    overflow: hidden;
    color: #1f2937;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 0.68rem;
    font-weight: 700;
    line-height: 1.1;
}

.music-note-spotify-link {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 999px;
    background: #1ed760;
    color: #ffffff;
    text-decoration: none;
    font-size: 0.62rem;
    font-weight: 800;
    line-height: 1;
    box-shadow: 0 2px 5px rgba(30, 215, 96, 0.22);
}

.music-note-spotify-link svg {
    flex-shrink: 0;
}

.detail-basic-music {
    width: min(100%, 260px);
    margin: 0 auto;
    min-height: 58px;
    padding: 10px 12px;
}

.detail-basic-music .music-note-title {
    font-size: 0.82rem;
}

.free-music-preview {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border: 1px solid #ececec;
    border-radius: 14px;
    background: #ffffff;
}

.free-music-preview .music-note-title {
    margin: 0;
    font-size: 0.78rem;
}

.tl-basic-music-wrap {
    min-height: 130px;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.collection-name-field {
    width: 100%;
    margin-bottom: 16px;
    text-align: left;
}

.collection-name-field label {
    display: block;
    margin-bottom: 6px;
    color: #666666;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    font-weight: 600;
}

#folder-name-input::placeholder {
    color: var(--text-muted);
    opacity: 1;
}

.inbox-cd-art-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: inherit;
    text-decoration: none;
}

a.inbox-cd-art-link {
    cursor: pointer;
}

/* Keep global hidden state last so component display rules cannot override it. */
.hidden {
    display: none !important;
}
