:root {
    --navy: #122046;
    --green: #5CC696;
    --ink: #0a0d14;
    --text: #F7F9FC;
}

* {
    box-sizing: border-box
}

html, body {
    margin: 0;
    height: 100%;
    background: #0a0d14;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: var(--text)
}

#graph {
    position: fixed;
    inset: 0
}

/* radial space backdrop */
#graph::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background: radial-gradient(ellipse at 50% 45%, #0c172e 0%, #090c19 45%, #000000 100%)
}

.overlay {
    position: fixed;
    pointer-events: none;
    z-index: 5
}

#title {
    top: 26px;
    left: 32px
}

#title h1 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: .2px
}

#title h1 .frog {
    color: var(--green)
}

#title p {
    margin: 6px 0 0;
    font-size: 13px;
    color: #9fb0c8;
    font-weight: 500
}

#counter {
    top: 30px;
    right: 32px;
    text-align: right
}

#counter .big {
    font-size: 30px;
    font-weight: 800;
    color: var(--green);
    line-height: 1
}

#counter .lbl {
    font-size: 12px;
    color: #9fb0c8;
    letter-spacing: .6px;
    text-transform: uppercase
}

/* legend */
#legend {
    left: 32px;
    bottom: 28px;
    display: flex;
    flex-direction: column;
    gap: 7px;
    background: rgba(10, 16, 30, .55);
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, .08);
    backdrop-filter: blur(6px)
}

#legend .row {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 12.5px;
    color: #cdd8e8;
    pointer-events: auto;
    cursor: pointer;
    padding: 2px 6px;
    margin: -2px -6px;
    border-radius: 7px;
    transition: background .12s, color .12s
}

#legend .row:hover {
    background: rgba(255, 255, 255, .07);
    color: #fff
}

#legend .ic {
    width: 16px;
    text-align: center;
    color: #cdd8e8
}

#legend .dot {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    flex: none;
    box-shadow: 0 0 8px currentColor
}

#legend .hd {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #7d8ba3;
    margin-bottom: 3px
}

/* filtre offres Shopware (apparaît quand Shopware est déplié) */
#offerfilter {
    top: 22px;
    left: 50%;
    transform: translateX(-50%) translateY(-12px);
    background: rgba(10, 16, 30, .6);
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 12px;
    padding: 11px 14px;
    backdrop-filter: blur(6px);
    opacity: 0;
    transition: opacity .25s, transform .25s;
}

#offerfilter.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

#offerfilter .of-hd {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #7d8ba3;
    text-align: center;
    margin-bottom: 8px;
}

#offerfilter .of-chips {
    display: flex;
    gap: 8px;
}

.of-chip {
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
    font: inherit;
    font-size: 12.5px;
    font-weight: 600;
    color: #aeb9c9;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 30px;
    padding: 6px 13px;
    transition: all .14s;
}

.of-chip .of-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--c);
    box-shadow: 0 0 7px var(--c);
}

.of-chip.active {
    color: #fff;
    border-color: var(--c);
    background: color-mix(in srgb, var(--c) 18%, transparent);
}

.of-chip:not(.active) {
    opacity: .45;
}

.of-chip:not(.active) .of-dot {
    background: #6b7686;
    box-shadow: none;
}

/* hint */
#hint {
    bottom: 30px;
    right: 32px;
    font-size: 12px;
    color: #7d8ba3;
    text-align: right;
    line-height: 1.7
}

#hint kbd {
    background: rgba(255, 255, 255, .1);
    border-radius: 5px;
    padding: 1px 7px;
    font-size: 11px;
    border: 1px solid rgba(255, 255, 255, .14);
    font-family: inherit
}

/* side panel */
#panel {
    position: fixed;
    top: 0;
    right: 0;
    height: 100%;
    width: 380px;
    z-index: 10;
    background: rgba(9, 14, 26, .86);
    backdrop-filter: blur(14px);
    border-left: 1px solid rgba(255, 255, 255, .1);
    transform: translateX(100%);
    transition: transform .45s cubic-bezier(.2, .8, .2, 1);
    padding: 30px 28px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    overflow-y: auto
}

#panel.open {
    transform: translateX(0)
}

#panel .phead {
    display: flex;
    align-items: center;
    gap: 12px
}

#panel .picon {
    width: 42px;
    height: 42px;
    flex: none;
    border-radius: 11px;
    display: grid;
    place-items: center;
    font-size: 19px;
    color: #0a0d14
}

#panel .ptag {
    align-self: flex-start;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .6px;
    text-transform: uppercase;
    padding: 5px 11px;
    border-radius: 30px
}

#panel h2 {
    margin: 2px 0 0;
    font-size: 23px;
    line-height: 1.2
}

#panel .goal-lbl {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #7d8ba3;
    margin-top: 6px
}

#panel .goal {
    font-size: 15px;
    line-height: 1.55;
    color: #dbe4f1;
    margin: 0
}

#panel .star {
    font-size: 12.5px;
    color: #E8B23A;
    font-weight: 600
}

/* liste des enfants (nœud parent) */
#panel .children-lbl {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #7d8ba3;
    margin-top: 4px;
    margin-bottom: 10px
}

#children-list {
    display: flex;
    flex-direction: column;
    gap: 6px
}

.child-row {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    text-align: left;
    cursor: pointer;
    font: inherit;
    font-size: 14px;
    color: #dbe4f1;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 9px;
    padding: 9px 12px;
    transition: background .12s, border-color .12s, transform .12s
}

.child-row:hover {
    background: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .2);
    transform: translateX(2px)
}

.child-row .cdot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    flex: none;
    box-shadow: 0 0 7px currentColor
}

.child-row .clabel {
    flex: 1
}

.child-row .cstar {
    color: #E8B23A;
    font-size: 12px
}

/* captures thumbnails */
#panel .shots-lbl {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .8px;
    color: #7d8ba3;
    margin-top: 4px
}

#thumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 16px;
}

#thumbs img {
    width: 100%;
    object-fit: cover;
    border-radius: 9px;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, .12);
    transition: transform .15s, border-color .15s;
    background: #0c1326
}

#thumbs img:hover {
    transform: scale(1.015);
    border-color: var(--green)
}

#panel .noshot {
    font-size: 13px;
    color: #6b7686;
    font-style: italic;
    border: 1px dashed rgba(255, 255, 255, .14);
    border-radius: 9px;
    padding: 14px;
    text-align: center
}

#panel .cid {
    margin-top: auto;
    font-size: 11px;
    color: #5a6678;
    font-family: ui-monospace, Menlo, monospace
}

#panel .cid b {
    color: #7d8ba3;
    font-weight: 600
}

#panel .close {
    position: absolute;
    top: 18px;
    right: 18px;
    cursor: pointer;
    pointer-events: auto;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, .18);
    background: transparent;
    color: #9fb0c8;
    font-size: 16px;
    line-height: 1
}

#panel .close:hover {
    background: rgba(255, 255, 255, .08);
    color: #fff
}

.pointer {
    pointer-events: auto
}

/* lightbox */
#lightbox {
    position: fixed;
    inset: 0;
    z-index: 30;
    background: rgba(4, 7, 13, .92);
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(3px)
}

#lightbox.open {
    display: flex
}

#lightbox img {
    max-width: 92vw;
    max-height: 84vh;
    border-radius: 10px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .6);
    border: 1px solid rgba(255, 255, 255, .12)
}

#lightbox .lb-cap {
    position: absolute;
    bottom: 26px;
    left: 0;
    right: 0;
    text-align: center;
    font-size: 14px;
    color: #cdd8e8;
    letter-spacing: .3px
}

#lightbox .lb-close {
    position: absolute;
    top: 22px;
    right: 30px;
    font-size: 26px;
    color: #cdd8e8;
    cursor: pointer;
    line-height: 1;
    background: none;
    border: none
}

#lightbox .lb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 30px;
    color: #fff;
    cursor: pointer;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .16);
    width: 54px;
    height: 54px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    user-select: none
}

#lightbox .lb-nav:hover {
    background: rgba(255, 255, 255, .18)
}

#lightbox .lb-prev {
    left: 28px
}

#lightbox .lb-next {
    right: 28px
}

#lightbox .lb-count {
    position: absolute;
    top: 26px;
    left: 30px;
    font-size: 13px;
    color: #9fb0c8
}
