/* ============================================
   Rio Favela Tour — Dashboard Design System v7
   Clean · Modern · Apple-inspired
   ============================================ */

/* ── DESIGN TOKENS ── */
:root {
    --ds-radius-sm: 0.5rem;
    --ds-radius: 0.875rem;
    --ds-radius-lg: 1.25rem;
    --ds-radius-xl: 1.5rem;
    --ds-radius-2xl: 2rem;

    /* Tourist brand */
    --tourist-primary: #8B5CF6;
    --tourist-secondary: #a855f7;
    --tourist-gradient: linear-gradient(135deg, #8B5CF6, #a855f7, #ec4899);

    /* Cria brand */
    --cria-primary: #10B981;
    --cria-secondary: #059669;
    --cria-gradient: linear-gradient(135deg, #10B981, #059669, #0d9488);

    /* Admin brand */
    --admin-primary: #F59E0B;
    --admin-secondary: #d97706;
    --admin-gradient: linear-gradient(135deg, #F59E0B, #d97706, #ef4444);

    /* Spacing */
    --ds-gap-xs: 0.375rem;
    --ds-gap-sm: 0.625rem;
    --ds-gap: 0.875rem;
    --ds-gap-lg: 1.25rem;
    --ds-gap-xl: 1.75rem;
}

/* ── DASHBOARD LAYOUT ── */
.dashboard-page {
    max-width: 720px;
    margin: 0 auto;
    padding-bottom: 2rem;
}

/* ── HERO CARD ── */
.hero-card {
    position: relative;
    border-radius: var(--ds-radius-xl);
    overflow: hidden;
    margin-bottom: var(--ds-gap-lg);
    color: white;
}
.hero-card-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
}
.hero-card-bg::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.25);
}
.hero-card-content {
    position: relative;
    z-index: 1;
    padding: 1.5rem;
}
.hero-card-noise {
    position: absolute;
    inset: 0;
    z-index: 0;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ── METRIC GRID ── */
.metric-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--ds-gap-sm);
    margin-bottom: var(--ds-gap-lg);
}
.metric-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--ds-gap-sm);
    margin-bottom: var(--ds-gap-lg);
}
.metric-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-lg);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
}
.metric-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}
.metric-card-icon {
    width: 2rem;
    height: 2rem;
    border-radius: 0.625rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.25rem;
    flex-shrink: 0;
}
.metric-card-label {
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted-foreground);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.metric-card-value {
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    line-height: 1;
    color: var(--foreground);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.metric-card-value-sm {
    font-size: 1.125rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1;
    color: var(--foreground);
}
.metric-card-sub {
    font-size: 0.6875rem;
    color: var(--muted-foreground);
    margin-top: 0.125rem;
}

/* ── SECTION HEADER ── */
.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    padding: 0 0.125rem;
}
.section-title {
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--muted-foreground);
    display: flex;
    align-items: center;
    gap: 0.375rem;
}
.section-action {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--brand);
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-sans);
    padding: 0;
    -webkit-tap-highlight-color: transparent;
}

/* ── PANEL CARD ── */
.panel-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-lg);
    overflow: hidden;
    margin-bottom: var(--ds-gap);
}
.panel-card-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}
.panel-card-title {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--foreground);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.panel-card-body {
    padding: 1.25rem;
}

/* ── ACTION GRID ── */
.action-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.625rem;
    margin-bottom: var(--ds-gap);
}
.action-btn {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.625rem;
    padding: 1rem;
    background: var(--secondary);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-lg);
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--font-sans);
    color: var(--foreground);
    text-align: left;
    -webkit-tap-highlight-color: transparent;
}
.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}
.action-btn:active { transform: scale(0.97); }
.action-btn-icon {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.action-btn-label {
    font-size: 0.875rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}
.action-btn-desc {
    font-size: 0.6875rem;
    color: var(--muted-foreground);
    margin-top: -0.25rem;
}

/* ── LIST ITEM ── */
.list-item {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid var(--border);
    transition: background 0.15s;
}
.list-item:last-child { border-bottom: none; }
.list-item:hover { background: var(--secondary); }
.list-item-icon {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.625rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.list-item-content { flex: 1; min-width: 0; }
.list-item-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--foreground);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.list-item-sub {
    font-size: 0.75rem;
    color: var(--muted-foreground);
    margin-top: 0.125rem;
}
.list-item-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.25rem;
    flex-shrink: 0;
}

/* ── STATUS PILL ── */
.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.2rem 0.625rem;
    border-radius: 2rem;
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    white-space: nowrap;
}
.status-pill-green  { background: rgba(16,185,129,0.12); color: #10B981; border: 1px solid rgba(16,185,129,0.2); }
.status-pill-amber  { background: rgba(245,158,11,0.12); color: #F59E0B; border: 1px solid rgba(245,158,11,0.2); }
.status-pill-red    { background: rgba(239,68,68,0.1);   color: #ef4444; border: 1px solid rgba(239,68,68,0.2); }
.status-pill-purple { background: rgba(139,92,246,0.12); color: #8B5CF6; border: 1px solid rgba(139,92,246,0.2); }
.status-pill-gray   { background: var(--secondary); color: var(--muted-foreground); border: 1px solid var(--border); }

/* ── AVATAR ── */
.avatar {
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    color: white;
    overflow: hidden;
    flex-shrink: 0;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-lg { width: 5rem; height: 5rem; font-size: 1.5rem; }
.avatar-md { width: 3rem; height: 3rem; font-size: 0.875rem; }
.avatar-sm { width: 2.25rem; height: 2.25rem; font-size: 0.75rem; }
.avatar-xs { width: 1.75rem; height: 1.75rem; font-size: 0.625rem; }

/* ── PROFILE COVER ── */
.profile-cover {
    position: relative;
    height: 110px;
    border-radius: var(--ds-radius-xl) var(--ds-radius-xl) 0 0;
    overflow: hidden;
}
.profile-cover-gradient {
    position: absolute;
    inset: 0;
}
.profile-cover-avatar {
    position: absolute;
    bottom: -2.5rem;
    left: 1.5rem;
}
.profile-cover-actions {
    position: absolute;
    top: 0.875rem;
    right: 0.875rem;
    display: flex;
    gap: 0.5rem;
}

/* ── TOGGLE SWITCH ── */
.ds-toggle {
    position: relative;
    width: 3rem;
    height: 1.625rem;
    flex-shrink: 0;
}
.ds-toggle input { opacity: 0; width: 0; height: 0; }
.ds-toggle-slider {
    position: absolute;
    inset: 0;
    cursor: pointer;
    background: var(--border);
    border-radius: 2rem;
    transition: background 0.2s;
}
.ds-toggle-slider::before {
    content: '';
    position: absolute;
    width: 1.25rem;
    height: 1.25rem;
    left: 0.1875rem;
    top: 0.1875rem;
    background: white;
    border-radius: 50%;
    transition: transform 0.2s cubic-bezier(0.34,1.56,0.64,1);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}
.ds-toggle input:checked + .ds-toggle-slider { background: var(--cria-primary); }
.ds-toggle input:checked + .ds-toggle-slider::before { transform: translateX(1.375rem); }

/* ── SCHEDULE GRID ── */
.schedule-day-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 0.375rem;
    margin-bottom: 0.875rem;
}
.schedule-day-btn {
    aspect-ratio: 1;
    border-radius: 0.5rem;
    border: 1px solid var(--border);
    background: var(--secondary);
    font-size: 0.625rem;
    font-weight: 700;
    color: var(--muted-foreground);
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-sans);
    -webkit-tap-highlight-color: transparent;
}
.schedule-day-btn.active {
    background: var(--cria-primary);
    border-color: var(--cria-primary);
    color: white;
}
.schedule-time-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.375rem;
}
.schedule-time-btn {
    padding: 0.375rem 0.75rem;
    border-radius: 2rem;
    border: 1px solid var(--border);
    background: var(--secondary);
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--muted-foreground);
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font-sans);
    -webkit-tap-highlight-color: transparent;
}
.schedule-time-btn.active {
    background: var(--cria-primary);
    border-color: var(--cria-primary);
    color: white;
}

/* ── COUNTDOWN TIMER ── */
.countdown-card {
    background: linear-gradient(135deg, rgba(16,185,129,0.1), rgba(5,150,105,0.05));
    border: 1px solid rgba(16,185,129,0.2);
    border-radius: var(--ds-radius-lg);
    padding: 1.25rem;
    margin-bottom: var(--ds-gap);
    display: flex;
    align-items: center;
    gap: 1rem;
}
.countdown-timer {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}
.countdown-unit {
    text-align: center;
}
.countdown-value {
    font-size: 1.75rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    color: var(--cria-primary);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}
.countdown-label {
    font-size: 0.5rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted-foreground);
    margin-top: 0.25rem;
}
.countdown-sep {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--cria-primary);
    opacity: 0.5;
    margin-bottom: 0.5rem;
}

/* ── ADMIN TABLE ── */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
}
.admin-table th {
    text-align: left;
    padding: 0.625rem 0.875rem;
    font-size: 0.625rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted-foreground);
    border-bottom: 1px solid var(--border);
    white-space: nowrap;
}
.admin-table td {
    padding: 0.75rem 0.875rem;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: var(--secondary); }

/* ── PROGRESS BAR ── */
.ds-progress {
    height: 6px;
    background: var(--secondary);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 0.5rem;
}
.ds-progress-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.8s cubic-bezier(0.34,1.56,0.64,1);
}

/* ── ADMIN TABS ── */
.admin-tabs {
    display: flex;
    gap: 0;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1.5rem;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.admin-tabs::-webkit-scrollbar { display: none; }
.admin-tab-btn {
    padding: 0.75rem 1.125rem;
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--muted-foreground);
    cursor: pointer;
    transition: all 0.15s;
    font-family: var(--font-sans);
    white-space: nowrap;
    margin-bottom: -1px;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    -webkit-tap-highlight-color: transparent;
}
.admin-tab-btn:hover { color: var(--foreground); }
.admin-tab-btn.active {
    color: var(--foreground);
    border-bottom-color: var(--admin-primary);
    font-weight: 700;
}

/* ── STORAGE METER ── */
.storage-meter {
    background: var(--secondary);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-lg);
    padding: 1.25rem;
    margin-bottom: var(--ds-gap);
}
.storage-bar {
    height: 8px;
    background: var(--border);
    border-radius: 4px;
    overflow: hidden;
    margin: 0.75rem 0 0.5rem;
}
.storage-bar-fill {
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--cria-primary), var(--tourist-primary));
    transition: width 1s ease;
}

/* ── CRIA ONLINE INDICATOR ── */
.online-indicator {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 1rem 1.25rem;
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-lg);
    margin-bottom: var(--ds-gap);
}
.online-dot {
    width: 0.625rem;
    height: 0.625rem;
    border-radius: 50%;
    flex-shrink: 0;
}
.online-dot.online {
    background: var(--cria-primary);
    box-shadow: 0 0 0 3px rgba(16,185,129,0.2);
    animation: onlinePulse 2s ease-in-out infinite;
}
.online-dot.offline { background: var(--muted-foreground); }
@keyframes onlinePulse {
    0%, 100% { box-shadow: 0 0 0 3px rgba(16,185,129,0.2); }
    50% { box-shadow: 0 0 0 6px rgba(16,185,129,0.1); }
}

/* ── NEXT TOUR COUNTDOWN ── */
.next-tour-card {
    background: var(--card);
    border: 1px solid rgba(16,185,129,0.25);
    border-radius: var(--ds-radius-lg);
    padding: 1.25rem;
    margin-bottom: var(--ds-gap);
    position: relative;
    overflow: hidden;
}
.next-tour-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: var(--cria-gradient);
}

/* ── ADMIN SYSTEM STATUS ── */
.system-status-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.625rem;
    margin-bottom: var(--ds-gap);
}
.system-status-item {
    background: var(--secondary);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius);
    padding: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.system-status-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    flex-shrink: 0;
}
.system-status-dot.ok { background: var(--cria-primary); box-shadow: 0 0 6px rgba(16,185,129,0.5); }
.system-status-dot.warn { background: var(--admin-primary); box-shadow: 0 0 6px rgba(245,158,11,0.5); }
.system-status-dot.error { background: #ef4444; box-shadow: 0 0 6px rgba(239,68,68,0.5); }

/* ── RESPONSIVE ── */
@media (max-width: 479px) {
    .metric-grid { grid-template-columns: repeat(3, 1fr); gap: 0.375rem; }
    .metric-card { padding: 0.75rem; }
    .metric-card-value { font-size: 1.25rem; }
    .action-grid { grid-template-columns: repeat(2, 1fr); }
    .system-status-grid { grid-template-columns: 1fr; }
}
@media (min-width: 768px) {
    .dashboard-page { max-width: 860px; }
    .metric-grid { grid-template-columns: repeat(4, 1fr); }
    .action-grid { grid-template-columns: repeat(4, 1fr); }
    .system-status-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ── LIGHT THEME FIXES ── */
html.light .action-btn {
    background: #f8f9fa;
    border-color: rgba(0,0,0,0.08);
    color: #0f172a;
}
html.light .action-btn:hover {
    background: #f1f5f9;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
html.light .action-btn-label { color: #0f172a !important; }
html.light .action-btn-desc { color: rgba(0,0,0,0.5) !important; }
html.light .metric-card {
    background: #ffffff;
    border-color: rgba(0,0,0,0.08);
}
html.light .metric-card-value { color: #0f172a; }
html.light .metric-card-label { color: rgba(0,0,0,0.5); }
html.light .panel-card {
    background: #ffffff;
    border-color: rgba(0,0,0,0.08);
}
html.light .panel-card-header { border-bottom-color: rgba(0,0,0,0.06); }
html.light .panel-card-title { color: #0f172a; }
html.light .list-item { border-bottom-color: rgba(0,0,0,0.06); }
html.light .list-item:hover { background: #f8f9fa; }
html.light .list-item-title { color: #0f172a; }
html.light .list-item-sub { color: rgba(0,0,0,0.5); }
html.light .section-title { color: rgba(0,0,0,0.5); }
html.light .online-indicator {
    background: #ffffff;
    border-color: rgba(0,0,0,0.08);
}
html.light .next-tour-card {
    background: #ffffff;
    border-color: rgba(16,185,129,0.2);
}
html.light .system-status-item {
    background: #f8f9fa;
    border-color: rgba(0,0,0,0.06);
}
html.light .storage-meter {
    background: #f8f9fa;
    border-color: rgba(0,0,0,0.08);
}
html.light .admin-tab-btn { color: rgba(0,0,0,0.5); }
html.light .admin-tab-btn:hover { color: #0f172a; }
html.light .admin-tab-btn.active { color: #0f172a; border-bottom-color: var(--admin-primary); }
html.light .countdown-value { color: var(--cria-primary); }
html.light .countdown-sep { color: var(--cria-primary); }
html.light .countdown-label { color: rgba(0,0,0,0.4); }

/* ── SIDEBAR LOGOUT TEXT FIX ── */
.snav-logout span { color: #f87171 !important; }

/* ── VIBE TAGS TEXT FIX ── */
.vibe-tag { font-size: 0.75rem !important; }

/* ── STARS FIX ── */
.star-rating { color: #f59e0b; letter-spacing: 0.05em; }

/* ── MATCH SCORE FIX ── */
.match-score { font-size: 0.6875rem !important; }

/* ── MOBILE TOPBAR — hide page-header on mobile ── */
@media (max-width: 767px) {
    #page-header { display: none !important; }
}

/* ── CONTENT AREA — correct top padding ── */
@media (max-width: 767px) {
    #main-content {
        padding-top: calc(3.5rem + env(safe-area-inset-top, 0px) + 0.5rem) !important;
    }
}

/* ── EXPERIENCE CARD — fix image aspect ratio ── */
.experience-card-img {
    padding-top: 58% !important;
}

/* ── BOOK BUTTON — ensure visibility ── */
.book-btn-card {
    background: var(--brand) !important;
    color: white !important;
    border: none !important;
    padding: 0.5rem 1rem !important;
    border-radius: 2rem !important;
    font-weight: 700 !important;
    font-size: 0.8125rem !important;
    cursor: pointer !important;
    white-space: nowrap !important;
}
html.light .book-btn-card {
    background: var(--brand) !important;
    color: white !important;
}

/* ── PRICE TAG ── */
.price-tag {
    font-size: 1.25rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.04em !important;
    color: var(--foreground) !important;
}

/* ── FILTER CHIPS — active state ── */
.filter-chip.active {
    background: var(--brand) !important;
    color: white !important;
    border-color: var(--brand) !important;
}

/* ── BOTTOM NAV — correct icon color ── */
.bottom-nav-item.active i,
.bottom-nav-item.active svg {
    color: var(--brand) !important;
    stroke: var(--brand) !important;
}
html.light .bottom-nav-item { color: rgba(0,0,0,0.4); }
html.light .bottom-nav-item.active { color: var(--brand); }

/* ── GLASS CARD LIGHT ── */
html.light .glass-card {
    background: #ffffff;
    border-color: rgba(0,0,0,0.08);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

/* ── SEARCH INPUT LIGHT ── */
html.light .search-input {
    background: #f8f9fa;
    border-color: rgba(0,0,0,0.1);
    color: #0f172a;
}
html.light .search-input::placeholder { color: rgba(0,0,0,0.4); }

/* ── EXPERIENCE CARD LIGHT ── */
html.light .experience-card {
    background: #ffffff;
    border-color: rgba(0,0,0,0.08);
}
html.light .experience-card-title { color: #0f172a; }
html.light .experience-card-desc { color: rgba(0,0,0,0.55); }

/* ── LIKE BTN LIGHT ── */
html.light .like-btn {
    background: #f1f5f9;
    border-color: rgba(0,0,0,0.1);
    color: rgba(0,0,0,0.5);
}
html.light .like-btn.liked {
    background: rgba(239,68,68,0.08);
    border-color: rgba(239,68,68,0.2);
    color: #ef4444;
}

/* ── VIBE TAG LIGHT ── */
html.light .vibe-tag {
    background: #f1f5f9;
    border-color: rgba(0,0,0,0.1);
    color: rgba(0,0,0,0.6);
}
html.light .vibe-tag.active {
    background: rgba(139,92,246,0.1);
    border-color: rgba(139,92,246,0.25);
    color: var(--brand);
}

/* ── FILTER CHIP LIGHT ── */
html.light .filter-chip {
    background: #f1f5f9;
    border-color: rgba(0,0,0,0.1);
    color: rgba(0,0,0,0.6);
}
html.light .filter-chip:hover:not(.active) {
    background: #e2e8f0;
    color: #0f172a;
}

/* ── CRITICAL LIGHT THEME FIXES ── */

/* Force all text to be visible in light mode */
html.light #content-area,
html.light #content-area * {
    color: inherit;
}

html.light .action-btn {
    background: #f8f9fa !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: #0f172a !important;
}
html.light .action-btn-label {
    color: #0f172a !important;
    font-weight: 800 !important;
}
html.light .action-btn-desc {
    color: rgba(0,0,0,0.5) !important;
}
html.light .action-btn-icon {
    /* Keep colored backgrounds */
}

html.light .metric-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .metric-card-value { color: #0f172a !important; }
html.light .metric-card-label { color: rgba(0,0,0,0.5) !important; }
html.light .metric-card-sub { color: rgba(0,0,0,0.4) !important; }

html.light .panel-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .panel-card-header {
    border-bottom: 1px solid rgba(0,0,0,0.06) !important;
}
html.light .panel-card-title { color: #0f172a !important; }
html.light .panel-card-body { color: #0f172a !important; }

html.light .list-item { border-bottom: 1px solid rgba(0,0,0,0.06) !important; }
html.light .list-item:hover { background: #f8f9fa !important; }
html.light .list-item-title { color: #0f172a !important; }
html.light .list-item-sub { color: rgba(0,0,0,0.5) !important; }

html.light .section-title { color: rgba(0,0,0,0.5) !important; }
html.light .section-action { color: var(--brand) !important; }

html.light .online-indicator {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .online-indicator p { color: #0f172a !important; }
html.light .online-indicator .list-item-sub { color: rgba(0,0,0,0.5) !important; }

html.light .next-tour-card {
    background: #ffffff !important;
    border: 1px solid rgba(16,185,129,0.2) !important;
}
html.light .next-tour-card p { color: #0f172a !important; }

html.light .countdown-value { color: var(--cria-primary) !important; }
html.light .countdown-label { color: rgba(0,0,0,0.4) !important; }
html.light .countdown-sep { color: var(--cria-primary) !important; }

html.light .system-status-item {
    background: #f8f9fa !important;
    border: 1px solid rgba(0,0,0,0.06) !important;
}
html.light .system-status-item p { color: #0f172a !important; }

html.light .storage-meter {
    background: #f8f9fa !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .storage-meter p { color: #0f172a !important; }

html.light .admin-tab-btn { color: rgba(0,0,0,0.5) !important; }
html.light .admin-tab-btn:hover { color: #0f172a !important; }
html.light .admin-tab-btn.active {
    color: #0f172a !important;
    border-bottom-color: var(--admin-primary) !important;
}

/* Profile cover in light mode */
html.light .profile-cover-actions button {
    background: rgba(0,0,0,0.2) !important;
    border-color: rgba(0,0,0,0.2) !important;
}

/* Dashboard page wrapper */
html.light .dashboard-page { color: #0f172a; }

/* Status pills in light mode */
html.light .status-pill-green { background: rgba(16,185,129,0.1) !important; color: #059669 !important; }
html.light .status-pill-amber { background: rgba(245,158,11,0.1) !important; color: #d97706 !important; }
html.light .status-pill-red { background: rgba(239,68,68,0.08) !important; color: #dc2626 !important; }
html.light .status-pill-purple { background: rgba(139,92,246,0.1) !important; color: #7c3aed !important; }
html.light .status-pill-gray { background: rgba(0,0,0,0.06) !important; color: rgba(0,0,0,0.5) !important; }

/* Glass card in light mode */
html.light .glass-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
}

/* Fintech card in light mode */
html.light .fintech-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .fintech-label { color: rgba(0,0,0,0.5) !important; }
html.light .fintech-value { color: #0f172a !important; }
html.light .fintech-value-sm { color: #0f172a !important; }

/* Experience card in light mode */
html.light .experience-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .experience-card-title { color: #0f172a !important; }
html.light .experience-card-desc { color: rgba(0,0,0,0.55) !important; }

/* Search input in light mode */
html.light .search-input {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: #0f172a !important;
}
html.light .search-input::placeholder { color: rgba(0,0,0,0.4) !important; }

/* Filter chips in light mode */
html.light .filter-chip {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: rgba(0,0,0,0.6) !important;
}
html.light .filter-chip.active {
    background: #0f172a !important;
    color: white !important;
    border-color: #0f172a !important;
}

/* Vibe tags in light mode */
html.light .vibe-tag {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: rgba(0,0,0,0.7) !important;
}
html.light .vibe-tag.active {
    background: rgba(139,92,246,0.1) !important;
    border-color: rgba(139,92,246,0.25) !important;
    color: var(--brand) !important;
}

/* Like button in light mode */
html.light .like-btn {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: rgba(0,0,0,0.5) !important;
}
html.light .like-btn.liked {
    background: rgba(239,68,68,0.08) !important;
    border-color: rgba(239,68,68,0.2) !important;
    color: #ef4444 !important;
}

/* Bottom nav in light mode */
html.light .bottom-nav {
    background: rgba(255,255,255,0.95) !important;
    border-top: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .bottom-nav-item { color: rgba(0,0,0,0.4) !important; }
html.light .bottom-nav-item.active { color: var(--brand) !important; }

/* Btn primary/secondary in light mode */
html.light .btn-primary {
    background: var(--brand) !important;
    color: white !important;
}
html.light .btn-secondary {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
}
html.light .btn-secondary:hover { background: #e2e8f0 !important; }

/* Book button in light mode */
html.light .book-btn-card {
    background: var(--brand) !important;
    color: white !important;
}

/* Price tag in light mode */
html.light .price-tag { color: #0f172a !important; }

/* Gradient text in light mode */
html.light .gradient-text {
    background: linear-gradient(135deg, #0f172a 40%, var(--brand)) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

/* Empty state in light mode */
html.light .empty-state { background: linear-gradient(180deg, rgba(0,0,0,0.02) 0%, transparent 100%) !important; }
html.light .empty-state h3 { color: #0f172a !important; }
html.light .empty-state p { color: rgba(0,0,0,0.5) !important; }
html.light .empty-state-icon-wrap {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}

/* Notification toast in light mode */
html.light .notification-toast,
html.light .toast-item {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    color: #0f172a !important;
}

/* Modal in light mode */
html.light .modal-content {
    background: rgba(255,255,255,0.95) !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    color: #0f172a !important;
}
html.light .modal-close {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    color: #0f172a !important;
}

/* Confirm dialog in light mode */
html.light .confirm-dialog-content {
    background: rgba(255,255,255,0.95) !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    color: #0f172a !important;
}

/* Tab buttons in light mode */
html.light .tab-btn { color: rgba(0,0,0,0.5) !important; }
html.light .tab-btn:hover { color: #0f172a !important; }
html.light .tab-btn.active {
    color: #0f172a !important;
    border-bottom-color: var(--brand) !important;
}

/* Stat card in light mode */
html.light .stat-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .stat-label { color: rgba(0,0,0,0.5) !important; }
html.light .stat-value { color: #0f172a !important; }

/* Security advisory in light mode */
html.light .security-advisory {
    background: rgba(139,92,246,0.05) !important;
    border: 1px solid rgba(139,92,246,0.15) !important;
    color: rgba(0,0,0,0.6) !important;
}
html.light .security-advisory strong { color: #0f172a !important; }

/* Map info bar in light mode */
html.light .map-info-bar {
    background: #f8f9fa !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .map-info-item { color: #0f172a !important; }

/* Time slots in light mode */
html.light .time-slot {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: #0f172a !important;
}
html.light .time-slot.selected {
    background: var(--brand) !important;
    color: white !important;
    border-color: var(--brand) !important;
}

/* Participant selector in light mode */
html.light .participant-selector {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
}
html.light .participant-btn {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: #0f172a !important;
}

/* Online toggle in light mode */
html.light .online-toggle {
    background: #f8f9fa !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}

/* Work area btn in light mode */
html.light .work-area-btn {
    background: #f1f5f9 !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    color: #0f172a !important;
}
html.light .work-area-btn.active {
    background: rgba(139,92,246,0.1) !important;
    border-color: rgba(139,92,246,0.25) !important;
    color: var(--brand) !important;
}

/* Cancel policy in light mode */
html.light .cancel-policy {
    background: #f8f9fa !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .cancel-policy-row { border-bottom-color: rgba(0,0,0,0.06) !important; }

/* Voucher in light mode */
html.light .voucher-card {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}
html.light .voucher-body { color: #0f172a !important; }

/* Story items in light mode */
html.light .story-name { color: rgba(0,0,0,0.6) !important; }

/* Badge in light mode */
html.light .badge-neutral {
    background: rgba(0,0,0,0.06) !important;
    color: rgba(0,0,0,0.5) !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
}

/* Skeleton in light mode */
html.light .skeleton {
    background: #e2e8f0 !important;
}
html.light .skeleton::after {
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.6) 50%, transparent 100%) !important;
}

/* ── CRITICAL LIGHT MODE TEXT FIXES ── */

/* All text in content area must be visible in light mode */
html.light #content-area h1,
html.light #content-area h2,
html.light #content-area h3,
html.light #content-area h4,
html.light #content-area h5,
html.light #content-area p,
html.light #content-area span:not(.status-pill):not(.badge):not(.match-score) {
    color: inherit;
}

/* Profile name in light mode */
html.light .dashboard-page h2 { color: #0f172a !important; }
html.light .dashboard-page p { color: rgba(0,0,0,0.6) !important; }

/* Metric card label — allow wrapping on small screens */
.metric-card-label {
    font-size: 0.5625rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.08em !important;
    color: var(--muted-foreground) !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    line-height: 1.2 !important;
    margin-top: 0.25rem !important;
}
html.light .metric-card-label { color: rgba(0,0,0,0.5) !important; }

/* Metric card value — responsive */
.metric-card-value {
    font-size: clamp(1rem, 4vw, 1.5rem) !important;
    font-weight: 900 !important;
    letter-spacing: -0.04em !important;
    line-height: 1 !important;
    color: var(--foreground) !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}
html.light .metric-card-value { color: #0f172a !important; }

/* Booking card buttons — ensure visibility in both modes */
.booking-action-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.375rem !important;
    padding: 0.5rem 0.875rem !important;
    border-radius: var(--radius) !important;
    font-size: 0.8125rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    font-family: var(--font-sans) !important;
    transition: all 0.15s !important;
    white-space: nowrap !important;
    border: 1px solid var(--border) !important;
    background: var(--secondary) !important;
    color: var(--foreground) !important;
}
.booking-action-btn:hover { background: var(--accent) !important; }
.booking-action-btn.danger {
    color: #ef4444 !important;
    border-color: rgba(239,68,68,0.3) !important;
    background: rgba(239,68,68,0.06) !important;
}
.booking-action-btn.gold {
    color: #f59e0b !important;
    border-color: rgba(245,158,11,0.3) !important;
    background: rgba(245,158,11,0.06) !important;
}
html.light .booking-action-btn {
    background: #f1f5f9 !important;
    color: #0f172a !important;
    border-color: rgba(0,0,0,0.1) !important;
}
html.light .booking-action-btn.danger {
    color: #dc2626 !important;
    background: rgba(239,68,68,0.06) !important;
}
html.light .booking-action-btn.gold {
    color: #d97706 !important;
    background: rgba(245,158,11,0.06) !important;
}

/* Topbar flag emoji — ensure proper rendering */
.lang-selector {
    font-size: 1.25rem !important;
    line-height: 1 !important;
    padding: 0.375rem 0.5rem !important;
    min-width: 2.5rem !important;
    justify-content: center !important;
}

/* Mobile topbar — correct layout */
#mobile-topbar {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 0.5rem 1rem !important;
    padding-top: max(0.5rem, env(safe-area-inset-top)) !important;
    background: var(--background) !important;
    border-bottom: 0.5px solid var(--border) !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 9997 !important;
    min-height: 3.25rem !important;
}
@media (min-width: 768px) {
    #mobile-topbar { display: none !important; }
}

/* Booking card — dark mode fix */
.booking-card-wrap {
    background: var(--card) !important;
    border-radius: var(--radius-xl) !important;
    border: 1px solid var(--border) !important;
    overflow: hidden !important;
}
html.light .booking-card-wrap {
    background: #ffffff !important;
    border-color: rgba(0,0,0,0.08) !important;
}

/* Booking card text */
.booking-card-wrap h5 { color: var(--foreground) !important; }
.booking-card-wrap p { color: var(--muted-foreground) !important; }
html.light .booking-card-wrap h5 { color: #0f172a !important; }
html.light .booking-card-wrap p { color: rgba(0,0,0,0.5) !important; }

/* Status badge in booking */
.booking-status-badge {
    font-size: 0.625rem !important;
    font-weight: 700 !important;
    padding: 0.25rem 0.625rem !important;
    border-radius: 2rem !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

/* Profile cover avatar border */
.profile-cover-avatar .avatar {
    border: 3px solid var(--background) !important;
    box-shadow: 0 4px 16px rgba(0,0,0,0.2) !important;
}
html.light .profile-cover-avatar .avatar {
    border-color: #ffffff !important;
}

/* Ensure all inline-styled text is visible */
html.light [style*="color:var(--foreground)"] { color: #0f172a !important; }
html.light [style*="color:var(--muted-foreground)"] { color: rgba(0,0,0,0.5) !important; }
html.light [style*="color:var(--card-foreground)"] { color: #0f172a !important; }

/* Fix white text on white background in light mode */
html.light .snav-user-name { color: #0f172a !important; }
html.light .snav-user-role { color: rgba(0,0,0,0.5) !important; }
html.light .snav-stat-val { color: #0f172a !important; }
html.light .snav-stat-lbl { color: rgba(0,0,0,0.4) !important; }

/* Gradient text in light mode */
html.light .gradient-text,
html.light .text-gradient {
    background: linear-gradient(135deg, #0f172a 40%, var(--brand)) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    background-clip: text !important;
}

/* View title in light mode */
html.light #view-title { color: #0f172a !important; }
html.light #view-subtitle { color: rgba(0,0,0,0.5) !important; }

/* Page header in light mode */
html.light #page-header {
    border-bottom-color: rgba(0,0,0,0.08) !important;
}

/* Sidebar close button in light mode */
html.light .snav-close-btn {
    background: rgba(0,0,0,0.05) !important;
    border-color: rgba(0,0,0,0.1) !important;
    color: #0f172a !important;
}

/* Sidebar logout in light mode */
html.light .snav-logout span { color: #dc2626 !important; }
html.light .snav-logout { background: rgba(239,68,68,0.05) !important; }

/* Community alert in light mode */
html.light .community-alert { color: white !important; }

/* Progress bar always visible */
.top-progress-bar { z-index: 99999 !important; }

/* Ensure bottom nav is always above content */
.bottom-nav { z-index: 9999 !important; }

/* Fix for iPhone safe area */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .bottom-nav {
        padding-bottom: max(env(safe-area-inset-bottom), 0.5rem) !important;
    }
    #main-content {
        padding-bottom: calc(5rem + env(safe-area-inset-bottom)) !important;
    }
}

/* ── AVATAR FIX — Ensure circular images ── */
.avatar {
    border-radius: 50% !important;
    overflow: hidden !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
}
.avatar img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 50% !important;
    display: block !important;
}
.avatar-lg { width: 5rem !important; height: 5rem !important; }
.avatar-md { width: 3rem !important; height: 3rem !important; }
.avatar-sm { width: 2.25rem !important; height: 2.25rem !important; }
.avatar-xs { width: 1.75rem !important; height: 1.75rem !important; }

/* Profile cover avatar positioning */
.profile-cover-avatar {
    position: absolute !important;
    bottom: -2.5rem !important;
    left: 1.5rem !important;
}
.profile-cover {
    position: relative !important;
    height: 110px !important;
    border-radius: var(--ds-radius-xl) var(--ds-radius-xl) 0 0 !important;
    overflow: hidden !important;
}
.profile-cover-gradient {
    position: absolute !important;
    inset: 0 !important;
}
.profile-cover-actions {
    position: absolute !important;
    top: 0.875rem !important;
    right: 0.875rem !important;
    display: flex !important;
    gap: 0.5rem !important;
    z-index: 2 !important;
}

/* Sidebar avatar fix */
#sidebar-drawer .snav-user-card img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 50% !important;
}

/* Upload profile photo button */
.profile-cover-avatar {
    position: relative !important;
}
.profile-cover-avatar label {
    position: absolute !important;
    bottom: 0 !important;
    right: 0 !important;
    z-index: 3 !important;
}

/* ============================================
   PROFILE HERO — New Design v2
   ============================================ */

/* Profile hero card */
.profile-hero-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-xl);
    overflow: visible;
    position: relative;
}
html.light .profile-hero-card {
    background: #ffffff;
    border-color: rgba(0,0,0,0.08);
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

/* Cover area */
.profile-cover-wrap {
    position: relative;
    height: 130px;
    border-radius: var(--ds-radius-xl) var(--ds-radius-xl) 0 0;
    overflow: hidden;
}
.profile-cover-bg {
    position: absolute;
    inset: 0;
    transition: opacity 0.3s ease;
}

/* Cover edit button */
.profile-cover-edit-btn {
    position: absolute;
    bottom: 0.75rem;
    right: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.375rem 0.75rem;
    background: rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 2rem;
    color: white;
    font-size: 0.6875rem;
    font-weight: 700;
    cursor: pointer;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.2s ease;
    font-family: var(--font-sans);
    z-index: 2;
}
.profile-cover-edit-btn:hover {
    background: rgba(0,0,0,0.7);
    transform: translateY(-1px);
}

/* Avatar wrapper — positioned overlapping cover */
.profile-avatar-wrap {
    position: relative;
    margin-top: -3.5rem;
    margin-left: 1.5rem;
    display: inline-block;
    z-index: 3;
}

/* Animated ring around avatar */
.profile-avatar-ring {
    position: relative;
    width: 6rem;
    height: 6rem;
    border-radius: 50%;
    padding: 3px;
    background: conic-gradient(
        from 0deg,
        #8B5CF6,
        #a855f7,
        #ec4899,
        #f59e0b,
        #10B981,
        #3B82F6,
        #8B5CF6
    );
    background-size: 200% 200%;
    animation: avatarRingRotate 3s linear infinite;
    box-shadow: 0 0 20px rgba(139,92,246,0.4), 0 0 40px rgba(139,92,246,0.2);
}
@keyframes avatarRingRotate {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(360deg); }
}

/* Inner avatar */
.profile-avatar-inner {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    background: var(--card);
    border: 3px solid var(--background);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}
html.light .profile-avatar-inner {
    border-color: #ffffff;
    background: #f1f5f9;
}
.profile-avatar-inner img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    border-radius: 50% !important;
    display: block !important;
}
.avatar-fallback {
    font-size: 1.75rem;
    font-weight: 900;
    color: white;
    line-height: 1;
}

/* Camera button on avatar */
.profile-avatar-edit-btn {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 1.625rem;
    height: 1.625rem;
    background: var(--tourist-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 2px solid var(--background);
    transition: transform 0.2s ease;
    z-index: 4;
}
.profile-avatar-edit-btn:hover { transform: scale(1.1); }
html.light .profile-avatar-edit-btn { border-color: #ffffff; }

/* Profile info section */
.profile-info-wrap {
    padding: 0.75rem 1.5rem 1.5rem;
}

/* Sidebar avatar ring animation */
.snav-user-card .avatar-ring-animated {
    background: conic-gradient(from 0deg, #8B5CF6, #ec4899, #10B981, #8B5CF6);
    animation: avatarRingRotate 3s linear infinite;
    padding: 2px;
    border-radius: 50%;
}

/* Fix topbar flag display */
.lang-selector {
    font-size: 1.375rem !important;
    line-height: 1 !important;
    padding: 0.25rem 0.5rem !important;
    min-width: 2.75rem !important;
    height: 2.25rem !important;
    justify-content: center !important;
    background: var(--secondary) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius) !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    transition: background 0.15s !important;
}
.lang-selector:hover { background: var(--accent) !important; }

/* Cria profile hero — same treatment */
.cria-profile-hero-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--ds-radius-xl);
    overflow: visible;
}
.cria-avatar-ring {
    position: relative;
    width: 6rem;
    height: 6rem;
    border-radius: 50%;
    padding: 3px;
    background: conic-gradient(from 0deg, #10B981, #059669, #0d9488, #10B981);
    animation: avatarRingRotate 3s linear infinite;
    box-shadow: 0 0 20px rgba(16,185,129,0.4);
}
.admin-avatar-ring {
    position: relative;
    width: 6rem;
    height: 6rem;
    border-radius: 50%;
    padding: 3px;
    background: conic-gradient(from 0deg, #F59E0B, #d97706, #ef4444, #F59E0B);
    animation: avatarRingRotate 3s linear infinite;
    box-shadow: 0 0 20px rgba(245,158,11,0.4);
}

/* ── CRIA CARDS — Premium Design ── */
.cria-card {
    background: var(--card) !important;
    border: 1px solid var(--border) !important;
    border-radius: 1.25rem !important;
    overflow: hidden !important;
    cursor: pointer !important;
    transition: all 0.2s cubic-bezier(0.34,1.56,0.64,1) !important;
    position: relative !important;
}
.cria-card:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15) !important;
    border-color: rgba(139,92,246,0.2) !important;
}
.cria-card:active { transform: scale(0.98) !important; }

html.light .cria-card {
    background: #ffffff !important;
    border-color: rgba(0,0,0,0.08) !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
}
html.light .cria-card:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,0.1) !important;
    border-color: rgba(139,92,246,0.2) !important;
}

/* Verified badge shimmer in cards */
.cria-card .verified-shimmer {
    position: relative;
    overflow: hidden;
}
.cria-card .verified-shimmer::after {
    content: '';
    position: absolute;
    top: 0; left: -100%; width: 60%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: verifiedShimmer 3s ease-in-out infinite;
}

/* Sort filter chips */
[data-sort].active {
    background: #0a0a0a !important;
    color: white !important;
    border-color: #0a0a0a !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3) !important;
}
html.light [data-sort].active {
    background: #0a0a0a !important;
    color: white !important;
}

/* Map container */
#cria-finder-map {
    position: relative;
}
#cria-finder-map .leaflet-container {
    background: #0a0a0a !important;
}
