/* GeoGames — Dünya Sanayi Kartları (oyuna özel stiller; ortak parçalar /shared/gs-game.css) */

:root { --gs-a: #0e7490; --gs-b: #ea580c; }

.wk-stage {
    flex: 1;
    min-height: 0;
    display: grid;
    grid-template-columns: 1fr minmax(300px, 34%);
    gap: 14px;
    padding: 14px;
    padding-bottom: max(14px, env(safe-area-inset-bottom));
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
}

/* ---------- Harita ---------- */
.wk-map-panel {
    position: relative;
    min-height: 0;
    display: flex;
    align-items: center;
    padding: 56px 8px 40px;
    border-radius: 26px;
    background: linear-gradient(180deg, #e0f2fe 0%, #bae6fd 100%);
    border: 4px solid rgba(255, 255, 255, .85);
    box-shadow: 0 16px 36px -14px rgba(2, 20, 60, .6);
    overflow: hidden;
}
.wk-map { display: block; width: 100%; height: auto; max-height: 100%; }

.wk-bg { fill: #d6dde5; stroke: none; pointer-events: none; }
.wk-c {
    fill: #fefce8;
    stroke: #94a3b8;
    stroke-width: .35;
    stroke-linejoin: round;
    cursor: pointer;
    transition: fill .3s;
}
.wk-c:hover { fill: #a5f3fc; }

/* Kıta modu: her kıta hafif farklı tonda */
.wk-c.cont-0 { fill: #fef3c7; }
.wk-c.cont-1 { fill: #e0f2fe; }
.wk-c.cont-2 { fill: #ffedd5; }
.wk-c.cont-3 { fill: #fef9c3; }
.wk-c.cont-4 { fill: #dcfce7; }
.wk-c.cont-5 { fill: #ede9fe; }
.wk-c.cont-x { fill: #e5e7eb; }
.wk-c.hover { fill: #67e8f9; stroke: #155e75; }

/* Isı haritası */
.wk-c.heat-0 { fill: #f8fafc; }
.wk-c.heat-1, .wk-legend .l1 { fill: #ffedd5; background: #ffedd5; }
.wk-c.heat-2, .wk-legend .l2 { fill: #fdba74; background: #fdba74; }
.wk-c.heat-3, .wk-legend .l3 { fill: #f97316; background: #f97316; }
.wk-c.heat-4, .wk-legend .l4 { fill: #c2410c; background: #c2410c; }
.wk-c.heat-5, .wk-legend .l5 { fill: #7c2d12; background: #7c2d12; }
.wk-c.chosen { stroke: #1d4ed8; stroke-width: 1.4; }
.wk-c.chosen-cont { stroke: #1d4ed8; stroke-width: .8; }

.wk-label {
    font: 800 9px var(--ui);
    fill: var(--navy);
    text-anchor: middle;
    paint-order: stroke;
    stroke: #fff;
    stroke-width: 2.4px;
    stroke-linejoin: round;
    pointer-events: none;
}

.wk-legend {
    position: absolute;
    left: 12px;
    bottom: 10px;
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .92);
    font-size: 11.5px;
    font-weight: 800;
    color: var(--navy);
}
.wk-legend[hidden] { display: none; }
.wk-legend i { display: inline-block; width: 18px; height: 10px; border-radius: 3px; }

/* ---------- Yan panel ---------- */
.wk-side {
    position: relative;
    min-height: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    padding: 2px 2px 4px;
}

.wk-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 22px;
    background: linear-gradient(135deg, #fff 0%, #ecfeff 100%);
    border: 3px solid #67e8f9;
    box-shadow: 0 6px 0 rgba(14, 116, 144, .35), 0 16px 30px -16px rgba(2, 20, 60, .6);
}
.wk-card.flip { animation: cardIn .45s cubic-bezier(.2, 1.3, .5, 1); }
@keyframes cardIn { from { transform: rotateY(80deg) scale(.9); opacity: 0; } to { transform: none; opacity: 1; } }
.wk-card-icon {
    flex: none;
    display: grid;
    place-items: center;
    width: 64px;
    height: 64px;
    border-radius: 18px;
    background: #fff;
    box-shadow: inset 0 0 0 2px #a5f3fc;
    font-size: 38px;
}
.wk-card-group { font-size: 11.5px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; color: #0e7490; }
.wk-card-name { font: 700 clamp(20px, 2.6vw, 26px)/1.1 var(--display); color: var(--navy); margin: 2px 0 4px; }
.wk-card-total { font-size: 13px; font-weight: 800; color: var(--muted); }

.wk-question { color: #fff; font-weight: 800; font-size: 14px; line-height: 1.4; }

.wk-conts { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
.wk-conts[hidden] { display: none; }
.wk-cont-btn {
    min-height: 42px;
    padding: 6px 10px;
    border: 0;
    border-radius: 12px;
    background: #fff;
    color: var(--navy);
    font-weight: 900;
    font-size: 14px;
    box-shadow: 0 4px 0 rgba(11, 42, 91, .25);
    touch-action: manipulation;
}
.wk-cont-btn:hover:not(:disabled) { background: #fef3c7; }
.wk-cont-btn.ok { background: #22c55e; color: #fff; }
.wk-cont-btn.no { background: #fca5a5; color: #7f1d1d; }
.wk-cont-btn:disabled:not(.ok):not(.no) { opacity: .55; }

.wk-result {
    padding: 12px 14px;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 5px 0 rgba(11, 42, 91, .22);
}
.wk-result[hidden] { display: none; }
.wk-result h3 { font-size: 12px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 2px 0 6px; }
.wk-result h3 + * { margin-bottom: 10px; }
.wk-top { list-style: none; counter-reset: t; display: grid; gap: 4px; }
.wk-top li {
    counter-increment: t;
    display: flex;
    justify-content: space-between;
    gap: 8px;
    padding: 5px 8px 5px 30px;
    position: relative;
    border-radius: 10px;
    background: #fff7ed;
    font-size: 13.5px;
    align-items: center;
}
.wk-top li::before {
    content: counter(t);
    position: absolute;
    left: 8px;
    font-weight: 900;
    color: #c2410c;
}
.wk-top img { flex: none; width: 22px; height: 16px; object-fit: cover; border-radius: 3px; box-shadow: 0 0 0 1px rgba(0,0,0,.12); }
.wk-top-name { flex: 1; min-width: 0; }
.wk-top-name { font-weight: 900; color: var(--navy); }
.wk-top-val { font-weight: 700; color: var(--muted); white-space: nowrap; }

.wk-bars { display: grid; gap: 4px; }
.wk-bar { display: grid; grid-template-columns: 118px 1fr 52px; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 800; color: var(--navy); }
.wk-bar-track { height: 10px; border-radius: 999px; background: #f1f5f9; overflow: hidden; }
.wk-bar-track i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #fb923c, #c2410c); }
.wk-bar-val { text-align: right; color: var(--muted); }
.wk-bar.other .wk-bar-track i { background: #cbd5e1; }
.wk-bar.other .wk-bar-name { color: var(--muted); }
.wk-note { font-size: 12.5px; font-weight: 700; color: var(--navy); margin-top: 4px; }
.wk-note[hidden] { display: none; }
.wk-src { margin-top: 6px; font-size: 11.5px; font-weight: 700; color: var(--muted); }
.gs-round-meta[hidden] { display: none; }

/* Tur sonu kartı üretim listesinin üstüne binmesin: akış içinde, listenin üstünde ve kompakt durur.
   Önceden yapışkan (sticky) kart "En çok üreten 5" listesini ve payları kapatıyordu. */
.wk-side .gs-round-end { position: static; order: 1; padding: 0; flex-shrink: 0; }
.wk-side #result-box { order: 2; }
.wk-side .gs-round-card { padding: 10px 14px; gap: 4px 12px; border-width: 3px; border-radius: 18px; box-shadow: 0 8px 20px -10px rgba(2, 20, 60, .6); }
.wk-side .gs-round-card > img { width: 48px; height: 48px; }
.wk-side .gs-round-title { font-size: 17px; }
.wk-side .gs-round-answer { font-size: 15px; margin-top: 2px; }
.wk-side .gs-round-points { font-size: 22px; }
.wk-side .gs-next { height: 44px; }
/* Cevap verildikten sonra soru metnine gerek yok: yer listeye kalsın */
.wk-side:has(.gs-round-end:not([hidden])) .wk-question { display: none; }

/* ---------- Duyarlı düzen ---------- */
@media (max-width: 900px), (orientation: portrait) and (max-width: 1100px) {
    .wk-stage { grid-template-columns: 1fr; grid-template-rows: auto 1fr; gap: 10px; padding: 10px; }
    .wk-map-panel { padding: 50px 8px 34px; border-radius: 22px; }
}

@media (max-width: 560px) {
    .wk-card { padding: 10px 12px; gap: 10px; }
    .wk-card-icon { width: 52px; height: 52px; font-size: 30px; }
    .wk-bar { grid-template-columns: 96px 1fr 46px; font-size: 11.5px; }
    .wk-cont-btn { font-size: 13px; }
    .wk-label { font-size: 16px; }
    .wk-conts { grid-template-columns: 1fr 1fr; }
}

@media (max-height: 520px) and (orientation: landscape) {
    .wk-stage { grid-template-columns: 1fr 42%; grid-template-rows: none; gap: 8px; padding: 8px; }
    .wk-map-panel { padding: 44px 8px 30px; }
}
