/* ============================================================================
   LYCCE — PORTAL DO ECOSSISTEMA (página principal de lycce.online)
   Tokens de cor e linguagem visual EXTRAÍDOS LITERALMENTE do modelo aprovado
   em Exemplo/HTTP/index.html (LycceGeo — dark-tech). Nenhuma cor nova.
   Versão: 1.1.1 · 27/09/2026 13:56 (UTC-4)
   Natureza: página de DEMONSTRAÇÃO (sem backend). Nenhum dado real é exibido.
   ============================================================================ */

:root {
    --bg-deep: #030712;
    --bg-card: #0f172a;
    --border-tech: #1e293b;
    --text-main: #f8fafc;
    --text-muted: #64748b;
    --green-neon: #10b981;
    --blue-tech: #3b82f6;
    --yellow-alert: #f59e0b;
    --magenta-telecom: #6366f1;
    --purple-ind: #a855f7;
    --glass: rgba(15, 23, 42, 0.85);
    --glass-soft: rgba(3, 7, 18, 0.45);
}

* { box-sizing: border-box; }

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-deep);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--text-main);
    overflow: hidden;
}

/* ------------------------------------------------------------------ MAPA --- */
#map-container {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-deep);
    background-image:
        radial-gradient(circle at 50% 50%, rgba(15, 23, 42, 0.4) 0%, var(--bg-deep) 100%),
        linear-gradient(rgba(30, 41, 59, 0.15) 1px, transparent 1px),
        linear-gradient(90deg, rgba(30, 41, 59, 0.15) 1px, transparent 1px);
    background-size: 100% 100%, 50px 50px, 50px 50px;
    z-index: 1;
    overflow: hidden;
}

.map-grid-line {
    position: absolute;
    background: rgba(30, 41, 59, 0.4);
    transition: all 1.2s ease-in-out;
}

/* Nó de módulo no mapa (o "ativo" do ecossistema) */
.ly-node {
    position: absolute;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    cursor: pointer;
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.6s ease-in-out;
    z-index: 3;
}

.ly-node.visible { transform: translate(-50%, -50%) scale(1); opacity: 1; }

.ly-node__icon {
    font-size: 1.35rem;
    line-height: 1;
    filter: drop-shadow(0 0 8px currentColor);
}

.ly-node__label {
    font-size: 0.6rem;
    font-family: monospace;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-main);
    background: rgba(3, 7, 18, 0.72);
    border: 1px solid var(--border-tech);
    border-radius: 4px;
    padding: 1px 5px;
    white-space: nowrap;
}

.ly-node:hover .ly-node__icon { transform: scale(1.25); }
.ly-node:hover .ly-node__label { border-color: var(--green-neon); color: var(--green-neon); }
.ly-node.hidden-node { display: none; }

@keyframes popIn {
    0% { transform: translate(-50%, -50%) scale(0); opacity: 0; }
    70% { transform: translate(-50%, -50%) scale(1.3); }
    100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

.ly-node.new-birth { animation: popIn 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards; }

/* ---------------------------------------------------------------- HEADER --- */
header.ly-topbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 76px;
    background: var(--glass);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-tech);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 0 20px;
    z-index: 40;
}

.logo-area { display: flex; align-items: center; gap: 12px; cursor: pointer; }

.logo-text {
    font-size: 1.55rem;
    font-weight: 900;
    letter-spacing: 0.05em;
    background: linear-gradient(135deg, #ffffff 40%, var(--green-neon));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo-dot {
    width: 12px;
    height: 12px;
    background-color: var(--green-neon);
    border-radius: 50%;
    box-shadow: 0 0 12px var(--green-neon);
}

.logo-sub {
    font-size: 0.6rem;
    font-family: monospace;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.header-telemetry {
    display: flex;
    gap: 18px;
    background: var(--glass-soft);
    border: 1px solid var(--border-tech);
    padding: 6px 16px;
    border-radius: 8px;
    font-family: monospace;
    font-size: 0.75rem;
}

.tel-item { display: flex; flex-direction: column; }
.tel-label { color: var(--text-muted); font-size: 0.6rem; text-transform: uppercase; letter-spacing: 0.05em; }
.tel-value { color: var(--green-neon); font-weight: bold; text-shadow: 0 0 5px rgba(16, 185, 129, 0.3); }
.tel-value.blue { color: var(--blue-tech); text-shadow: 0 0 5px rgba(59, 130, 246, 0.3); }
.tel-value.amber { color: var(--yellow-alert); }
.tel-value.violet { color: var(--purple-ind); }

.nav-modules {
    display: flex;
    gap: 4px;
    overflow-x: auto;
    max-width: 46vw;
    scrollbar-width: thin;
    padding-bottom: 2px;
}

.nav-btn {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    padding: 7px 10px;
    font-size: 0.72rem;
    font-weight: 600;
    font-family: inherit;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.25s;
    white-space: nowrap;
}

.nav-btn:hover,
.nav-btn.active {
    border-color: var(--border-tech);
    background: rgba(30, 41, 59, 0.4);
    color: var(--text-main);
}

.nav-btn.active {
    border-color: rgba(16, 185, 129, 0.3);
    color: var(--green-neon);
    box-shadow: inset 0 0 10px rgba(16, 185, 129, 0.1);
}

.nav-btn.nav-btn--gov { border-color: rgba(168, 85, 247, 0.35); color: var(--purple-ind); }

.user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    border-left: 1px solid var(--border-tech);
    padding-left: 16px;
    font-size: 0.78rem;
    font-weight: 600;
}

.avatar {
    width: 34px;
    height: 32px;
    background: var(--border-tech);
    border: 1px solid var(--green-neon);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--green-neon);
}

/* ------------------------------------------------------ CARD FLUTUANTE --- */
.floating-card {
    position: absolute;
    top: 96px;
    right: 22px;
    width: 322px;
    background: var(--glass);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-tech);
    border-radius: 10px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.55);
    z-index: 30;
}

.card-header-drag {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-tech);
    cursor: grab;
    margin-bottom: 12px;
}

.card-header-drag:active { cursor: grabbing; }

.card-title-text {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-main);
}

.card-title-text .drag-icon { color: var(--text-muted); }

.control-btn {
    width: 22px;
    height: 22px;
    background: transparent;
    border: 1px solid var(--border-tech);
    border-radius: 4px;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.9rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.control-btn:hover {
    background: var(--green-neon);
    color: var(--bg-deep);
    border-color: var(--green-neon);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
}

.floating-card.minimized .card-header-drag { margin-bottom: 0; border-bottom: none; }
.floating-card.minimized .card-body-content { display: none; }

.card-body-content { padding: 0 12px 12px; max-height: 46vh; overflow-y: auto; }

.inventory-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 9px;
    font-size: 0.8rem;
}

.item-label { display: flex; align-items: center; gap: 8px; color: var(--text-muted); }

.item-value {
    font-weight: 700;
    color: var(--text-main);
    background: rgba(30, 41, 59, 0.6);
    padding: 2px 8px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.72rem;
}

.checkbox-container { display: flex; align-items: center; cursor: pointer; }
.checkbox-container input { display: none; }

.custom-checkbox {
    width: 14px;
    height: 14px;
    border: 1px solid var(--border-tech);
    border-radius: 3px;
    margin-right: 8px;
    display: inline-block;
    position: relative;
    background: rgba(3, 7, 18, 0.5);
    flex: 0 0 auto;
}

.checkbox-container input:checked + .custom-checkbox { background-color: var(--green-neon); border-color: var(--green-neon); }

.checkbox-container input:checked + .custom-checkbox::after {
    content: '';
    position: absolute;
    left: 4px;
    top: 1px;
    width: 4px;
    height: 7px;
    border: solid var(--bg-deep);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.copy-action-btn {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid var(--green-neon);
    color: var(--green-neon);
    width: 100%;
    padding: 9px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.76rem;
    font-weight: 700;
    font-family: inherit;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 12px;
    transition: all 0.3s;
}

.copy-action-btn:hover { background: var(--green-neon); color: var(--bg-deep); box-shadow: 0 0 12px rgba(16, 185, 129, 0.4); }

/* ------------------------------------------------------------- TIMELINE --- */
.timeline-container {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    width: calc(100% - 48px);
    max-width: 820px;
    background: var(--glass);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-tech);
    border-radius: 12px;
    padding: 14px 22px;
    z-index: 20;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
}

.timeline-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }

.timeline-title {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

.current-year {
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--green-neon);
    font-family: monospace;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.3);
}

.timeline-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--border-tech);
    outline: none;
    cursor: pointer;
}

.timeline-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--green-neon);
    box-shadow: 0 0 10px var(--green-neon);
    border: 2px solid var(--bg-deep);
    transition: transform 0.1s;
}

.timeline-slider::-webkit-slider-thumb:hover { transform: scale(1.2); }
.timeline-slider::-moz-range-thumb {
    width: 16px; height: 16px; border-radius: 50%;
    background: var(--green-neon); border: 2px solid var(--bg-deep);
}

.timeline-ticks { display: flex; justify-content: space-between; margin-top: 6px; padding: 0 4px; }
.tick-label { font-size: 0.68rem; font-weight: 600; color: var(--text-muted); font-family: monospace; cursor: pointer; }
.tick-label.active { color: var(--green-neon); }

/* ---------------------------------------------------------- NOTIFICAÇÃO --- */
.map-notification {
    position: absolute;
    bottom: 172px;
    left: 22px;
    width: 296px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-left: 4px solid var(--yellow-alert);
    border-radius: 6px;
    padding: 11px 12px;
    font-size: 0.78rem;
    z-index: 20;
    backdrop-filter: blur(8px);
    animation: slideInNotify 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideInNotify {
    0% { transform: translateX(-50px); opacity: 0; }
    100% { transform: translateX(0); opacity: 1; }
}

.notify-title { font-weight: 700; color: var(--yellow-alert); margin-bottom: 4px; font-size: 0.74rem; letter-spacing: 0.04em; }
.notify-body { color: #cbd5e1; line-height: 1.45; }

/* ----------------------------------------------------------- STATUS BAR --- */
.ly-statusbar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 26px;
    background: rgba(3, 7, 18, 0.9);
    border-top: 1px solid var(--border-tech);
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 0 14px;
    font-family: monospace;
    font-size: 0.66rem;
    color: var(--text-muted);
    z-index: 60;
}

.ly-statusbar strong { color: var(--green-neon); }
.ly-statusbar .sb-right { margin-left: auto; display: flex; gap: 14px; align-items: center; }

.ly-demo-badge {
    color: var(--yellow-alert);
    border: 1px solid rgba(245, 158, 11, 0.35);
    border-radius: 3px;
    padding: 0 6px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* ------------------------------------------- APRESENTAÇÃO (overlay full) --- */
.ly-overlay {
    position: fixed;
    inset: 0;
    background: rgba(3, 7, 18, 0.92);
    backdrop-filter: blur(10px);
    z-index: 80;
    overflow-y: auto;
    padding: 26px 22px 60px;
    display: none;
}

.ly-overlay.open { display: block; }

.ly-overlay-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    max-width: 1240px;
    margin: 0 auto 18px;
    border-bottom: 1px solid var(--border-tech);
    padding-bottom: 14px;
}

.ly-overlay-title { font-size: 1.5rem; font-weight: 900; letter-spacing: 0.02em; margin: 0; }
.ly-overlay-sub { color: var(--text-muted); font-size: 0.8rem; margin: 4px 0 0; }

.ly-hero {
    max-width: 1240px;
    margin: 0 auto 20px;
    background: var(--glass);
    border: 1px solid var(--border-tech);
    border-left: 4px solid var(--green-neon);
    border-radius: 10px;
    padding: 16px 18px;
}

.ly-hero h2 { margin: 0 0 8px; font-size: 1.05rem; }
.ly-hero p { margin: 0 0 10px; color: #cbd5e1; font-size: 0.86rem; line-height: 1.55; }

.ly-chip-row { display: flex; flex-wrap: wrap; gap: 6px; }

.ly-chip {
    font-family: monospace;
    font-size: 0.68rem;
    color: var(--text-muted);
    border: 1px solid var(--border-tech);
    background: rgba(30, 41, 59, 0.35);
    border-radius: 20px;
    padding: 3px 10px;
}

.ly-grid {
    max-width: 1240px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 14px;
}

.ly-card {
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--border-tech);
    border-radius: 10px;
    padding: 14px 15px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: border-color 0.25s, transform 0.25s;
}

.ly-card:hover { border-color: rgba(16, 185, 129, 0.45); transform: translateY(-2px); }

.ly-card__top { display: flex; align-items: center; gap: 10px; }
.ly-card__icon { font-size: 1.5rem; line-height: 1; filter: drop-shadow(0 0 8px currentColor); }
.ly-card__name { font-size: 0.98rem; font-weight: 800; }
.ly-card__route { font-family: monospace; font-size: 0.7rem; color: var(--blue-tech); }

.ly-card__badge {
    margin-left: auto;
    font-family: monospace;
    font-size: 0.64rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 4px;
    padding: 2px 7px;
    border: 1px solid currentColor;
    white-space: nowrap;
}

.badge-prod { color: var(--green-neon); background: rgba(16, 185, 129, 0.1); }
.badge-ready { color: var(--blue-tech); background: rgba(59, 130, 246, 0.1); }
.badge-next { color: var(--yellow-alert); background: rgba(245, 158, 11, 0.1); }
.badge-plan { color: var(--text-muted); background: rgba(100, 116, 139, 0.1); }
.badge-lock { color: var(--purple-ind); background: rgba(168, 85, 247, 0.1); }

.ly-card__desc { color: #cbd5e1; font-size: 0.82rem; line-height: 1.5; margin: 0; }

.ly-card__bullets { margin: 0; padding-left: 16px; color: var(--text-muted); font-size: 0.78rem; line-height: 1.55; }
.ly-card__bullets li { margin-bottom: 2px; }

.ly-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 12px;
    border-top: 1px solid var(--border-tech);
    padding-top: 8px;
    font-size: 0.72rem;
    color: var(--text-muted);
    font-family: monospace;
}

.ly-card__actions { display: flex; gap: 8px; margin-top: 2px; }

.ly-btn {
    border: 1px solid var(--border-tech);
    background: rgba(30, 41, 59, 0.45);
    color: var(--text-main);
    border-radius: 6px;
    padding: 7px 12px;
    font-size: 0.76rem;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.25s;
}

.ly-btn:hover { border-color: var(--green-neon); color: var(--green-neon); }

.ly-btn--primary {
    background: rgba(16, 185, 129, 0.12);
    border-color: var(--green-neon);
    color: var(--green-neon);
}

.ly-btn--primary:hover { background: var(--green-neon); color: var(--bg-deep); box-shadow: 0 0 12px rgba(16, 185, 129, 0.4); }
.ly-btn--ghost { color: var(--text-muted); }

/* ---------------------------------------------------------- JANELA (win) --- */
.ly-win {
    position: fixed;
    top: 120px;
    left: 96px;
    width: 470px;
    max-width: calc(100vw - 40px);
    background: rgba(15, 23, 42, 0.96);
    border: 1px solid var(--border-tech);
    border-radius: 10px;
    box-shadow: 0 20px 45px -10px rgba(0, 0, 0, 0.75);
    z-index: 90;
    display: none;
}

.ly-win.open { display: block; }
.ly-win.focused { border-color: rgba(16, 185, 129, 0.5); box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.25), 0 20px 45px -10px rgba(0, 0, 0, 0.8); }

.ly-win__head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-bottom: 1px solid var(--border-tech);
    cursor: grab;
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.ly-win__head:active { cursor: grabbing; }
.ly-win__head .drag-icon { color: var(--text-muted); }

.ly-win__cpu { display: flex; gap: 6px; align-items: center; }
.ly-win__cpu span { width: 11px; height: 11px; border-radius: 50%; display: inline-block; border: 1px solid rgba(3, 7, 18, 0.6); }
.ly-win__cpu .c1 { background: #ef4444; }
.ly-win__cpu .c2 { background: var(--yellow-alert); }
.ly-win__cpu .c3 { background: var(--green-neon); }

.ly-win__spacer { flex: 1; }

.ly-win__body {
    padding: 13px 15px 16px;
    max-height: 68vh;
    overflow-y: auto;
    font-size: 0.84rem;
    line-height: 1.55;
    color: #cbd5e1;
}

.ly-win__body h3 { margin: 0 0 8px; font-size: 0.95rem; color: var(--text-main); }
.ly-win__body h4 { margin: 14px 0 6px; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); }
.ly-win__body ul { margin: 0; padding-left: 17px; }
.ly-win__body li { margin-bottom: 3px; }
.ly-win__body p { margin: 0 0 9px; }

.ly-win__note {
    margin-top: 12px;
    border: 1px dashed rgba(245, 158, 11, 0.4);
    background: rgba(245, 158, 11, 0.08);
    border-radius: 6px;
    padding: 9px 10px;
    font-size: 0.76rem;
    color: var(--yellow-alert);
}

/* ------------------------------------------------------------- GOVERNANÇA --- */
.gov-toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }

.gov-select,
.gov-input {
    background: rgba(3, 7, 18, 0.6);
    border: 1px solid var(--border-tech);
    color: var(--text-main);
    border-radius: 6px;
    padding: 6px 8px;
    font-family: inherit;
    font-size: 0.76rem;
    color-scheme: dark;
}

.gov-select option { background: rgb(11, 18, 32); color: var(--text-main); }

.gov-tree { border: 1px solid var(--border-tech); border-radius: 8px; overflow: hidden; }

.gov-row {
    display: grid;
    grid-template-columns: 1fr 128px 54px 54px 54px;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-bottom: 1px solid rgba(30, 41, 59, 0.6);
    font-size: 0.79rem;
}

.gov-row:last-child { border-bottom: none; }
.gov-row:nth-child(even) { background: rgba(3, 7, 18, 0.35); }

.gov-row.gov-head {
    background: rgba(30, 41, 59, 0.5);
    font-size: 0.66rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    font-weight: 700;
}

.gov-row.gov-pai { background: rgba(16, 185, 129, 0.06); font-weight: 700; }
.gov-row.gov-pop { background: rgba(59, 130, 246, 0.06); }
.gov-row.gov-pop-2 { background: rgba(59, 130, 246, 0.1); }

.gov-cell { display: flex; align-items: center; gap: 6px; }
.gov-indent { display: inline-block; width: 16px; }
.gov-cell--center { justify-content: center; }

.gov-toggle { cursor: pointer; color: var(--text-muted); width: 14px; display: inline-block; user-select: none; text-align: center; }

.gov-lvl {
    width: 18px;
    height: 18px;
    border: 1px solid var(--border-tech);
    border-radius: 3px;
    background: rgba(3, 7, 18, 0.6);
    cursor: pointer;
    position: relative;
    flex: 0 0 auto;
}

.gov-lvl[data-state="allow"] { background: rgba(16, 185, 129, 0.22); border-color: var(--green-neon); color: var(--green-neon); }
.gov-lvl[data-state="allow"]::after { content: '✓'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 0.72rem; font-weight: 900; }
.gov-lvl[data-state="deny"] { background: rgba(245, 158, 11, 0.18); border-color: var(--yellow-alert); color: var(--yellow-alert); }
.gov-lvl[data-state="deny"]::after { content: '✕'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 0.68rem; font-weight: 900; }
.gov-lvl[data-state="inherit"]::after { content: '◪'; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 0.6rem; color: var(--text-muted); }

.gov-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 0.7rem; color: var(--text-muted); margin: 10px 0 4px; font-family: monospace; }

.gov-sim {
    margin-top: 10px;
    border: 1px solid var(--border-tech);
    border-radius: 8px;
    padding: 10px 11px;
    background: rgba(3, 7, 18, 0.5);
    font-family: monospace;
    font-size: 0.72rem;
    color: var(--text-muted);
    white-space: pre-wrap;
}

.gov-sim strong { color: var(--green-neon); }
.gov-sim .neg { color: var(--yellow-alert); }

/* ---------------------------------------------------------- RODAPÉ/MISC --- */
.ly-footer {
    max-width: 1240px;
    margin: 22px auto 0;
    border-top: 1px solid var(--border-tech);
    padding-top: 12px;
    color: var(--text-muted);
    font-size: 0.74rem;
    font-family: monospace;
    display: flex;
    flex-wrap: wrap;
    gap: 6px 18px;
}

::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-track { background: rgba(3, 7, 18, 0.5); }
::-webkit-scrollbar-thumb { background: rgba(30, 41, 59, 0.9); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: rgba(16, 185, 129, 0.5); }

/* ============================================================================
   v1.1.2 — AS REGRAS DE CELULAR/TABLET DESTE ARQUIVO FORAM CONSOLIDADAS NO
   BLOCO "CAMADA AUTOADAPTATIVA" (fim do arquivo), que é chaveado por
   html[data-dispositivo]. A regra que existia aqui deixava
   "#bairro { position: static; height: auto }" — e isso ZERAVA a altura do
   canvas (que é absolute/inset:0), fazendo a animação 2.5D desaparecer no
   celular. Foi esse o defeito corrigido na v1.1.2.
   Aqui fica apenas a preferência de acessibilidade do sistema.
   ============================================================================ */
@media (prefers-reduced-motion: reduce) {
    * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* ============================================================================
   SIMULAÇÃO DE CRESCIMENTO DO BAIRRO (acionada pelo time-slider "Efeito Pipoca")
   Etapas: 1 bairro · 2 ruas · 3 pedidos de UC · 4 transformadores · 5 UCs ·
   6 casas subindo · 7 bairro crescendo · 8 escolas · 9 solar nos telhados ·
   10 rede iluminada · 11 pessoas · 12 votos · 13 carros · 14 semáforos
   ============================================================================ */

#bairro {
    position: absolute;
    top: 12%;
    left: 10%;
    width: 72%;
    height: 63%;
    z-index: 2;
}

/* Perímetro do loteamento (etapa 1) */
#bairro::before {
    content: '';
    position: absolute;
    inset: -10px;
    border-radius: 12px;
    background: radial-gradient(ellipse at 50% 50%, rgba(16, 185, 129, 0.05), transparent 70%);
    box-shadow: inset 0 0 46px rgba(3, 7, 18, 0.7);
    pointer-events: none;
}

#cidade {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}

.bairro-legenda {
    position: absolute;
    top: -30px;
    left: 0;
    font-family: monospace;
    font-size: 0.66rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--green-neon);
    opacity: 0.75;
}

/* ---- Regra central: todo elemento de etapa nasce invisível ---- */
#bairro [data-etapa] {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease-in-out, visibility 0.5s;
}

#bairro [data-etapa].ativo {
    opacity: 1;
    visibility: visible;
}

/* As casas crescem de baixo para cima mesmo quando o container já está visível */
#bairro .lote .casa { transition: transform 0.75s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.35s, visibility 0.35s; }

/* ------------------------------------------------------------------ RUAS --- */
.rua {
    position: absolute;
    background: rgba(30, 41, 59, 0.55);
    z-index: 1;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1), background 0.6s, box-shadow 0.6s;
}

.rua.ativo { transform: scaleX(1); }
.rua.rua--v { transform: scaleY(0); transform-origin: top center; }
.rua.rua--v.ativo { transform: scaleY(1); }

.rua.iluminada {
    background: rgba(245, 158, 11, 0.42);
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.28);
}

/* ------------------------------------------------------------------ LOTES --- */
.lote {
    position: absolute;
    width: 26px;
    height: 22px;
    border: 1px dashed var(--border-tech);
    border-radius: 4px;
    background: rgba(3, 7, 18, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.62rem;
    z-index: 4;
    transition: opacity 0.5s, border-color 0.4s, background 0.4s, box-shadow 0.4s;
}

.lote.ativo { border-color: rgba(245, 158, 11, 0.5); }
.lote.ligado { border-style: solid; border-color: rgba(16, 185, 129, 0.55); background: rgba(16, 185, 129, 0.07); }
.lote__pedido { font-size: 0.62rem; opacity: 0.9; }

.lote.ligado .lote__pedido { display: none; }

.uc-badge {
    position: absolute;
    right: -7px;
    top: -7px;
    font-family: monospace;
    font-size: 0.5rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--green-neon);
    background: rgba(3, 7, 18, 0.85);
    border: 1px solid var(--green-neon);
    border-radius: 3px;
    padding: 0 3px;
    z-index: 6;
}

/* ---------------------------------------------------------- TRANSFORMADOR --- */
.trafo {
    position: absolute;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    color: var(--yellow-alert);
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.45);
    border-radius: 4px;
    z-index: 7;
    filter: drop-shadow(0 0 6px rgba(245, 158, 11, 0.5));
}

.trafo.ativo { animation: trafoPulse 2.4s ease-in-out infinite; }

@keyframes trafoPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.35); }
    50% { box-shadow: 0 0 0 5px rgba(245, 158, 11, 0); }
}

/* ------------------------------------------------------------------ CASAS --- */
.casa {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transform: translateY(12px) scale(0.55);
    transform-origin: bottom center;
    transition: transform 0.75s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.5s;
}

.casa.ativo { transform: translateY(0) scale(1); }
.casa.casa--alta { font-size: 1.25rem; }

.solar-badge {
    position: absolute;
    top: -9px;
    right: -9px;
    font-size: 0.55rem;
    opacity: 0;
    transform: scale(0) rotate(-20deg);
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    filter: drop-shadow(0 0 5px rgba(245, 158, 11, 0.9));
}

.solar-badge.ativo { opacity: 1; transform: scale(1) rotate(0deg); }

/* ----------------------------------------------------------------- ESCOLA --- */
.escola,
.predio {
    position: absolute;
    font-size: 1.15rem;
    z-index: 6;
    filter: drop-shadow(0 0 7px rgba(168, 85, 247, 0.6));
}

/* -------------------------------------------------- REDE ELÉTRICA (POSTE) --- */
.poste {
    position: absolute;
    font-size: 0.85rem;
    z-index: 5;
    filter: grayscale(1) brightness(0.7);
    transition: filter 0.7s, opacity 0.5s;
}

.poste.luz-on {
    filter: none;
    text-shadow: 0 0 14px rgba(245, 158, 11, 0.95);
}

.poste.luz-on::after {
    content: '';
    position: absolute;
    inset: -7px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.4), transparent 70%);
    animation: luzPisca 3.4s ease-in-out infinite;
    z-index: -1;
}

@keyframes luzPisca {
    0%, 100% { opacity: 0.55; }
    50% { opacity: 0.95; }
}

/* ------------------------------------------------------------- PESSOAS ------ */
.pessoa {
    position: absolute;
    font-size: 0.8rem;
    z-index: 8;
    animation: pessoaAnda 4.5s ease-in-out infinite;
}

@keyframes pessoaAnda {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(4px, -2px); }
    50% { transform: translate(7px, 0); }
    75% { transform: translate(3px, 2px); }
}

/* --------------------------------------------------------------- VOTOS ------ */
.voto {
    position: absolute;
    font-size: 0.9rem;
    z-index: 9;
    filter: drop-shadow(0 0 6px rgba(168, 85, 247, 0.75));
    animation: votoPulsa 2.6s ease-in-out infinite;
}

@keyframes votoPulsa {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.18); }
}

/* -------------------------------------------------------------- CARROS ------ */
.carro {
    position: absolute;
    font-size: 0.9rem;
    z-index: 8;
    animation: carroRoda 7s ease-in-out infinite;
}

@keyframes carroRoda {
    0% { transform: translateX(-9px); }
    50% { transform: translateX(9px); }
    100% { transform: translateX(-9px); }
}

/* ----------------------------------------------------------- SEMÁFOROS ------ */
.semaforo {
    position: absolute;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 2px;
    background: rgb(11, 18, 32);
    border: 1px solid var(--border-tech);
    border-radius: 3px;
    z-index: 9;
    box-shadow: 0 0 10px rgba(3, 7, 18, 0.9);
}

.semaforo span {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #1e293b;
}

.semaforo .s-red { animation: sinalRed 3s linear infinite; }
.semaforo .s-yel { animation: sinalYel 3s linear infinite; }
.semaforo .s-grn { animation: sinalGrn 3s linear infinite; }

@keyframes sinalRed {
    0%, 30% { background: #ef4444; box-shadow: 0 0 6px #ef4444; }
    31%, 100% { background: #1e293b; box-shadow: none; }
}

@keyframes sinalYel {
    0%, 33% { background: #1e293b; box-shadow: none; }
    34%, 64% { background: var(--yellow-alert); box-shadow: 0 0 6px var(--yellow-alert); }
    65%, 100% { background: #1e293b; box-shadow: none; }
}

@keyframes sinalGrn {
    0%, 67% { background: #1e293b; box-shadow: none; }
    68%, 100% { background: var(--green-neon); box-shadow: 0 0 6px var(--green-neon); }
}

/* ---------------------------------------------- TIMELINE POR ETAPAS --------- */
.timeline-container { bottom: 38px; }
.map-notification { bottom: 240px; }

.timeline-status { display: flex; align-items: center; gap: 10px; }

.timeline-etapa {
    font-family: monospace;
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--blue-tech);
    border: 1px solid rgba(59, 130, 246, 0.35);
    background: rgba(59, 130, 246, 0.1);
    border-radius: 4px;
    padding: 1px 6px;
}

.timeline-legenda {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-main);
    margin: 7px 0 2px;
    min-height: 20px;
}

.timeline-legenda .tl-ico { font-size: 0.95rem; }

.timeline-ticks { display: flex; justify-content: space-between; gap: 2px; margin-top: 6px; padding: 0; }

.tick-label {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.05;
    padding: 1px 0;
    border: 1px solid transparent;
    border-radius: 4px;
    transition: all 0.2s;
}

.tick-label .tick-ico { font-size: 0.74rem; filter: grayscale(1); opacity: 0.5; }
.tick-label .tick-num { font-size: 0.54rem; color: var(--text-muted); }

.tick-label:hover { border-color: var(--border-tech); background: rgba(30, 41, 59, 0.35); }
.tick-label.viva .tick-ico { filter: none; opacity: 0.9; }
.tick-label.active { background: rgba(16, 185, 129, 0.08); border-color: rgba(16, 185, 129, 0.3); }
.tick-label.active .tick-ico { filter: none; opacity: 1; }
.tick-label.active .tick-num { color: var(--green-neon); font-weight: 700; }

/* ------------------------------------- CENSO DO BAIRRO (card flutuante) ---- */
.censo { margin-top: 14px; border-top: 1px solid var(--border-tech); padding-top: 12px; }

.censo__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-main);
    margin-bottom: 8px;
}

.censo__etapa {
    font-family: monospace;
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--green-neon);
    border: 1px solid rgba(16, 185, 129, 0.35);
    background: rgba(16, 185, 129, 0.08);
    border-radius: 4px;
    padding: 1px 5px;
}

.censo__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3px 10px;
    font-size: 0.69rem;
    color: var(--text-muted);
}

.censo__grid span {
    display: flex;
    justify-content: space-between;
    gap: 6px;
    border-bottom: 1px dotted rgba(30, 41, 59, 0.85);
    padding-bottom: 2px;
}

.censo__grid b { color: var(--text-main); font-family: monospace; }

/* ============================================================================
   v1.1.2 — A REGRA DE CELULAR QUE EXISTIA AQUI FOI CONSOLIDADA NO BLOCO
   "CAMADA AUTOADAPTATIVA" (fim deste arquivo), chaveado por html[data-dispositivo].
   Era exatamente esta dupla que quebrava o bolso:
       .tick-label .tick-num { display: none }      → escondia o número da etapa
       #bairro { position: static; height: auto }   → ZERAVA a altura do canvas
                                                      (que é absolute/inset:0) e a
                                                      animação 2.5D desaparecia.
   Agora o palco (#bairro) tem caixa de verdade e a régua rola de lado com
   todos os 14 passos tocáveis.
   ============================================================================ */










/* ============================================================================
   CIDADE 2.5D VIVA (v1.1.0) — giro pela alça do canto, etiqueta LycceSolar,
   frase "Olhe, Saiba onde Olhar", foco no módulo do ecossistema e autoplay.
   A etiqueta LycceSolar e a alça de giro são desenhadas DENTRO do canvas
   (portal-modulos.js); aqui vive o que é HTML: slogan, dica, botão e chip.
   ============================================================================ */

/* ---------------------------------------- CANVAS: cursor de "pegar e girar" --- */
#cidade { touch-action: none; cursor: grab; }
#cidade.girando { cursor: grabbing; }

/* --------------------------------------------- FRASE DE ABERTURA/FECHAMENTO -- */
.cidade-slogan {
    position: absolute;
    left: 50%;
    top: 40%;
    transform: translate(-50%, -50%) scale(0.94);
    width: max-content;
    max-width: 92%;
    text-align: center;
    font-size: clamp(1.05rem, 2.6vw, 2rem);
    font-weight: 800;
    letter-spacing: 0.16em;
    color: var(--text-main);
    text-shadow: 0 0 26px rgba(16, 185, 129, 0.55), 0 2px 14px rgba(3, 7, 18, 0.95);
    opacity: 0;
    transition: opacity 0.9s ease, transform 0.9s ease;
    pointer-events: none;
    z-index: 3;
}

.cidade-slogan.on { opacity: 1; transform: translate(-50%, -50%) scale(1); }

/* --------------------------------------------------- DICA DO GIRO (2.5D) ----- */
.cidade-dica {
    position: absolute;
    left: 0;
    bottom: -24px;
    font-family: monospace;
    font-size: 0.62rem;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    opacity: 0.8;
    transition: opacity 0.5s;
    pointer-events: none;
}

.cidade-dica.oculta { opacity: 0; }

/* -------------------------------- BOTÃO ▶ PROSSEGUIR / ⏸ PAUSAR (timeline) --- */
.timeline-btn {
    font-family: monospace;
    font-size: 0.64rem;
    font-weight: 700;
    color: var(--green-neon);
    border: 1px solid rgba(16, 185, 129, 0.45);
    background: rgba(16, 185, 129, 0.12);
    border-radius: 5px;
    padding: 2px 9px;
    cursor: pointer;
    transition: all 0.2s;
}

.timeline-btn:hover { background: rgba(16, 185, 129, 0.24); }

.timeline-btn.pausado {
    color: var(--yellow-alert);
    border-color: rgba(245, 158, 11, 0.5);
    background: rgba(245, 158, 11, 0.12);
}

/* ------------------------ CHIP "EM FOCO NO ECOSSISTEMA" (módulo da etapa) ----- */
.timeline-foco {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-muted);
    margin: 2px 0 0;
    min-height: 15px;
    transition: color 0.35s;
}

.timeline-foco[data-mod] { color: var(--green-neon); }

/* =========================== ÊNFASE NO ITEM DO ECOSSISTEMA ===================
   A cada etapa, o cartão, o nó do mapa e o botão de menu do módulo que a
   cidade está mostrando acendem em verde, com um pulso discreto.
   ============================================================================ */
@keyframes ecoPulso {
    0%, 100% { box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.35), 0 0 26px rgba(16, 185, 129, 0.14); }
    50%      { box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.80), 0 0 40px rgba(16, 185, 129, 0.34); }
}

.ly-card.eco-foco {
    border-color: rgba(16, 185, 129, 0.8);
    animation: ecoPulso 2.4s ease-in-out infinite;
}

.ly-card.eco-foco .ly-card__name { color: var(--green-neon); }

.ly-node.eco-foco .ly-node__icon { transform: scale(1.3); filter: drop-shadow(0 0 14px currentColor); }
.ly-node.eco-foco .ly-node__label { border-color: var(--green-neon); color: var(--green-neon); }

.nav-btn.eco-foco {
    border-color: rgba(16, 185, 129, 0.65);
    color: var(--green-neon);
    box-shadow: 0 0 18px rgba(16, 185, 129, 0.2);
}



/* ============================================================================
   v1.1.2 — CAMADA AUTOADAPTATIVA: CELULAR · TABLET · DESKTOP
   ----------------------------------------------------------------------------
   QUEM DECIDE É A MEDIÇÃO (largura + toque + orientação), nunca um "chute" de
   user-agent: portal-modulos.js mede e escreve em
        <html data-dispositivo="celular|tablet|desktop" data-toque="sim|nao"
              data-paisagem="sim|nao">
   Todo o CSS desta seção é chaveado por ESSES ATRIBUTOS — previsível e testável.

   O QUE ESTAVA QUEBRADO NO CELULAR (e o que esta seção conserta):
     1. #bairro ficava "position: static; height: auto" enquanto o canvas é
        "position:absolute; inset:0" → altura ZERO: a animação 2.5D SUMIA;
     2. os botões da topbar quebravam linha virando um bloco irregular;
     3. inventário, censo e o painel do Efeito Pipoca viravam uma pilha longa;
     4. não havia como girar a cidade (a alça exigia ponteiro com mira de 30 px);
     5. rodapé/statusbar/cards disputavam espaço com o conteúdo.

   NADA FOI REMOVIDO: as 13 fichas, o inventário, o censo, a governança, a
   apresentação, o giro, o autoplay e a régua de 14 etapas continuam existindo —
   apenas reposicionados e com alvo de toque de verdade.
   ============================================================================ */

/* ----------------------- 1. A PÁGINA PASSA A ROLAR (tela travada só no PC) -- */
html[data-dispositivo="celular"],
html[data-dispositivo="celular"] body,
html[data-dispositivo="tablet"],
html[data-dispositivo="tablet"] body {
    height: auto;
    min-height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-text-size-adjust: 100%;
}

html[data-dispositivo="celular"] #map-container,
html[data-dispositivo="tablet"] #map-container {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
    min-height: 100svh;
    overflow: visible;
    /* topbar fixa (76px) + faixa de módulos (≈44px): o palco nasce abaixo,
       e o pé guarda espaço para a barra de status */
    padding: 126px 0 52px;
    /* v1.1.2 — no bolso a pilha é CONTROLADA por ordem explícita:
       palco → Efeito Pipoca → aviso do ecossistema → conteúdo/rodapé.
       (sem isto, o aviso absoluto do PC caía por cima da régua de etapas) */
    display: flex;
    flex-direction: column;
}

html[data-dispositivo="celular"] #bairro,
html[data-dispositivo="tablet"] #bairro { order: 1; }
html[data-dispositivo="celular"] .timeline-container,
html[data-dispositivo="tablet"] .timeline-container { order: 2; }
html[data-dispositivo="celular"] .map-notification,
html[data-dispositivo="tablet"] .map-notification {
    order: 3;
    position: static;
    margin: 10px 10px 0;
    width: auto;
    max-width: none;
    bottom: auto;
    right: auto;
    left: auto;
}
html[data-dispositivo="celular"] .ly-hero,
html[data-dispositivo="celular"] .ly-grid,
html[data-dispositivo="celular"] .ly-footer,
html[data-dispositivo="tablet"] .ly-hero,
html[data-dispositivo="tablet"] .ly-grid,
html[data-dispositivo="tablet"] .ly-footer { order: 4; }

html[data-dispositivo="tablet"] #map-container { padding-top: 118px; }

/* as linhas decorativas do mapa só fazem sentido no quadro fixo do PC */
html[data-dispositivo="celular"] .map-grid-line { display: none; }

/* ------------------------- 2. TOPBAR COMPACTA + FAIXA ROLÁVEL DE MÓDULOS --- */
html[data-dispositivo="celular"] header.ly-topbar,
html[data-dispositivo="tablet"] header.ly-topbar {
    height: auto;
    flex-wrap: wrap;
    row-gap: 0;
    padding: 8px 10px 0;
    gap: 8px;
}

html[data-dispositivo="celular"] .logo-text { font-size: 1.25rem; }
html[data-dispositivo="celular"] .logo-sub { display: none; }        /* ganha largura */
html[data-dispositivo="celular"] .logo-dot { width: 10px; height: 10px; }
html[data-dispositivo="celular"] .user-profile { border-left: none; padding-left: 0; gap: 8px; }
html[data-dispositivo="celular"] .user-profile > span { display: none; }   /* fica só o avatar */
html[data-dispositivo="celular"] .avatar { width: 32px; height: 30px; }

/* a faixa de módulos (filha da topbar) vira UMA linha de rolagem lateral */
html[data-dispositivo="celular"] .nav-modules,
html[data-dispositivo="tablet"] .nav-modules {
    order: 3;
    flex: 1 0 100%;
    max-width: 100%;
    margin: 0 -10px;
    padding: 4px 10px 8px;
    gap: 6px;
    border-top: 1px solid var(--border-tech);
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 10px, #000 calc(100% - 10px), transparent 100%);
    mask-image: linear-gradient(90deg, transparent 0, #000 10px, #000 calc(100% - 10px), transparent 100%);
}

html[data-dispositivo="celular"] .nav-modules::-webkit-scrollbar,
html[data-dispositivo="tablet"] .nav-modules::-webkit-scrollbar { display: none; }

html[data-dispositivo="celular"] .nav-btn,
html[data-dispositivo="tablet"] .nav-btn {
    min-height: 40px;                 /* alvo de toque de verdade */
    padding: 8px 12px;
    font-size: 0.76rem;
    white-space: nowrap;
    border-color: var(--border-tech);
    background: rgba(30, 41, 59, 0.35);
    scroll-snap-align: center;
}

html[data-dispositivo="celular"] .nav-btn.eco-foco { background: rgba(16, 185, 129, 0.14); }

/* utilitários de visibilidade por modo (usados também pelas janelas e cards) */
.so-celular, .so-movel, .so-tablet { display: none !important; }
html[data-dispositivo="celular"] .so-movel,
html[data-dispositivo="celular"] .so-celular { display: inline-flex !important; }
html[data-dispositivo="tablet"] .so-movel,
html[data-dispositivo="tablet"] .so-tablet { display: inline-flex !important; }
html[data-dispositivo="celular"] .so-desktop,
html[data-dispositivo="tablet"] .so-desktop { display: none !important; }

/* --------------------------------------- 3. BARRA DE STATUS COMPACTA ------- */
html[data-dispositivo="celular"] .ly-statusbar,
html[data-dispositivo="tablet"] .ly-statusbar {
    height: auto;
    min-height: 26px;
    gap: 8px 10px;
    padding: 4px 9px calc(4px + env(safe-area-inset-bottom));
    font-size: 0.6rem;
    flex-wrap: wrap;
}

html[data-dispositivo="celular"] .ly-statusbar .sb-right { margin-left: 0; gap: 8px; }
html[data-dispositivo="celular"] #status-relogio { display: none; }        /* relógio sai no bolso */
html[data-dispositivo="celular"] .ly-statusbar .sb-ts { display: none; }   /* data longa sai */
html[data-dispositivo="celular"] .ly-statusbar .badge-longo { display: none; }
html[data-dispositivo="celular"] .ly-demo-badge { padding: 0 5px; letter-spacing: 0.04em; }

/* ==================== 4. O PALCO DA CIDADE (correção principal do celular) ===
   O bug: #bairro virava "static/height:auto" e o canvas (absolute/inset:0)
   ficava com altura zero. Aqui o palco ganha caixa de verdade e o canvas
   volta a ser desenhado — a animação 2.5D aparece no bolso.                  */
html[data-dispositivo="celular"] #bairro,
html[data-dispositivo="tablet"] #bairro {
    position: relative;                /* deixa de ser "static" */
    top: auto;
    left: auto;
    display: block;
    width: calc(100% - 20px);
    margin: 0 10px;
    height: 46vh;                      /* fallback p/ navegador sem svh */
    height: min(46svh, 420px);
    min-height: 240px;
    border: 1px solid var(--border-tech);
    border-radius: 12px;
    background: rgba(3, 7, 18, 0.55);
    overflow: hidden;
    z-index: 2;
}

html[data-dispositivo="tablet"] #bairro {
    width: calc(100% - 32px);
    margin: 0 16px;
    height: min(52svh, 560px);
}

html[data-dispositivo="celular"] #bairro::before,
html[data-dispositivo="tablet"] #bairro::before { inset: 0; border-radius: 12px; }

/* legenda/dica agora vivem DENTRO do palco (antes ficavam fora e sumiam) */
html[data-dispositivo="celular"] .bairro-legenda,
html[data-dispositivo="tablet"] .bairro-legenda { top: 7px; left: 9px; font-size: 0.6rem; }
html[data-dispositivo="celular"] .cidade-dica,
html[data-dispositivo="tablet"] .cidade-dica { bottom: 6px; left: 9px; right: 9px; font-size: 0.56rem; }
html[data-dispositivo="celular"] .cidade-slogan { font-size: clamp(1.05rem, 6vw, 1.6rem); letter-spacing: 0.1em; top: 38%; }

/* botão "⤾ norte" (só existe no toque: no PC o duplo clique já basta) */
.btn-girar-zero {
    position: absolute;
    top: 7px;
    right: 7px;
    z-index: 6;
    padding: 6px 10px;
    font-family: monospace;
    font-size: 0.66rem;
    min-height: 32px;
}

/* os nós dos módulos orbitam a cidade dentro do palco (rótulo só do módulo em foco) */
html[data-dispositivo="celular"] .ly-node,
html[data-dispositivo="tablet"] .ly-node {
    z-index: 5;
    padding: 9px 6px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    cursor: pointer;
}
html[data-dispositivo="celular"] .ly-node__icon { font-size: 0.95rem; }
html[data-dispositivo="celular"] .ly-node__label { display: none; }
html[data-dispositivo="celular"] .ly-node.eco-foco .ly-node__label { display: inline-block; font-size: 0.54rem; }

/* ================= 5. PAINEL DO "EFEITO PIPOCA" LOGO ABAIXO DA CIDADE ======= */
html[data-dispositivo="celular"] .timeline-container,
html[data-dispositivo="tablet"] .timeline-container {
    position: relative;
    left: auto;
    bottom: auto;
    transform: none;
    width: calc(100% - 20px);
    max-width: none;
    margin: 10px 10px 0;
    padding: 10px 12px 8px;
    border-radius: 12px;
    z-index: 10;
}

html[data-dispositivo="celular"] .timeline-header { margin-bottom: 8px; gap: 8px; flex-wrap: wrap; }
html[data-dispositivo="celular"] .timeline-title { font-size: 0.64rem; }
html[data-dispositivo="celular"] .timeline-etapa { font-size: 0.62rem; }
html[data-dispositivo="celular"] .current-year { font-size: 1.15rem; }
html[data-dispositivo="celular"] .timeline-btn { min-height: 34px; padding: 6px 11px; font-size: 0.7rem; }
html[data-dispositivo="celular"] .timeline-legenda { font-size: 0.7rem; margin: 6px 0 2px; }
html[data-dispositivo="celular"] .timeline-foco { font-size: 0.68rem; }
html[data-dispositivo="celular"] .timeline-slider { height: 9px; }
html[data-dispositivo="celular"] .timeline-slider::-webkit-slider-thumb { width: 26px; height: 26px; }
html[data-dispositivo="celular"] .timeline-slider::-moz-range-thumb { width: 24px; height: 24px; }

/* a régua dos 14 passos rola de lado — TODOS continuam tocáveis */
html[data-dispositivo="celular"] .timeline-ticks,
html[data-dispositivo="tablet"] .timeline-ticks {
    justify-content: flex-start;
    gap: 5px;
    margin-top: 8px;
    padding: 0 0 2px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x proximity;
    /* position:relative de propósito: faz do próprio quadro o "offsetParent"
       dos passos, então o JS consegue centralizar o passo da vez com precisão */
    position: relative;
}

html[data-dispositivo="celular"] .timeline-ticks::-webkit-scrollbar { display: none; }

html[data-dispositivo="celular"] .tick-label {
    flex: 0 0 auto;
    min-width: 44px;
    min-height: 44px;                 /* alvo de toque */
    justify-content: center;
    border: 1px solid var(--border-tech);
    background: rgba(30, 41, 59, 0.25);
    scroll-snap-align: center;
}

html[data-dispositivo="celular"] .tick-label .tick-ico { font-size: 1rem; }
html[data-dispositivo="celular"] .tick-label .tick-num { display: inline; font-size: 0.58rem; }
html[data-dispositivo="tablet"] .tick-label { min-width: 40px; min-height: 40px; justify-content: center; }

/* ============ 6. INVENTÁRIO + CENSO: GAVETA INFERIOR (bottom sheet) ========= */
html[data-dispositivo="celular"] .floating-card,
html[data-dispositivo="tablet"] .floating-card {
    position: fixed;
    top: auto;
    left: 0;
    right: 0;
    bottom: -103%;                    /* recolhida fora da tela */
    width: auto;
    max-height: 76vh;
    margin: 0;
    padding-bottom: env(safe-area-inset-bottom);
    border-radius: 14px 14px 0 0;
    border-bottom: none;
    z-index: 70;
    /* a gaveta entra e sai pelo `bottom`, não por transform: assim nenhuma
       outra transformação (nem a de terceiros) pode atropelar a animação */
    transition: bottom 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 -14px 34px -10px rgba(0, 0, 0, 0.8);
}

html[data-dispositivo="celular"] .floating-card.aberto,
html[data-dispositivo="tablet"] .floating-card.aberto { bottom: 0; }

/* alça visual da gaveta */
html[data-dispositivo="celular"] .floating-card::before,
html[data-dispositivo="tablet"] .floating-card::before {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 44px;
    height: 4px;
    border-radius: 2px;
    background: var(--border-tech);
}

html[data-dispositivo="celular"] .floating-card .card-header-drag { cursor: default; padding: 16px 12px 8px; margin-bottom: 6px; }
html[data-dispositivo="celular"] .floating-card .card-title-text { font-size: 0.74rem; }
html[data-dispositivo="celular"] .floating-card .card-body-content { max-height: 56vh; -webkit-overflow-scrolling: touch; }
html[data-dispositivo="celular"] .floating-card .inventory-item { font-size: 0.78rem; min-height: 26px; }
html[data-dispositivo="celular"] .floating-card .control-btn { width: 32px; height: 32px; }
html[data-dispositivo="celular"] .copy-action-btn { min-height: 42px; }
html[data-dispositivo="tablet"] .floating-card .card-body-content { max-height: 52vh; }

/* ============================ 7. JANELAS DE MÓDULO (largura útil + sem arrasto) */
html[data-dispositivo="celular"] .ly-win {
    top: 124px;
    left: 8px;
    right: 8px;
    width: auto;
    max-width: none;
}

html[data-dispositivo="celular"] .ly-win__head { cursor: default; padding: 10px 12px; gap: 8px; font-size: 0.74rem; }
html[data-dispositivo="celular"] .ly-win__head .control-btn { width: 30px; height: 30px; }
html[data-dispositivo="celular"] .ly-win__body { max-height: 58vh; font-size: 0.82rem; -webkit-overflow-scrolling: touch; }
html[data-dispositivo="celular"] .gov-toolbar { gap: 6px; }
html[data-dispositivo="celular"] .gov-select { min-height: 40px; font-size: 0.8rem; }
html[data-dispositivo="celular"] .gov-lvl { width: 30px; height: 30px; }
html[data-dispositivo="celular"] .gov-row { grid-template-columns: 1fr 70px 40px 40px 40px; font-size: 0.7rem; }
html[data-dispositivo="celular"] .gov-sim { font-size: 0.68rem; }
html[data-dispositivo="tablet"] .ly-win { top: 118px; left: 16px; right: 16px; width: auto; }

/* ======================== 8. APRESENTAÇÃO, CARDS E RODAPÉ NO BOLSO ========= */
html[data-dispositivo="celular"] .ly-overlay { padding: 10px 11px 40px; }

html[data-dispositivo="celular"] .ly-overlay-head {
    position: sticky;
    top: 0;
    z-index: 3;
    margin: 0 -11px 12px;
    padding: 10px 11px 12px;
    background: rgba(3, 7, 18, 0.94);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-tech);
    gap: 8px;
    flex-wrap: wrap;
}

html[data-dispositivo="celular"] .ly-overlay-title { font-size: 1.1rem; }
html[data-dispositivo="celular"] .ly-overlay-sub { font-size: 0.76rem; }
html[data-dispositivo="celular"] #btn-fechar-apresentacao { min-height: 40px; }
html[data-dispositivo="celular"] .ly-grid { grid-template-columns: 1fr; gap: 10px; }
html[data-dispositivo="celular"] .ly-hero { padding: 12px 13px; }
html[data-dispositivo="celular"] .ly-hero h2 { font-size: 0.96rem; }
html[data-dispositivo="celular"] .ly-hero p { font-size: 0.82rem; }
html[data-dispositivo="celular"] .ly-card { padding: 12px 13px; }
html[data-dispositivo="celular"] .ly-card:hover { transform: none; }        /* sem hover no toque */
html[data-dispositivo="celular"] .ly-card__actions { flex-wrap: wrap; }
html[data-dispositivo="celular"] .ly-card__actions .ly-btn { min-height: 42px; flex: 1 1 auto; justify-content: center; }
html[data-dispositivo="celular"] .ly-card__bullets { font-size: 0.76rem; }
html[data-dispositivo="celular"] .ly-footer {
    flex-direction: column;
    gap: 4px;
    margin: 16px 10px 0;
    padding: 10px 2px 0;
    font-size: 0.64rem;
}

html[data-dispositivo="tablet"] .ly-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
html[data-dispositivo="tablet"] .ly-overlay { padding: 16px 16px 48px; }
html[data-dispositivo="tablet"] .ly-hero { padding: 14px 16px; }
html[data-dispositivo="tablet"] .nav-btn { min-height: 44px; }
html[data-dispositivo="tablet"] .ly-footer { font-size: 0.7rem; }

/* trava a rolagem do fundo enquanto a apresentação/janela está aberta */
body.sem-rolagem { overflow: hidden !important; }

/* ================= 9. CELULAR DEITADO (paisagem): topbar e palco enxutos ==== */
html[data-dispositivo="celular"][data-paisagem="sim"] #map-container { padding-top: 100px; }
html[data-dispositivo="celular"][data-paisagem="sim"] header.ly-topbar { padding: 4px 10px 0; }
html[data-dispositivo="celular"][data-paisagem="sim"] .nav-btn { min-height: 34px; padding: 5px 10px; }
html[data-dispositivo="celular"][data-paisagem="sim"] #bairro { height: min(64svh, 300px); min-height: 200px; }
html[data-dispositivo="celular"][data-paisagem="sim"] .ly-win { top: 92px; }
html[data-dispositivo="celular"][data-paisagem="sim"] .ly-win__body { max-height: 48vh; }
html[data-dispositivo="celular"][data-paisagem="sim"] .floating-card { max-height: 84vh; }

/* ============================================================================
   10. MENU SUSPENSO DE MÓDULOS (lado esquerdo) — v1.4.0
   Atalho direto: LycceGeo · Lycce Vision · LycceSolar. Reaproveita os tokens e
   a linguagem do card "Inventário do Ecossistema" (.floating-card): mesmo vidro,
   borda, raio e sombra — espelhado para a esquerda. Abre no hover (PC) e no
   clique/toque (seta ▾). No bolso some: a topbar já navega os 13 módulos.
   ============================================================================ */
.menu-modulos {
    position: absolute;
    top: 96px;
    left: 22px;
    width: 268px;
    background: var(--glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-tech);
    border-radius: 10px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.55);
    z-index: 35;
    overflow: hidden;
    transition: box-shadow 0.25s ease;
}

.menu-modulos:hover { box-shadow: 0 16px 34px -8px rgba(0, 0, 0, 0.68); }

.menu-modulos__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
    padding: 10px 12px;
    background: transparent;
    border: none;
    border-bottom: 1px solid var(--border-tech);
    cursor: pointer;
    font-family: inherit;
    color: var(--text-main);
    text-align: left;
}

.menu-modulos__head:focus-visible { outline: 1px solid var(--green-neon); outline-offset: -2px; }

.menu-modulos__chevron {
    color: var(--text-muted);
    font-size: 0.72rem;
    line-height: 1;
    transition: transform 0.25s ease, color 0.25s ease;
}

.menu-modulos[data-aberto="sim"] .menu-modulos__chevron { transform: rotate(180deg); color: var(--green-neon); }
/* o hover só gira a seta em aparelhos COM mouse (no toque ele "prende" e confunde) */
html[data-toque="nao"] .menu-modulos:hover .menu-modulos__chevron { transform: rotate(180deg); color: var(--green-neon); }

.menu-modulos__body {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    padding: 0 12px;
    transition: max-height 0.3s ease, opacity 0.22s ease, padding 0.3s ease;
}

.menu-modulos[data-aberto="sim"] .menu-modulos__body {
    max-height: 460px;
    opacity: 1;
    padding: 10px 12px 12px;
}

/* no PC (mouse) o menu também abre ao passar o cursor; no TOQUE, abre SÓ por clique
   (o hover do iOS/Android "prende" e fazia o menu abrir e cair o foco) */
html[data-toque="nao"] .menu-modulos:hover .menu-modulos__body {
    max-height: 460px;
    opacity: 1;
    padding: 10px 12px 12px;
}

.menu-modulos__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 10px;
    margin-bottom: 6px;
    border: 1px solid transparent;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-main);
    transition: background 0.18s ease, border-color 0.18s ease;
}

.menu-modulos__item:last-child { margin-bottom: 0; }

.menu-modulos__item:hover,
.menu-modulos__item:focus-visible {
    background: rgba(30, 41, 59, 0.45);
    border-color: var(--border-tech);
    outline: none;
}

.menu-modulos__icon {
    font-size: 1.15rem;
    line-height: 1;
    flex: 0 0 auto;
    filter: drop-shadow(0 0 6px currentColor);
}

.menu-modulos__info { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.menu-modulos__nome { font-size: 0.82rem; font-weight: 700; }

.menu-modulos__rota {
    font-size: 0.66rem;
    font-family: monospace;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.menu-modulos__go {
    margin-left: auto;
    color: var(--text-muted);
    font-size: 0.8rem;
    transition: color 0.18s ease, transform 0.18s ease;
}

.menu-modulos__item:hover .menu-modulos__nome { color: var(--green-neon); }
.menu-modulos__item:hover .menu-modulos__go { color: var(--green-neon); transform: translateX(2px); }

/* bolso/tablet: o menu fica NO TOPO, ANTES do palco 2.5D — entra no fluxo da coluna
   (order 0) logo abaixo da topbar, então EMPURRA o mapa para baixo em vez de cobri-lo.
   Assim a ênfase dos módulos fica em cima e o mapa permanece 100% visível. */
html[data-dispositivo="celular"] .menu-modulos,
html[data-dispositivo="tablet"] .menu-modulos {
    position: static;
    top: auto;
    left: auto;
    right: auto;
    order: 0;                          /* primeiro item: acima do palco (order 1) */
    width: calc(100% - 20px);
    margin: 0 10px 10px;
    z-index: 3;
}

html[data-dispositivo="tablet"] .menu-modulos { width: calc(100% - 32px); margin: 0 16px 12px; }

html[data-dispositivo="celular"] .menu-modulos__head,
html[data-dispositivo="tablet"] .menu-modulos__head { padding: 12px; }

html[data-dispositivo="celular"] .menu-modulos__item,
html[data-dispositivo="tablet"] .menu-modulos__item { min-height: 46px; padding: 11px 12px; }

