/* ==================== PRANGERJEV GRAD – zgodbena igra ==================== */
:root {
    --pg-gold: #f2c86b;
    --pg-gold-soft: rgba(242, 200, 107, 0.18);
    --pg-gold-line: rgba(242, 200, 107, 0.35);
    --pg-ember: #f59e0b;
    --pg-blood: #e2574c;
    --pg-leaf: #5ad18a;
    --pg-love: #f472b6;
    --pg-ink: #1a140e;
    --pg-panel: rgba(28, 22, 16, 0.78);
    --pg-panel-solid: #1c1610;
    --pg-parchment: #f6ead2;
    --pg-title-font: "Cinzel", Georgia, "Times New Roman", serif;
}

.pg-game {
    display: none;
    flex-direction: column;
    gap: 12px;
    margin: -14px -16px 0;
    padding: 0 12px 12px;
    min-height: 100%;
    background:
        radial-gradient(ellipse at top, rgba(242, 200, 107, 0.08), transparent 60%),
        linear-gradient(180deg, #120e0a 0%, #0b0907 100%);
    color: var(--pg-parchment);
}

/* ---------- HUD (zgoraj) ---------- */
.pg-hud {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 2px 8px;
    background: linear-gradient(180deg, rgba(14, 11, 8, 0.98) 70%, rgba(14, 11, 8, 0));
    backdrop-filter: blur(6px);
}

.pg-back {
    width: 40px;
    height: 40px;
    flex-shrink: 0;
    border-radius: 12px;
    border: 1px solid var(--pg-gold-line);
    background: var(--pg-panel);
    color: var(--pg-gold);
    font-size: 18px;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.2s ease;
}
.pg-back:active { transform: scale(0.92); }

.pg-hud-title { flex: 1; min-width: 0; }
.pg-chapter-label {
    font-size: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(246, 234, 210, 0.55);
}
.pg-chapter-name {
    font-family: var(--pg-title-font);
    font-size: 16px;
    font-weight: 700;
    color: var(--pg-gold);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-shadow: 0 0 12px rgba(242, 200, 107, 0.35);
}

.pg-date {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px 6px 8px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(242, 200, 107, 0.22), rgba(245, 158, 11, 0.12));
    border: 1px solid var(--pg-gold-line);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
    flex-shrink: 0;
}
.pg-date-icon { font-size: 22px; line-height: 1; }
.pg-date-text { display: flex; flex-direction: column; line-height: 1.1; text-align: right; }
.pg-date-text b { font-size: 13px; color: var(--pg-parchment); }
.pg-date-text small { font-family: var(--pg-title-font); font-size: 15px; font-weight: 700; color: var(--pg-gold); }
.pg-date.is-changing { animation: pgDatePop 0.7s ease; }

@keyframes pgDatePop {
    0% { transform: scale(1); }
    40% { transform: scale(1.12); box-shadow: 0 0 24px rgba(242, 200, 107, 0.6); }
    100% { transform: scale(1); }
}

/* ---------- Viri ---------- */
.pg-resources {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 6px;
}
.pg-res {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    padding: 6px 2px;
    border-radius: 12px;
    background: var(--pg-panel);
    border: 1px solid rgba(242, 200, 107, 0.12);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.pg-res-icon { font-size: 18px; line-height: 1.1; }
.pg-res-val { font-size: 13px; font-weight: 800; color: var(--pg-parchment); font-variant-numeric: tabular-nums; }
.pg-res.is-bump { border-color: var(--pg-gold); box-shadow: 0 0 16px rgba(242, 200, 107, 0.45); animation: pgBump 0.6s ease; }
.pg-res-float {
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 13px;
    font-weight: 900;
    color: var(--pg-leaf);
    text-shadow: 0 1px 4px #000;
    pointer-events: none;
    animation: pgFloatUp 1.4s ease forwards;
}

@keyframes pgBump { 0%, 100% { transform: scale(1); } 35% { transform: scale(1.18); } }
@keyframes pgFloatUp {
    0% { opacity: 0; transform: translate(-50%, 6px); }
    20% { opacity: 1; }
    100% { opacity: 0; transform: translate(-50%, -26px); }
}

/* ---------- Scena (slika) ---------- */
.pg-scene {
    position: relative;
    height: 230px;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--pg-gold-line);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    background: #000;
    flex-shrink: 0;
}
.pg-scene-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.9s ease;
    animation: pgKenBurns 24s ease-in-out infinite alternate;
}
.pg-scene-img.is-hidden { opacity: 0; }

@keyframes pgKenBurns {
    from { transform: scale(1.02) translate(0, 0); }
    to { transform: scale(1.12) translate(-2%, -1%); }
}

.pg-scene-vignette {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, transparent 30%, transparent 55%, rgba(12, 9, 6, 0.95) 100%),
        radial-gradient(ellipse at center, transparent 55%, rgba(0, 0, 0, 0.45) 100%);
    pointer-events: none;
}
.pg-scene-caption {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: var(--pg-parchment);
    background: rgba(0, 0, 0, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);
}
.pg-scene-level {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    color: var(--pg-ink);
    background: var(--pg-gold);
}

/* vremenski učinki */
.pg-fx { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.pg-flake {
    position: absolute;
    top: -20px;
    color: #fff;
    opacity: 0.85;
    animation: pgFall linear infinite;
    text-shadow: 0 0 4px rgba(255, 255, 255, 0.6);
}
@keyframes pgFall {
    to { transform: translateY(270px) translateX(30px) rotate(200deg); }
}

/* ---------- Oder (dialog / naloga) ---------- */
.pg-stage {
    position: relative;
    z-index: 3;
    margin-top: -56px;
    min-height: 170px;
}

/* Dialog (vizualna novela) */
.pg-dialog {
    position: relative;
    padding: 16px 16px 34px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(36, 28, 20, 0.96), rgba(22, 17, 12, 0.98));
    border: 1px solid var(--pg-gold-line);
    box-shadow: 0 -6px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    cursor: pointer;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    animation: pgSlideUp 0.35s ease;
}
.pg-dialog-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}
.pg-dialog.is-self .pg-dialog-head { flex-direction: row-reverse; text-align: right; }

.pg-portrait {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    border-radius: 50%;
    border: 2px solid var(--pg-gold);
    box-shadow: 0 0 0 3px rgba(242, 200, 107, 0.15), 0 6px 16px rgba(0, 0, 0, 0.6);
    background: radial-gradient(circle at 30% 30%, #3b2f22, #17120c);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    overflow: hidden;
    margin-top: -36px;
    animation: pgPortraitIn 0.4s ease;
}
.pg-portrait img { width: 100%; height: 100%; object-fit: cover; }
.pg-portrait.is-love { border-color: var(--pg-love); box-shadow: 0 0 0 3px rgba(244, 114, 182, 0.2), 0 6px 16px rgba(0, 0, 0, 0.6); }
.pg-portrait.is-villain { border-color: var(--pg-blood); }
.pg-portrait.is-narrator { border-color: rgba(246, 234, 210, 0.5); }

@keyframes pgPortraitIn {
    from { opacity: 0; transform: translateY(10px) scale(0.85); }
    to { opacity: 1; transform: none; }
}

.pg-speaker {
    font-family: var(--pg-title-font);
    font-weight: 700;
    font-size: 15px;
    color: var(--pg-gold);
}
.pg-speaker small {
    display: block;
    font-family: inherit;
    font-size: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: rgba(246, 234, 210, 0.5);
    font-weight: 600;
}
.pg-dialog-text {
    font-size: 16px;
    line-height: 1.55;
    color: var(--pg-parchment);
    min-height: 50px;
}
.pg-dialog-text em { color: rgba(246, 234, 210, 0.6); font-style: italic; }
.pg-dialog-text.is-narrator { font-style: italic; color: #e7dcc4; }

.pg-dialog-foot {
    position: absolute;
    left: 16px;
    right: 16px;
    bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.pg-dots { display: flex; gap: 4px; }
.pg-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(246, 234, 210, 0.2); transition: all 0.3s ease; }
.pg-dot.is-done { background: var(--pg-gold); }
.pg-dot.is-now { width: 16px; border-radius: 4px; background: var(--pg-gold); }
.pg-next-hint { font-size: 12px; color: var(--pg-gold); animation: pgBlink 1.4s ease-in-out infinite; }
.pg-skip {
    border: none;
    background: none;
    color: rgba(246, 234, 210, 0.45);
    font-size: 11px;
    padding: 4px 6px;
    cursor: pointer;
}

@keyframes pgBlink { 0%, 100% { opacity: 0.35; } 50% { opacity: 1; } }
@keyframes pgSlideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* Kartica naloge */
.pg-task {
    padding: 16px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(36, 28, 20, 0.97), rgba(22, 17, 12, 0.99));
    border: 1px solid var(--pg-gold-line);
    box-shadow: 0 -6px 30px rgba(0, 0, 0, 0.5);
    animation: pgSlideUp 0.35s ease;
}
.pg-task-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}
.pg-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.3px;
    background: var(--pg-gold-soft);
    color: var(--pg-gold);
    border: 1px solid var(--pg-gold-line);
}
.pg-chip.is-reward { background: rgba(90, 209, 138, 0.15); color: var(--pg-leaf); border-color: rgba(90, 209, 138, 0.4); }
.pg-task-q {
    font-size: 17px;
    font-weight: 700;
    line-height: 1.45;
    margin-bottom: 14px;
    color: #fff8e8;
}
.pg-replay {
    border: none;
    background: none;
    color: rgba(246, 234, 210, 0.5);
    font-size: 12px;
    cursor: pointer;
    padding: 0;
    margin-bottom: 10px;
}

.pg-options { display: grid; gap: 10px; }
.pg-opt {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 13px 14px;
    border-radius: 14px;
    border: 1px solid rgba(242, 200, 107, 0.22);
    background: linear-gradient(180deg, rgba(56, 44, 30, 0.9), rgba(38, 30, 21, 0.95));
    color: var(--pg-parchment);
    font-size: 15px;
    font-weight: 600;
    text-align: left;
    line-height: 1.35;
    cursor: pointer;
    transition: transform 0.12s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}
.pg-opt:active { transform: scale(0.98); }
.pg-opt-letter {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--pg-title-font);
    font-weight: 800;
    font-size: 13px;
    color: var(--pg-ink);
    background: var(--pg-gold);
}
.pg-opt:disabled { cursor: default; }
.pg-opt.is-pending { border-color: var(--pg-gold); box-shadow: 0 0 14px rgba(242, 200, 107, 0.35); }
.pg-opt.is-wrong {
    border-color: var(--pg-blood);
    background: linear-gradient(180deg, rgba(120, 36, 30, 0.6), rgba(70, 22, 18, 0.7));
    opacity: 0.7;
    animation: pgShake 0.45s ease;
}
.pg-opt.is-wrong .pg-opt-letter { background: var(--pg-blood); color: #fff; }
.pg-opt.is-correct, .pg-opt.is-reveal {
    border-color: var(--pg-leaf);
    background: linear-gradient(180deg, rgba(30, 110, 66, 0.65), rgba(18, 70, 42, 0.75));
    box-shadow: 0 0 20px rgba(90, 209, 138, 0.4);
}
.pg-opt.is-correct .pg-opt-letter, .pg-opt.is-reveal .pg-opt-letter { background: var(--pg-leaf); }
.pg-opt.is-reveal { animation: pgPulseGreen 1.2s ease-in-out infinite; }

@keyframes pgShake {
    0%, 100% { transform: translateX(0); }
    20% { transform: translateX(-8px); }
    40% { transform: translateX(7px); }
    60% { transform: translateX(-5px); }
    80% { transform: translateX(3px); }
}
@keyframes pgPulseGreen { 0%, 100% { box-shadow: 0 0 8px rgba(90, 209, 138, 0.3); } 50% { box-shadow: 0 0 26px rgba(90, 209, 138, 0.7); } }

/* ---------- Mini igra (fizično delo) ---------- */
.pg-mini {
    position: relative;
    height: 240px;
    border-radius: 16px;
    overflow: hidden;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
    cursor: crosshair;
    border: 1px solid rgba(242, 200, 107, 0.3);
    box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.6);
}
.pg-mini--les { background: radial-gradient(ellipse at 50% 80%, #6b4a2b 0%, #3a2716 55%, #1d140b 100%); }
.pg-mini--hrana { background: repeating-linear-gradient(170deg, #5a3d22 0 18px, #4a3119 18px 36px); }
.pg-mini--zemlja { background: repeating-linear-gradient(90deg, #614227 0 22px, #553920 22px 44px); }
.pg-mini--kamen { background: radial-gradient(ellipse at 50% 70%, #6b6b6b 0%, #3f3d3a 55%, #22201d 100%); }
.pg-mini--zlatniki { background: radial-gradient(ellipse at 50% 60%, #6d5320 0%, #3b2c10 60%, #1d1608 100%); }
.pg-mini--delavci { background: radial-gradient(ellipse at 50% 60%, #3f5a2f 0%, #263a1c 60%, #121c0d 100%); }
.pg-mini--zima { filter: saturate(0.6) brightness(1.05); }

.pg-mini-tool {
    position: absolute;
    left: 50%;
    top: 44%;
    transform: translate(-50%, -50%);
    font-size: 72px;
    filter: drop-shadow(0 8px 12px rgba(0, 0, 0, 0.6));
    pointer-events: none;
    transition: transform 0.1s ease, left 0.1s ease, top 0.1s ease;
}
.pg-mini-tool.is-hit { animation: pgToolHit 0.28s ease; }
@keyframes pgToolHit {
    0% { transform: translate(-50%, -50%) rotate(0deg) scale(1); }
    40% { transform: translate(-50%, -40%) rotate(-38deg) scale(1.15); }
    100% { transform: translate(-50%, -50%) rotate(0deg) scale(1); }
}

.pg-mini-hint {
    position: absolute;
    left: 0;
    right: 0;
    top: 12px;
    text-align: center;
    font-size: 13px;
    font-weight: 700;
    color: rgba(255, 248, 232, 0.85);
    text-shadow: 0 1px 4px #000;
    pointer-events: none;
}
.pg-mini-hand {
    position: absolute;
    left: 50%;
    top: 68%;
    font-size: 34px;
    pointer-events: none;
    animation: pgHandSwipe 1.6s ease-in-out infinite;
}
.pg-mini-hand.is-tap { animation: pgHandTap 1s ease-in-out infinite; }
@keyframes pgHandSwipe {
    0%, 100% { transform: translateX(-90px) rotate(-10deg); opacity: 0.9; }
    50% { transform: translateX(50px) rotate(10deg); opacity: 0.9; }
}
@keyframes pgHandTap {
    0%, 100% { transform: translate(-50%, 0) scale(1); }
    50% { transform: translate(-50%, 8px) scale(0.85); }
}

.pg-mini-item {
    position: absolute;
    font-size: 26px;
    pointer-events: none;
    transform: translate(-50%, -50%);
    animation: pgItemPop 0.4s cubic-bezier(.2, 1.6, .4, 1);
    filter: drop-shadow(0 3px 4px rgba(0, 0, 0, 0.5));
}
@keyframes pgItemPop {
    from { transform: translate(-50%, -50%) scale(0); }
    to { transform: translate(-50%, -50%) scale(1); }
}

.pg-particle {
    position: absolute;
    font-size: 18px;
    pointer-events: none;
    animation: pgParticle 0.7s ease-out forwards;
}
@keyframes pgParticle {
    from { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    to { opacity: 0; transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(0.4) rotate(var(--rot)); }
}
.pg-trail {
    position: absolute;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 236, 180, 0.9), rgba(242, 200, 107, 0));
    pointer-events: none;
    transform: translate(-50%, -50%);
    animation: pgTrail 0.45s ease-out forwards;
}
@keyframes pgTrail { to { opacity: 0; transform: translate(-50%, -50%) scale(2.2); } }

.pg-mini-progress {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    pointer-events: none;
}
.pg-mini-bar {
    flex: 1;
    height: 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
    overflow: hidden;
}
.pg-mini-fill {
    height: 100%;
    width: 0%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--pg-ember), var(--pg-gold));
    box-shadow: 0 0 10px rgba(242, 200, 107, 0.6);
    transition: width 0.2s ease;
}
.pg-mini-count {
    font-family: var(--pg-title-font);
    font-weight: 800;
    font-size: 15px;
    color: #fff;
    text-shadow: 0 1px 4px #000;
    min-width: 52px;
    text-align: right;
}
.pg-mini.is-done { box-shadow: inset 0 0 60px rgba(90, 209, 138, 0.5); border-color: var(--pg-leaf); }
.pg-mini.is-done .pg-mini-fill { background: linear-gradient(90deg, #2fae69, var(--pg-leaf)); }
.pg-mini-done {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--pg-title-font);
    font-size: 26px;
    font-weight: 800;
    color: #fff;
    text-shadow: 0 0 20px rgba(90, 209, 138, 0.9), 0 2px 6px #000;
    animation: pgItemPop 0.4s ease;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.4);
    z-index: 50;
}

/* ==================== SEKANJE DRV (Wood Chopping Scene) ==================== */
.pg-mini--sekanje {
    background: radial-gradient(circle at 50% 25%, #4e341b 0%, #2e1e0f 50%, #150d06 100%) !important;
    position: relative;
    height: 275px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}

/* Woodcutter environment background */
.pg-wood-env {
    position: absolute;
    inset: 0;
    pointer-events: none;
}
.pg-wood-ground {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 65px;
    background: linear-gradient(180deg, #2b1c0e 0%, #170d05 100%);
    border-top: 1px solid rgba(139, 90, 43, 0.4);
}
.pg-wood-ground-chips {
    position: absolute;
    bottom: 4px;
    left: 8%;
    right: 8%;
    height: 25px;
    background: radial-gradient(ellipse at 50% 80%, rgba(212, 163, 106, 0.18) 0%, transparent 70%);
}

/* Wood piles on sides */
.pg-wood-pile {
    position: absolute;
    bottom: 38px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    opacity: 0.85;
}
.pg-wood-pile--left {
    left: 14px;
}
.pg-wood-pile--right {
    right: 14px;
    align-items: flex-end;
}
.pg-pile-log {
    display: inline-block;
    height: 14px;
    width: 36px;
    background: linear-gradient(90deg, #603d1e 0%, #87572d 50%, #4a2d14 100%);
    border-radius: 4px;
    border: 1px solid #361f0c;
    box-shadow: 0 2px 5px rgba(0,0,0,0.5);
    position: relative;
}
.pg-pile-log::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 6px;
    border-radius: 50%;
    background: radial-gradient(circle, #dfb479 0%, #7e572d 80%);
}

/* Chopping Station: Stump + Log */
.pg-chopping-station {
    position: absolute;
    bottom: 34px;
    left: 50%;
    transform: translateX(-50%);
    width: 140px;
    height: 180px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    pointer-events: none;
    transition: transform 0.05s ease;
}
.pg-chopping-station.is-shaking {
    animation: pgChopImpactShake 0.22s ease-out;
}
@keyframes pgChopImpactShake {
    0% { transform: translateX(-50%) translateY(0) rotate(0deg); }
    20% { transform: translateX(-52%) translateY(5px) rotate(-1.5deg); }
    40% { transform: translateX(-48%) translateY(-3px) rotate(1.5deg); }
    60% { transform: translateX(-51%) translateY(2px) rotate(-0.5deg); }
    100% { transform: translateX(-50%) translateY(0) rotate(0deg); }
}

/* The Stump (Tnalo) */
.pg-stump {
    position: relative;
    width: 124px;
    height: 64px;
    background: linear-gradient(90deg, #2a180b 0%, #4b2d18 20%, #684124 50%, #4b2d18 80%, #201207 100%);
    border-radius: 0 0 16px 16px;
    box-shadow: 0 12px 24px rgba(0,0,0,0.7), inset 0 2px 4px rgba(255,255,255,0.1);
}
.pg-stump-top {
    position: absolute;
    top: -15px;
    left: 0;
    width: 124px;
    height: 30px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 50%, #c89e65 0%, #a47840 40%, #7a5427 75%, #422b13 100%);
    border: 2px solid #36200d;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.4);
    display: flex;
    align-items: center;
    justify-content: center;
}
.pg-stump-rings {
    width: 80%;
    height: 70%;
    border-radius: 50%;
    border: 1px dashed rgba(60, 36, 14, 0.45);
}
.pg-stump-rings::after {
    content: '';
    position: absolute;
    width: 45%;
    height: 40%;
    border-radius: 50%;
    border: 1px dotted rgba(60, 36, 14, 0.35);
}

/* Target Log (Poleno na tnalu) */
.pg-target-log-container {
    position: relative;
    width: 58px;
    height: 96px;
    margin-bottom: -6px;
    z-index: 2;
}
.pg-target-log {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, #382111 0%, #5d381c 25%, #7e4e29 50%, #5d381c 75%, #2a170a 100%);
    border-radius: 5px 5px 4px 4px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5), inset 0 1px 2px rgba(255,255,255,0.15);
    transition: transform 0.1s ease;
    overflow: hidden;
}
.pg-target-log.is-spawning {
    animation: pgLogBounceDrop 0.38s cubic-bezier(.34, 1.56, .64, 1);
}
@keyframes pgLogBounceDrop {
    0% { transform: translateY(-130px) scale(0.75); opacity: 0; }
    70% { transform: translateY(6px) scale(1.06); opacity: 1; }
    100% { transform: translateY(0) scale(1); opacity: 1; }
}

.pg-log-top-rings {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 16px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 50%, #e2b981 0%, #bc8d50 45%, #885f2f 80%, #4a3015 100%);
    border: 1.5px solid #36200d;
}
.pg-log-cut-mark {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 3px;
    height: 0px;
    background: linear-gradient(180deg, #170b04 0%, #3e1b07 100%);
    border-radius: 2px;
    box-shadow: 0 0 3px rgba(0,0,0,0.8);
    transition: height 0.15s ease, width 0.15s ease;
}

/* Split halves */
.pg-log-half {
    position: absolute;
    width: 29px;
    height: 96px;
    top: 0;
    display: none;
    background: linear-gradient(90deg, #cda167 0%, #82582b 40%, #442a12 100%);
    border-radius: 4px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.6);
}
.pg-log-half--left {
    left: 0;
    border-top-left-radius: 5px;
    border-bottom-left-radius: 4px;
    transform-origin: bottom left;
}
.pg-log-half--right {
    right: 0;
    border-top-right-radius: 5px;
    border-bottom-right-radius: 4px;
    background: linear-gradient(270deg, #cda167 0%, #82582b 40%, #442a12 100%);
    transform-origin: bottom right;
}
.pg-log-half--left.is-splitting {
    display: block;
    animation: pgSplitLeft 0.48s cubic-bezier(.12, .82, .24, 1) forwards;
}
.pg-log-half--right.is-splitting {
    display: block;
    animation: pgSplitRight 0.48s cubic-bezier(.12, .82, .24, 1) forwards;
}
@keyframes pgSplitLeft {
    0% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
    100% { transform: translate(-75px, 35px) rotate(-45deg); opacity: 0; }
}
@keyframes pgSplitRight {
    0% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
    100% { transform: translate(75px, 35px) rotate(45deg); opacity: 0; }
}

/* Axe Actor */
.pg-chop-axe-actor {
    position: absolute;
    top: 25px;
    left: 55%;
    transform-origin: 20px 85px;
    transform: rotate(20deg);
    width: 100px;
    height: 110px;
    pointer-events: none;
    z-index: 10;
    transition: transform 0.12s ease-out;
}
.pg-chop-axe-actor.is-idle {
    animation: pgAxeIdle 1.8s ease-in-out infinite alternate;
}
@keyframes pgAxeIdle {
    0% { transform: rotate(18deg) translateY(0); }
    100% { transform: rotate(25deg) translateY(-8px); }
}
.pg-chop-axe-actor.is-chopping-down {
    animation: pgAxeChopDown 0.22s cubic-bezier(.22, 1, .36, 1) forwards;
}
@keyframes pgAxeChopDown {
    0% { transform: rotate(35deg) translate(10px, -20px); }
    60% { transform: rotate(-48deg) translate(-28px, 62px); }
    80% { transform: rotate(-42deg) translate(-26px, 58px); }
    100% { transform: rotate(20deg) translate(0, 0); }
}

/* Crafted Axe Handle & Head */
.pg-axe-handle {
    position: absolute;
    width: 10px;
    height: 95px;
    left: 45px;
    top: 15px;
    background: linear-gradient(90deg, #5c381c 0%, #8c572b 40%, #b37742 70%, #5c381c 100%);
    border-radius: 5px;
    box-shadow: 2px 2px 6px rgba(0,0,0,0.5);
    transform: rotate(-25deg);
    transform-origin: bottom center;
}
.pg-axe-head {
    position: absolute;
    width: 48px;
    height: 38px;
    left: 14px;
    top: 12px;
    background: linear-gradient(135deg, #4b5563 0%, #9ca3af 45%, #d1d5db 75%, #374151 100%);
    clip-path: polygon(100% 15%, 85% 0%, 25% 10%, 0% 50%, 15% 95%, 80% 85%, 100% 70%);
    filter: drop-shadow(0 3px 6px rgba(0,0,0,0.6));
}
.pg-axe-blade-edge {
    position: absolute;
    left: 0;
    top: 30%;
    bottom: 20%;
    width: 6px;
    background: #ffffff;
    box-shadow: 0 0 6px rgba(255, 255, 255, 0.9);
    border-radius: 2px;
}
.pg-axe-whoosh-trail {
    position: absolute;
    inset: -20px;
    border-radius: 50%;
    border-right: 4px solid rgba(255, 235, 180, 0.7);
    opacity: 0;
    pointer-events: none;
    transform: rotate(-10deg);
}
.pg-chop-axe-actor.is-chopping-down .pg-axe-whoosh-trail {
    animation: pgWhooshFade 0.22s ease-out;
}
@keyframes pgWhooshFade {
    0% { opacity: 0; transform: rotate(10deg) scale(0.9); }
    50% { opacity: 0.9; transform: rotate(-40deg) scale(1.1); }
    100% { opacity: 0; transform: rotate(-70deg) scale(1.2); }
}

/* Wood chips & splinters */
.pg-wood-chip {
    position: absolute;
    pointer-events: none;
    border-radius: 2px;
    z-index: 20;
    animation: pgWoodChipFly 0.55s cubic-bezier(.25, .46, .45, .94) forwards;
}
@keyframes pgWoodChipFly {
    0% {
        opacity: 1;
        transform: translate(0, 0) rotate(0deg) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(var(--vx), var(--vy)) rotate(var(--vrot)) scale(0.4);
    }
}

/* Impact Spark Flash */
.pg-impact-flash {
    position: absolute;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: radial-gradient(circle, #ffffff 0%, rgba(255, 220, 120, 0.8) 40%, transparent 70%);
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 25;
    animation: pgFlashPop 0.25s ease-out forwards;
}
@keyframes pgFlashPop {
    0% { transform: translate(-50%, -50%) scale(0.3); opacity: 1; }
    50% { transform: translate(-50%, -50%) scale(1.4); opacity: 0.9; }
    100% { transform: translate(-50%, -50%) scale(2); opacity: 0; }
}

/* Floating hit text */
.pg-hit-text {
    position: absolute;
    font-family: var(--pg-title-font);
    font-weight: 800;
    font-size: 17px;
    color: #ffd166;
    text-shadow: 0 2px 6px rgba(0,0,0,0.9), 0 0 10px rgba(255, 209, 102, 0.6);
    pointer-events: none;
    z-index: 30;
    animation: pgHitFloat 0.65s cubic-bezier(.17, .89, .32, 1.28) forwards;
}
@keyframes pgHitFloat {
    0% { opacity: 0; transform: translate(-50%, 0) scale(0.6); }
    30% { opacity: 1; transform: translate(-50%, -20px) scale(1.15); }
    100% { opacity: 0; transform: translate(-50%, -45px) scale(0.9); }
}

/* Swipe Slash Guide Prompt */
.pg-swipe-slash-guide {
    position: absolute;
    top: 14px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    pointer-events: none;
    z-index: 15;
    transition: opacity 0.3s ease;
}
.pg-swipe-slash-guide.is-hidden {
    opacity: 0;
    pointer-events: none;
}
.pg-swipe-guide-arrow {
    font-size: 26px;
    animation: pgSwipeArrowDown 1.3s ease-in-out infinite;
    filter: drop-shadow(0 2px 8px rgba(242, 200, 107, 0.7));
}
@keyframes pgSwipeArrowDown {
    0% { transform: translateY(-8px); opacity: 0.4; }
    50% { transform: translateY(6px); opacity: 1; }
    100% { transform: translateY(14px); opacity: 0.2; }
}
@keyframes pgSwipeArrowSide {
    0% { transform: translateX(-15px); opacity: 0.3; }
    50% { transform: translateX(0px); opacity: 1; }
    100% { transform: translateX(15px); opacity: 0.3; }
}
.pg-swipe-guide-text {
    font-family: var(--pg-title-font);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #fff8e8;
    background: rgba(22, 17, 12, 0.85);
    padding: 3px 12px;
    border-radius: 999px;
    border: 1px solid rgba(242, 200, 107, 0.4);
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    text-shadow: 0 1px 3px #000;
}

/* FX layer */
.pg-fx-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 30;
}

/* ==================== SEJANJE (Sowing Field Scene) ==================== */
.pg-mini--sejanje {
    background: linear-gradient(180deg, #3d2314 0%, #2b180d 40%, #1a0e07 100%) !important;
    position: relative;
    height: 260px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.pg-field-furrows {
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(175deg, #442716 0 16px, #2a170c 16px 32px);
    opacity: 0.85;
    pointer-events: none;
}
.pg-sprouts-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
}
.pg-sprout-item {
    position: absolute;
    font-size: 22px;
    transform: translate(-50%, -50%) scale(0);
    animation: pgSproutPop 0.4s cubic-bezier(.34, 1.56, .64, 1) forwards;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.6));
}
@keyframes pgSproutPop {
    0% { transform: translate(-50%, -50%) scale(0) rotate(-15deg); opacity: 0; }
    70% { transform: translate(-50%, -50%) scale(1.25) rotate(5deg); opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(1) rotate(0deg); opacity: 1; }
}
.pg-sow-hand {
    position: absolute;
    font-size: 48px;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 10;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.6));
    transition: transform 0.1s ease;
}
.pg-golden-seed {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: radial-gradient(circle, #ffe066 0%, #d4a017 100%);
    box-shadow: 0 0 8px #ffd166;
    pointer-events: none;
    animation: pgSeedDrop 0.5s ease-out forwards;
}
@keyframes pgSeedDrop {
    0% { transform: translate(0, 0) scale(1.4); opacity: 1; }
    100% { transform: translate(var(--sdx), var(--sdy)) scale(0.6); opacity: 0; }
}

/* ==================== KAMEN (Quarry Scene) ==================== */
.pg-mini--kamen {
    background: radial-gradient(circle at 50% 30%, #474747 0%, #2b2b2b 55%, #141414 100%) !important;
    position: relative;
    height: 260px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.pg-rock-env {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 35px;
    pointer-events: none;
}
.pg-rock-boulder {
    width: 120px;
    height: 85px;
    background: radial-gradient(ellipse at 35% 30%, #7e7e7e 0%, #525252 50%, #2e2e2e 90%);
    border-radius: 45% 55% 40% 60% / 55% 45% 55% 45%;
    border: 2px solid #242424;
    box-shadow: 0 14px 28px rgba(0,0,0,0.8), inset 0 3px 6px rgba(255,255,255,0.2);
    position: relative;
    transition: transform 0.1s ease;
}
.pg-rock-boulder.is-shaking {
    animation: pgRockShake 0.22s ease-out;
}
@keyframes pgRockShake {
    0% { transform: translate(0, 0); }
    25% { transform: translate(-4px, 3px); }
    50% { transform: translate(4px, -2px); }
    75% { transform: translate(-2px, 1px); }
    100% { transform: translate(0, 0); }
}
.pg-pickaxe-actor {
    position: absolute;
    top: 20px;
    left: 56%;
    font-size: 58px;
    transform: rotate(20deg);
    pointer-events: none;
    z-index: 10;
    filter: drop-shadow(0 6px 10px rgba(0,0,0,0.7));
    transition: transform 0.12s ease;
}
.pg-pickaxe-actor.is-idle {
    animation: pgAxeIdle 1.8s ease-in-out infinite alternate;
}
.pg-pickaxe-actor.is-striking {
    animation: pgPickStrike 0.22s cubic-bezier(.2, .9, .3, 1.2) forwards;
}
@keyframes pgPickStrike {
    0% { transform: rotate(35deg) translate(10px, -20px); }
    60% { transform: rotate(-45deg) translate(-30px, 60px); }
    100% { transform: rotate(20deg) translate(0, 0); }
}
.pg-stone-chip {
    position: absolute;
    width: 6px;
    height: 6px;
    background: #8e8e8e;
    border-radius: 2px;
    pointer-events: none;
    animation: pgStoneFly 0.5s ease-out forwards;
}
@keyframes pgStoneFly {
    0% { transform: translate(0, 0); opacity: 1; }
    100% { transform: translate(var(--vx), var(--vy)) rotate(var(--vrot)); opacity: 0; }
}

/* Boulder cracks */
.pg-boulder-crack {
    position: absolute;
    top: 20%;
    left: 45%;
    width: 3px;
    height: 0px;
    background: #151515;
    box-shadow: 0 0 2px #000;
    border-radius: 2px;
    transition: height 0.15s ease, width 0.15s ease;
}

/* ==================== ZETEV (Harvesting with Sickle) ==================== */
.pg-mini--zetev {
    background: radial-gradient(circle at 50% 20%, #684f18 0%, #3d2f0f 50%, #1c1505 100%) !important;
    position: relative;
    height: 275px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.pg-wheat-field {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 120px;
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    padding-bottom: 25px;
    pointer-events: none;
}
.pg-wheat-cluster {
    font-size: 42px;
    transform-origin: bottom center;
    animation: pgWheatSway 2.5s ease-in-out infinite alternate;
    filter: drop-shadow(0 4px 6px rgba(0,0,0,0.5));
}
.pg-wheat-cluster:nth-child(2) { animation-delay: 0.4s; }
.pg-wheat-cluster:nth-child(3) { animation-delay: 0.8s; }
.pg-wheat-cluster:nth-child(4) { animation-delay: 1.2s; }
@keyframes pgWheatSway {
    0% { transform: rotate(-6deg); }
    100% { transform: rotate(6deg); }
}
.pg-sickle-actor {
    position: absolute;
    top: 30px;
    left: 50%;
    transform: translate(-50%, 0) rotate(15deg);
    width: 90px;
    height: 90px;
    pointer-events: none;
    z-index: 15;
    transition: transform 0.12s ease-out;
}
.pg-sickle-actor.is-idle {
    animation: pgSickleHover 1.8s ease-in-out infinite alternate;
}
@keyframes pgSickleHover {
    0% { transform: translate(-50%, 0) rotate(10deg); }
    100% { transform: translate(-50%, -8px) rotate(22deg); }
}
.pg-sickle-actor.is-slashing {
    animation: pgSickleSlash 0.24s cubic-bezier(.2, .9, .3, 1.2) forwards;
}
@keyframes pgSickleSlash {
    0% { transform: translate(-20%, -15px) rotate(-35deg) scale(0.9); }
    50% { transform: translate(-70%, 25px) rotate(50deg) scale(1.15); }
    100% { transform: translate(-50%, 0) rotate(15deg) scale(1); }
}
.pg-sickle-blade {
    position: absolute;
    width: 65px;
    height: 65px;
    border: 8px solid transparent;
    border-top: 8px solid #f3f4f6;
    border-right: 8px solid #9ca3af;
    border-radius: 50%;
    transform: rotate(45deg);
    filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.8));
}
.pg-sickle-handle {
    position: absolute;
    width: 12px;
    height: 48px;
    bottom: 5px;
    right: 18px;
    background: linear-gradient(90deg, #4b2d18 0%, #87572d 50%, #4b2d18 100%);
    border-radius: 6px;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.6);
    transform: rotate(-35deg);
}
.pg-wheat-chaff {
    position: absolute;
    font-size: 18px;
    pointer-events: none;
    animation: pgChaffFly 0.5s ease-out forwards;
}
@keyframes pgChaffFly {
    0% { transform: translate(0, 0) scale(1); opacity: 1; }
    100% { transform: translate(var(--vcx), var(--vcy)) rotate(var(--vcrot)) scale(0.4); opacity: 0; }
}
.pg-sheaf-pile {
    position: absolute;
    bottom: 30px;
    right: 12px;
    display: flex;
    flex-direction: column-reverse;
    gap: 3px;
    pointer-events: none;
}
.pg-sheaf-item {
    font-size: 26px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.6));
    animation: pgItemPop 0.35s cubic-bezier(.34, 1.56, .64, 1);
}

/* ==================== ORANJE (Plowing Field) ==================== */
.pg-mini--oranje {
    background: radial-gradient(circle at 50% 20%, #52351d 0%, #301d0e 55%, #180d05 100%) !important;
    position: relative;
    height: 275px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.pg-plow-ground {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 95px;
    background: repeating-linear-gradient(175deg, #462916 0 18px, #2a160a 18px 36px);
    border-top: 2px solid rgba(139, 90, 43, 0.5);
    box-shadow: inset 0 10px 20px rgba(0,0,0,0.7);
}
.pg-plow-actor {
    position: absolute;
    bottom: 38px;
    left: 30%;
    transform: translate(-50%, 0);
    font-size: 64px;
    filter: drop-shadow(0 8px 12px rgba(0,0,0,0.7));
    pointer-events: none;
    z-index: 10;
    transition: transform 0.1s ease, left 0.1s ease;
}
.pg-plow-actor.is-plowing {
    animation: pgPlowShake 0.2s ease infinite alternate;
}
@keyframes pgPlowShake {
    0% { transform: translate(-50%, 0) rotate(0deg); }
    100% { transform: translate(-50%, -3px) rotate(-4deg); }
}
.pg-furrow-mark {
    position: absolute;
    bottom: 42px;
    height: 12px;
    border-radius: 6px;
    background: linear-gradient(180deg, #160a03 0%, #3d2211 100%);
    box-shadow: inset 0 2px 4px #000;
    pointer-events: none;
}
.pg-dirt-clod {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #5c381c;
    pointer-events: none;
    animation: pgDirtFly 0.45s ease-out forwards;
}
@keyframes pgDirtFly {
    0% { transform: translate(0, 0); opacity: 1; }
    100% { transform: translate(var(--vdx), var(--vdy)) scale(0.3); opacity: 0; }
}

/* ==================== VODA (Drawing Water from Well) ==================== */
.pg-mini--voda {
    background: radial-gradient(circle at 50% 25%, #1e3a5f 0%, #0f2038 55%, #060e1a 100%) !important;
    position: relative;
    height: 275px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.pg-well-container {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    width: 130px;
    height: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    pointer-events: none;
}
.pg-well-stone-rim {
    width: 120px;
    height: 60px;
    background: linear-gradient(90deg, #374151 0%, #6b7280 40%, #4b5563 80%, #1f2937 100%);
    border-radius: 12px;
    border: 3px solid #1f2937;
    box-shadow: 0 10px 20px rgba(0,0,0,0.8), inset 0 0 15px rgba(0,0,0,0.9);
    position: relative;
    overflow: hidden;
}
.pg-well-hole {
    position: absolute;
    top: 4px;
    left: 8px;
    right: 8px;
    height: 22px;
    border-radius: 50%;
    background: #050b14;
    box-shadow: inset 0 3px 8px #000;
}
.pg-well-water-level {
    position: absolute;
    inset: 4px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 50%, #38bdf8 0%, #0284c7 60%, #0369a1 100%);
    opacity: 0.6;
    animation: pgWaterRipple 2s ease-in-out infinite alternate;
}
@keyframes pgWaterRipple {
    0% { transform: scale(0.95); opacity: 0.5; }
    100% { transform: scale(1.05); opacity: 0.8; }
}
.pg-bucket-actor {
    position: absolute;
    bottom: 75px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 56px;
    filter: drop-shadow(0 6px 10px rgba(0,0,0,0.6));
    pointer-events: none;
    z-index: 10;
    transition: transform 0.12s ease-out, bottom 0.12s ease-out;
}
.pg-bucket-actor.is-hauling {
    animation: pgBucketHaul 0.25s cubic-bezier(.2, .9, .3, 1.2) forwards;
}
@keyframes pgBucketHaul {
    0% { transform: translateX(-50%) translateY(30px) scale(0.85); }
    60% { transform: translateX(-50%) translateY(-25px) scale(1.1); }
    100% { transform: translateX(-50%) translateY(0) scale(1); }
}
.pg-water-splash {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, #bae6fd 0%, #38bdf8 80%);
    box-shadow: 0 0 6px #38bdf8;
    pointer-events: none;
    animation: pgSplashDrop 0.5s ease-out forwards;
}
@keyframes pgSplashDrop {
    0% { transform: translate(0, 0) scale(1.2); opacity: 1; }
    100% { transform: translate(var(--wsx), var(--wsy)) scale(0.4); opacity: 0; }
}

/* ==================== GRADNJA (Building / Construction) ==================== */
.pg-mini--gradnja {
    background: radial-gradient(circle at 50% 25%, #4b3621 0%, #2b1f13 55%, #140d07 100%) !important;
    position: relative;
    height: 275px;
    overflow: hidden;
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
}
.pg-build-wall {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    width: 160px;
    height: 100px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    align-content: flex-end;
    pointer-events: none;
}
.pg-build-block {
    height: 24px;
    width: 48px;
    background: linear-gradient(135deg, #78716c 0%, #57534e 60%, #292524 100%);
    border-radius: 4px;
    border: 1px solid #44403c;
    box-shadow: 0 3px 6px rgba(0,0,0,0.6);
    animation: pgItemPop 0.3s ease;
}
.pg-hammer-actor {
    position: absolute;
    top: 25px;
    left: 56%;
    font-size: 60px;
    transform: rotate(20deg);
    pointer-events: none;
    z-index: 15;
    filter: drop-shadow(0 6px 10px rgba(0,0,0,0.7));
    transition: transform 0.12s ease;
}
.pg-hammer-actor.is-idle {
    animation: pgAxeIdle 1.8s ease-in-out infinite alternate;
}
.pg-hammer-actor.is-striking {
    animation: pgHammerStrike 0.22s cubic-bezier(.2, .9, .3, 1.2) forwards;
}
@keyframes pgHammerStrike {
    0% { transform: rotate(35deg) translate(10px, -20px); }
    60% { transform: rotate(-45deg) translate(-28px, 60px); }
    100% { transform: rotate(20deg) translate(0, 0); }
}

/* ==================== SESTAVLJANJE NAJDBE (Roman Mound Puzzle Workbench) ==================== */
.pg-mini--puzzle {
    background: radial-gradient(circle at 50% 30%, #3e2723 0%, #251610 60%, #120a07 100%) !important;
    position: relative;
    min-height: 420px;
    padding: 16px 14px 20px;
    border-radius: 16px;
    border: 1px solid rgba(212, 175, 55, 0.45);
    box-shadow: inset 0 0 35px rgba(0, 0, 0, 0.8), 0 8px 24px rgba(0, 0, 0, 0.6);
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.pg-puzzle-header {
    text-align: center;
    margin-bottom: 12px;
}

.pg-puzzle-badge {
    display: inline-block;
    background: rgba(212, 175, 55, 0.18);
    border: 1px solid rgba(212, 175, 55, 0.6);
    color: #fde047;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 6px;
    text-transform: uppercase;
}

.pg-puzzle-title {
    font-size: 1.12rem;
    font-weight: 800;
    color: #fef08a;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8);
    margin-bottom: 4px;
}

.pg-puzzle-sub {
    font-size: 0.82rem;
    color: #d1d5db;
    max-width: 480px;
    margin: 0 auto;
    line-height: 1.35;
}

/* Ploskev grobnice z obrisi */
.pg-puzzle-board {
    position: relative;
    background: radial-gradient(circle at 50% 50%, rgba(45, 30, 20, 0.85) 0%, rgba(20, 14, 10, 0.95) 100%);
    border: 2px dashed rgba(212, 175, 55, 0.35);
    border-radius: 14px;
    padding: 12px;
    min-height: 195px;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s ease;
}

.pg-puzzle-board.is-fully-restored {
    border-color: #22c55e;
    border-style: solid;
    box-shadow: 0 0 30px rgba(34, 197, 94, 0.4), inset 0 0 25px rgba(245, 158, 11, 0.3);
    animation: pgAncientRestore 1.5s ease-in-out infinite alternate;
}

@keyframes pgAncientRestore {
    0% { transform: scale(1); filter: drop-shadow(0 0 8px rgba(234, 179, 8, 0.4)); }
    100% { transform: scale(1.015); filter: drop-shadow(0 0 18px rgba(234, 179, 8, 0.8)); }
}

.pg-vessel-ghost {
    position: relative;
    width: 270px;
    height: 175px;
}

.pg-puzzle-slot {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 1.5px dashed rgba(245, 158, 11, 0.5);
    background: rgba(30, 20, 12, 0.55);
    border-radius: 8px;
    padding: 4px;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.2, 0.9, 0.3, 1.2);
    animation: pgSlotPulse 2.4s ease-in-out infinite alternate;
}

@keyframes pgSlotPulse {
    0% { border-color: rgba(245, 158, 11, 0.35); transform: scale(0.98); }
    100% { border-color: rgba(245, 158, 11, 0.7); transform: scale(1); }
}

.pg-puzzle-slot:hover {
    border-color: #fde047;
    background: rgba(50, 35, 20, 0.8);
    transform: scale(1.05);
}

.pg-slot-outline {
    font-size: 1.5rem;
    opacity: 0.35;
    filter: grayscale(1);
    transition: all 0.3s ease;
}

.pg-slot-label {
    font-size: 0.68rem;
    color: #a8a29e;
    font-weight: 600;
    white-space: nowrap;
    margin-top: 2px;
}

/* Postavitev slotov glede na posodo */
.slot-handle {
    left: 15px;
    top: 35px;
    width: 68px;
    height: 80px;
}

.slot-rim {
    left: 95px;
    top: 5px;
    width: 80px;
    height: 48px;
}

.slot-body {
    left: 90px;
    top: 60px;
    width: 90px;
    height: 65px;
}

.slot-base {
    left: 85px;
    bottom: 5px;
    width: 100px;
    height: 38px;
}

.slot-glass {
    right: 15px;
    top: 45px;
    width: 68px;
    height: 70px;
}

/* Stanje ko je košček postavljen */
.pg-puzzle-slot.is-placed {
    border: 2px solid #22c55e;
    background: radial-gradient(circle, rgba(234, 179, 8, 0.35) 0%, rgba(34, 197, 94, 0.25) 100%);
    box-shadow: 0 0 16px rgba(234, 179, 8, 0.6), inset 0 0 10px rgba(34, 197, 94, 0.4);
    animation: none;
    transform: scale(1.02);
}

.pg-puzzle-slot.is-placed .pg-slot-outline {
    opacity: 1;
    filter: none;
    transform: scale(1.15);
}

.pg-puzzle-slot.is-placed .pg-slot-label {
    color: #86efac;
    font-weight: 700;
}

/* Pladenj s kosi najdbe */
.pg-puzzle-tray {
    background: rgba(20, 14, 10, 0.85);
    border: 1px solid rgba(120, 88, 56, 0.6);
    border-radius: 12px;
    padding: 10px;
    margin-bottom: 10px;
}

.pg-tray-title {
    font-size: 0.78rem;
    font-weight: 700;
    color: #fde68a;
    text-align: center;
    margin-bottom: 8px;
    letter-spacing: 0.03em;
}

.pg-pieces-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    justify-content: center;
}

.pg-piece-card {
    display: flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #2d2016 0%, #1c130d 100%);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 8px;
    padding: 6px 10px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.4);
}

.pg-piece-card:hover {
    background: linear-gradient(135deg, #453123 0%, #2d2016 100%);
    border-color: #f59e0b;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.35);
}

.pg-piece-card:active {
    transform: translateY(0) scale(0.97);
}

.pg-piece-card.is-used {
    opacity: 0.35;
    pointer-events: none;
    border-color: #4b5563;
    background: #181513;
    text-decoration: line-through;
    filter: grayscale(0.8);
}

.pg-piece-emoji {
    font-size: 1.15rem;
}

.pg-piece-name {
    font-size: 0.76rem;
    font-weight: 600;
    color: #f3f4f6;
}

/* Odkritja vseh 4 družinskih članov (modal lokacije na zemljevidu) */
.pg-mound-discoveries {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 12px 0;
}

.pg-disc-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: rgba(30, 22, 16, 0.65);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 8px;
    padding: 8px 10px;
    font-size: 0.82rem;
    line-height: 1.35;
}

.pg-disc-who {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-weight: 700;
    color: #fde047;
    white-space: nowrap;
    min-width: 100px;
}

.pg-disc-text {
    color: #e2e8f0;
}

/* ==================== SPIRANJE ZLATA (Gold Panning Mini-Game) ==================== */
.pg-mini--spiranje {
    background: radial-gradient(circle at 50% 25%, #1e4b6e 0%, #12324d 55%, #0b1f30 100%) !important;
    position: relative;
    min-height: 400px;
    padding: 16px 14px 20px;
    border-radius: 16px;
    border: 1px solid rgba(245, 158, 11, 0.5);
    box-shadow: inset 0 0 35px rgba(0, 0, 0, 0.8), 0 8px 24px rgba(0, 0, 0, 0.6);
    user-select: none;
    -webkit-user-select: none;
    touch-action: none;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.pg-pan-header {
    text-align: center;
    margin-bottom: 10px;
}

.pg-gold-pan-stage {
    position: relative;
    height: 220px;
    width: 100%;
    margin: 8px auto 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 14px;
    background: radial-gradient(circle at 50% 50%, rgba(20, 50, 75, 0.5) 0%, rgba(10, 25, 40, 0.8) 100%);
    border: 1px dashed rgba(56, 189, 248, 0.3);
}

.pg-river-flow-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none;
    overflow: hidden;
    opacity: 0.35;
}

.pg-river-stream-line {
    position: absolute;
    height: 2px;
    width: 80%;
    background: linear-gradient(90deg, transparent, rgba(186, 230, 253, 0.8), transparent);
    animation: pgStreamFlow 2.4s linear infinite;
}

.pg-river-stream-line:nth-child(1) { top: 25%; left: -20%; }
.pg-river-stream-line:nth-child(2) { top: 75%; left: -40%; animation-delay: 1.2s; }

@keyframes pgStreamFlow {
    0% { transform: translateX(0); }
    100% { transform: translateX(140%); }
}

/* Lesena kopanja (izpiralna posoda) */
.pg-pan-dish {
    position: absolute;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 215px;
    height: 165px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 45%, #6a4422 0%, #4a2f16 65%, #2a190b 100%);
    box-shadow: inset 0 8px 22px rgba(0, 0, 0, 0.9), 0 10px 25px rgba(0, 0, 0, 0.7);
    border: 3px solid #82552a;
    cursor: grab;
    transition: transform 0.08s ease-out;
    pointer-events: none;
}

.pg-pan-dish.is-gold-full {
    box-shadow: 0 0 35px rgba(234, 179, 8, 0.8), inset 0 0 25px rgba(253, 224, 71, 0.6);
    animation: pgGoldPanGlow 1.2s ease-in-out infinite alternate;
}

@keyframes pgGoldPanGlow {
    0% { filter: drop-shadow(0 0 10px rgba(234, 179, 8, 0.5)); transform: translateX(-50%) scale(1); }
    100% { filter: drop-shadow(0 0 25px rgba(234, 179, 8, 0.9)); transform: translateX(-50%) scale(1.03); }
}

.pg-pan-inner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 155px;
    height: 115px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 50%, #15222e 0%, #0d161e 75%, #050a0e 100%);
    box-shadow: inset 0 4px 14px rgba(0, 0, 0, 0.95);
    overflow: hidden;
}

.pg-pan-water-ripple {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    border-radius: 50%;
    border: 2px solid rgba(125, 211, 252, 0.3);
    opacity: 0.4;
    pointer-events: none;
}

.pg-pan-water-ripple.is-swirling {
    animation: pgPanWaterSwirl 0.4s ease-out;
}

@keyframes pgPanWaterSwirl {
    0% { transform: scale(0.8) rotate(0deg); opacity: 0.8; }
    50% { transform: scale(1.1) rotate(60deg); opacity: 0.5; }
    100% { transform: scale(1) rotate(120deg); opacity: 0.3; }
}

/* Črni pesek (magnetit in granat) na dnu */
.pg-black-sand {
    position: absolute;
    bottom: 8px;
    left: 20%;
    width: 60%;
    height: 32px;
    border-radius: 50%;
    background: radial-gradient(ellipse at 50% 50%, #171717 0%, #262626 50%, #451a1a 80%, transparent 100%);
    opacity: 0.35;
    transition: opacity 0.3s ease;
}

/* Zlate luske in zrna */
.pg-gold-deposit {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none;
}

.pg-gold-flake {
    position: absolute;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: radial-gradient(circle, #fef08a 0%, #eab308 60%, #b45309 100%);
    box-shadow: 0 0 8px #fde047, 0 0 2px #fff;
    animation: pgFlakeGlint 1.1s ease-in-out infinite alternate;
}

@keyframes pgFlakeGlint {
    0% { transform: scale(0.85); opacity: 0.8; }
    100% { transform: scale(1.25); opacity: 1; }
}

.pg-pan-hand-guide {
    position: absolute;
    bottom: 8px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #fde68a;
    background: rgba(15, 23, 42, 0.75);
    padding: 3px 10px;
    border-radius: 20px;
    border: 1px solid rgba(245, 158, 11, 0.4);
    animation: pgGuideBounce 1.5s ease-in-out infinite;
}

@keyframes pgGuideBounce {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-6px); }
    75% { transform: translateX(6px); }
}

/* Zlata kartica lokacije */
.pg-location-card--gold {
    border-color: rgba(234, 179, 8, 0.6) !important;
    box-shadow: 0 0 30px rgba(234, 179, 8, 0.2), inset 0 0 20px rgba(0, 0, 0, 0.6) !important;
}

/* ---------- Nalaganje / napaka ---------- */
.pg-loading {
    padding: 26px 18px;
    border-radius: 18px;
    text-align: center;
    background: linear-gradient(180deg, rgba(36, 28, 20, 0.96), rgba(22, 17, 12, 0.98));
    border: 1px solid var(--pg-gold-line);
    animation: pgSlideUp 0.35s ease;
}
.pg-quill { font-size: 42px; display: inline-block; animation: pgQuill 1.2s ease-in-out infinite; }
@keyframes pgQuill {
    0%, 100% { transform: rotate(-8deg) translateX(-6px); }
    50% { transform: rotate(10deg) translateX(6px); }
}
.pg-loading h3 { font-family: var(--pg-title-font); color: var(--pg-gold); font-size: 16px; margin: 10px 0 6px; }
.pg-loading-tip { font-size: 13px; line-height: 1.5; color: rgba(246, 234, 210, 0.7); min-height: 40px; transition: opacity 0.4s ease; }
.pg-loading-bar { height: 3px; margin-top: 14px; border-radius: 3px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.pg-loading-bar::after {
    content: "";
    display: block;
    width: 40%;
    height: 100%;
    background: linear-gradient(90deg, transparent, var(--pg-gold), transparent);
    animation: pgLoadSweep 1.4s ease-in-out infinite;
}
@keyframes pgLoadSweep { from { transform: translateX(-100%); } to { transform: translateX(260%); } }

.pg-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 18px;
    border: none;
    border-radius: 14px;
    font-family: var(--pg-title-font);
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: var(--pg-ink);
    background: linear-gradient(180deg, #ffd98a, #e2a83c);
    box-shadow: 0 6px 20px rgba(226, 168, 60, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: transform 0.12s ease, filter 0.2s ease;
}
.pg-btn:active { transform: scale(0.97); filter: brightness(0.95); }
.pg-btn.is-ghost { background: transparent; color: var(--pg-gold); border: 1px solid var(--pg-gold-line); box-shadow: none; }

/* ---------- Plošče (cilj, odnosi, kronika) ---------- */
.pg-panel {
    padding: 14px;
    border-radius: 16px;
    background: var(--pg-panel);
    border: 1px solid rgba(242, 200, 107, 0.14);
}
.pg-panel-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: var(--pg-title-font);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    color: var(--pg-gold);
    margin-bottom: 8px;
    text-transform: uppercase;
}
.pg-goal-text { font-size: 13px; line-height: 1.5; color: rgba(246, 234, 210, 0.7); margin-bottom: 10px; }
.pg-bars { display: grid; gap: 8px; }
.pg-bar-row { display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 8px; font-size: 12px; }
.pg-bar-row .pg-bar-icon { font-size: 16px; text-align: center; }
.pg-bar {
    height: 8px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.45);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
}
.pg-bar-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--pg-ember), var(--pg-gold));
    transition: width 0.8s cubic-bezier(.2, .8, .2, 1);
}
.pg-bar-fill.is-full { background: linear-gradient(90deg, #2fae69, var(--pg-leaf)); }
.pg-bar-fill.is-love { background: linear-gradient(90deg, #db2777, var(--pg-love)); }
.pg-bar-val { font-weight: 800; font-variant-numeric: tabular-nums; color: var(--pg-parchment); min-width: 64px; text-align: right; }

.pg-chronicle { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pg-chronicle li {
    position: relative;
    padding-left: 14px;
    font-size: 12.5px;
    line-height: 1.45;
    color: rgba(246, 234, 210, 0.78);
}
.pg-chronicle li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 6px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--pg-gold);
}
.pg-chronicle b { color: var(--pg-gold); font-weight: 700; }
.pg-details summary { cursor: pointer; list-style: none; }
.pg-details summary::-webkit-details-marker { display: none; }
.pg-details[open] .pg-caret { transform: rotate(180deg); }
.pg-caret { transition: transform 0.2s ease; display: inline-block; }

/* ---------- Modalna okna ---------- */
.pg-modal {
    position: fixed;
    inset: 0;
    z-index: 300;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(5, 4, 3, 0.78);
    backdrop-filter: blur(6px);
}
.pg-modal.is-open { display: flex; animation: pgFade 0.25s ease; }
@keyframes pgFade { from { opacity: 0; } to { opacity: 1; } }

.pg-modal-card {
    position: relative;
    width: 100%;
    max-width: 420px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding: 22px 18px 18px;
    border-radius: 22px;
    text-align: center;
    background: linear-gradient(180deg, #2a2016 0%, #17110b 100%);
    border: 1px solid var(--pg-gold-line);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 40px rgba(242, 200, 107, 0.12);
    animation: pgModalPop 0.45s cubic-bezier(.2, 1.4, .4, 1);
}
@keyframes pgModalPop { from { opacity: 0; transform: scale(0.85) translateY(20px); } to { opacity: 1; transform: none; } }

.pg-reward-amount {
    font-family: var(--pg-title-font);
    font-size: 46px;
    font-weight: 900;
    color: var(--pg-gold);
    text-shadow: 0 0 24px rgba(242, 200, 107, 0.6);
    animation: pgBump 0.9s ease 0.2s;
}
.pg-reward-title { font-family: var(--pg-title-font); font-size: 20px; color: var(--pg-parchment); margin: 4px 0 12px; }
.pg-reward-lines { display: grid; gap: 6px; margin-bottom: 14px; text-align: left; }
.pg-reward-line {
    padding: 8px 12px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 13px;
    color: rgba(246, 234, 210, 0.9);
    animation: pgSlideUp 0.4s ease both;
}
.pg-reward-line.is-love { border-color: rgba(244, 114, 182, 0.35); background: rgba(244, 114, 182, 0.08); }
.pg-fact {
    text-align: left;
    padding: 12px 14px;
    margin-bottom: 16px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(242, 200, 107, 0.14), rgba(242, 200, 107, 0.04));
    border-left: 3px solid var(--pg-gold);
    font-size: 13.5px;
    line-height: 1.5;
    color: var(--pg-parchment);
}
.pg-fact b { display: block; color: var(--pg-gold); font-size: 12px; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 4px; }

.pg-chapter-card { padding: 0; overflow: hidden; }
.pg-chapter-img { width: 100%; height: 210px; object-fit: cover; display: block; animation: pgKenBurns 14s ease-in-out infinite alternate; }
.pg-chapter-body { padding: 18px; }
.pg-chapter-kicker { font-size: 11px; letter-spacing: 3px; text-transform: uppercase; color: rgba(246, 234, 210, 0.6); }
.pg-chapter-title { font-family: var(--pg-title-font); font-size: 24px; font-weight: 900; color: var(--pg-gold); margin: 6px 0 10px; text-shadow: 0 0 20px rgba(242, 200, 107, 0.4); }
.pg-chapter-intro { font-size: 14px; line-height: 1.6; color: var(--pg-parchment); margin-bottom: 16px; }

.pg-confetti {
    position: fixed;
    top: -20px;
    z-index: 400;
    font-size: 20px;
    pointer-events: none;
    animation: pgConfetti linear forwards;
}
@keyframes pgConfetti { to { transform: translateY(110vh) rotate(720deg); opacity: 0.6; } }

@media (min-width: 560px) {
    .pg-scene { height: 300px; }
    .pg-res-icon { font-size: 20px; }
}

@media (prefers-reduced-motion: reduce) {
    .pg-scene-img, .pg-chapter-img { animation: none; }
}

/* ==========================================================================
   2D INTERAKTIVNI ZEMLJEVID & 4-PLAYER HUD (Dravsko polje 1500)
   ========================================================================== */

.pg-game-2d {
    display: flex !important;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 10px 24px;
    box-sizing: border-box;
}

/* ---------- 4-PLAYER STATUS HUD ---------- */
.pg-players-hud-card {
    background: linear-gradient(135deg, rgba(32, 25, 18, 0.95), rgba(18, 14, 10, 0.98));
    border: 1px solid var(--pg-gold-line);
    border-radius: 14px;
    padding: 8px 12px 10px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
}

.pg-players-hud-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    padding-bottom: 4px;
    border-bottom: 1px solid rgba(242, 200, 107, 0.15);
}

.pg-hud-badge-title {
    font-family: var(--pg-title-font);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: var(--pg-gold);
}

.pg-hud-badge-hint {
    font-size: 10.5px;
    color: rgba(246, 234, 210, 0.55);
}

.pg-players-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

@media (max-width: 768px) {
    .pg-players-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.pg-player-card {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(242, 200, 107, 0.18);
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    user-select: none;
}

.pg-player-card:hover {
    transform: translateY(-2px);
    background: rgba(242, 200, 107, 0.08);
    border-color: var(--pg-gold);
}

.pg-player-card.is-active {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.22), rgba(217, 119, 6, 0.1));
    border-color: #f59e0b;
    box-shadow: 0 0 16px rgba(245, 158, 11, 0.35);
}

.pg-player-avatar-wrap {
    position: relative;
    width: 38px;
    height: 38px;
    flex-shrink: 0;
}

.pg-player-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--pg-gold-line);
    display: block;
}

.pg-player-card.is-active .pg-player-avatar-img {
    border-color: #f59e0b;
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.6);
}

.pg-player-crown {
    position: absolute;
    top: -8px;
    right: -4px;
    font-size: 13px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.8));
    animation: pgCrownBob 2s ease-in-out infinite;
}

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

.pg-player-lvl-pill {
    position: absolute;
    bottom: -3px;
    left: 50%;
    transform: translateX(-50%);
    background: #1c1610;
    border: 1px solid var(--pg-gold-line);
    border-radius: 6px;
    font-size: 8px;
    font-weight: 700;
    color: var(--pg-gold);
    padding: 0 4px;
    line-height: 11px;
    white-space: nowrap;
}

.pg-player-details {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.pg-player-name-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
}

.pg-player-name {
    font-family: var(--pg-title-font);
    font-size: 12.5px;
    font-weight: 700;
    color: var(--pg-parchment);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pg-player-turn-badge {
    background: #f59e0b;
    color: #1a140e;
    font-size: 8px;
    font-weight: 800;
    padding: 1px 5px;
    border-radius: 6px;
    letter-spacing: 0.5px;
    animation: pgBadgeGlow 1.8s ease-in-out infinite alternate;
}

@keyframes pgBadgeGlow {
    from { box-shadow: 0 0 4px rgba(245, 158, 11, 0.4); }
    to { box-shadow: 0 0 10px rgba(245, 158, 11, 0.9); }
}

.pg-player-wait-badge {
    font-size: 9px;
    color: rgba(246, 234, 210, 0.4);
}

.pg-player-role {
    font-size: 10px;
    color: rgba(246, 234, 210, 0.65);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pg-player-bar-track {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 2px;
}

.pg-player-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #f59e0b, #d97706);
    border-radius: 2px;
    transition: width 0.3s ease;
}

.pg-player-bar-fill.is-complete {
    background: linear-gradient(90deg, #10b981, #059669);
}

/* ---------- MOBILNI PREKLOPNIK (TABS) ---------- */
.pg-view-tabs {
    display: none;
}

@media (max-width: 899px) {
    .pg-view-tabs {
        display: flex;
        gap: 8px;
        margin: 2px 0 6px;
    }
}

.pg-view-tab {
    flex: 1;
    position: relative;
    padding: 9px 12px;
    border-radius: 10px;
    background: rgba(28, 22, 16, 0.85);
    border: 1px solid var(--pg-gold-line);
    color: var(--pg-parchment);
    font-family: var(--pg-title-font);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.pg-view-tab.is-active {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #1a140e;
    border-color: #f59e0b;
    box-shadow: 0 0 14px rgba(245, 158, 11, 0.4);
}

.pg-tab-task-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #e2574c;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    animation: pgPingDot 1.5s infinite;
}

@keyframes pgPingDot {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.25); }
}

/* ---------- SPLIT-SCREEN STRUKTURA ---------- */
.pg-split-container {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 14px;
    align-items: start;
    width: 100%;
}

@media (max-width: 899px) {
    .pg-split-container {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }
    .is-hidden-mobile {
        display: none !important;
    }
}

.pg-col-map,
.pg-col-story {
    width: 100%;
    box-sizing: border-box;
}

/* ---------- 2D ZEMLJEVID KARTICA ---------- */
.pg-map-card {
    background: var(--pg-panel-solid);
    border: 1px solid var(--pg-gold-line);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
}

.pg-map-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(14, 11, 8, 0.95);
    border-bottom: 1px solid var(--pg-gold-line);
}

.pg-map-title {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--pg-title-font);
    font-size: 13px;
    font-weight: 700;
    color: var(--pg-gold);
}

.pg-map-compass {
    font-size: 16px;
}

.pg-map-season-pill {
    font-size: 11px;
    color: rgba(246, 234, 210, 0.75);
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 8px;
    border-radius: 8px;
    border: 1px solid rgba(242, 200, 107, 0.2);
}

.pg-map-viewport {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 11;
    min-height: 380px;
    max-height: 520px;
    overflow: hidden;
    background: #232616;
}

.pg-map-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.pg-map-hotspots {
    position: absolute;
    inset: 0;
    z-index: 5;
    pointer-events: auto;
}

/* Kartografski okraski na zemljevidu */
.pg-map-decorations {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 4;
}

.pg-map-river-label {
    position: absolute;
    top: 20%;
    right: 5%;
    font-family: var(--pg-title-font);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.45);
    transform: rotate(82deg);
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}

.pg-map-compass-rose {
    position: absolute;
    bottom: 12px;
    left: 12px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--pg-title-font);
    font-size: 10px;
    font-weight: 800;
    color: var(--pg-gold);
    background: rgba(14, 11, 8, 0.65);
    border: 1px dashed var(--pg-gold-line);
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}

.pg-map-compass-rose span {
    position: absolute;
}
.c-n { top: 2px; }
.c-s { bottom: 2px; }
.c-w { left: 4px; }
.c-e { right: 4px; }
.c-cross { font-size: 12px; opacity: 0.7; }

.pg-map-scale {
    position: absolute;
    bottom: 10px;
    right: 12px;
    font-family: var(--pg-title-font);
    font-size: 9.5px;
    letter-spacing: 1px;
    color: rgba(246, 234, 210, 0.5);
    background: rgba(14, 11, 8, 0.7);
    padding: 2px 6px;
    border-radius: 4px;
    border: 1px solid rgba(242, 200, 107, 0.2);
}

/* Interaktivni pin-i na zemljevidu */
.pg-map-pin {
    position: absolute;
    transform: translate(-50%, -50%);
    cursor: pointer;
    transition: transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
    user-select: none;
    z-index: 6;
}

.pg-map-pin:hover {
    transform: translate(-50%, -56%) scale(1.1);
    z-index: 10;
}

.pg-pin-landmark {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.pg-pin-icon-wrap {
    position: relative;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(40, 30, 20, 0.95), rgba(18, 14, 10, 0.98));
    border: 2px solid var(--pg-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.7);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pg-pin-emoji {
    font-size: 22px;
    line-height: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.6));
}

.pg-pin-tag {
    background: rgba(24, 18, 12, 0.94);
    border: 1px solid var(--pg-gold-line);
    border-radius: 6px;
    padding: 2px 7px;
    margin-top: 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
    white-space: nowrap;
}

.pg-pin-tag-name {
    font-family: var(--pg-title-font);
    font-size: 10.5px;
    font-weight: 700;
    color: var(--pg-parchment);
}

.pg-pin-tag-task {
    font-size: 8.5px;
    font-weight: 800;
    color: #f59e0b;
    letter-spacing: 0.5px;
}

/* Izbrana lokacija */
.pg-map-pin.is-selected .pg-pin-icon-wrap {
    border-color: #fff;
    box-shadow: 0 0 16px rgba(242, 200, 107, 0.85), 0 0 30px rgba(245, 158, 11, 0.5);
}

/* Lokacija z aktivno nalogo */
.pg-map-pin.has-active-task .pg-pin-icon-wrap {
    border-color: #f59e0b;
    animation: pgTaskBeaconPulse 1.8s infinite;
}

@keyframes pgTaskBeaconPulse {
    0%, 100% {
        box-shadow: 0 0 10px rgba(245, 158, 11, 0.6), 0 0 20px rgba(245, 158, 11, 0.3);
    }
    50% {
        box-shadow: 0 0 22px rgba(245, 158, 11, 0.95), 0 0 40px rgba(245, 158, 11, 0.6);
    }
}

.pg-pin-pulse {
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 2px solid #f59e0b;
    animation: pgPing 1.8s cubic-bezier(0, 0, 0.2, 1) infinite;
    pointer-events: none;
}

@keyframes pgPing {
    75%, 100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

/* Spodnji trak zemljevida */
.pg-map-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(14, 11, 8, 0.95);
    border-top: 1px solid var(--pg-gold-line);
}

.pg-map-footer-info {
    font-size: 12px;
    color: var(--pg-parchment);
    line-height: 1.3;
}

.pg-map-footer-info b {
    color: var(--pg-gold);
    margin-right: 4px;
}

.pg-map-footer-info span {
    color: rgba(246, 234, 210, 0.7);
}

.pg-btn-map-action {
    flex-shrink: 0;
    padding: 6px 12px;
    border-radius: 8px;
    background: rgba(242, 200, 107, 0.15);
    border: 1px solid var(--pg-gold-line);
    color: var(--pg-gold);
    font-family: var(--pg-title-font);
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pg-btn-map-action:hover {
    background: var(--pg-gold);
    color: #1a140e;
}

.pg-btn-map-action.is-highlight {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #1a140e;
    border-color: #f59e0b;
    box-shadow: 0 0 12px rgba(245, 158, 11, 0.4);
    animation: pgPulseBtn 1.8s infinite;
}

@keyframes pgPulseBtn {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.04); }
}

/* ---------- KARTICA RAZISKOVANJA LOKACIJE ---------- */
.pg-location-card {
    background: linear-gradient(135deg, rgba(38, 29, 20, 0.95), rgba(22, 17, 12, 0.98));
    border: 1px solid var(--pg-gold-line);
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    animation: pgFadeIn 0.3s ease;
}

@keyframes pgFadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.pg-location-badge {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--pg-gold);
    margin-bottom: 8px;
}

.pg-location-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.pg-location-big-icon {
    font-size: 36px;
    line-height: 1;
    padding: 8px;
    background: rgba(242, 200, 107, 0.12);
    border-radius: 12px;
    border: 1px solid rgba(242, 200, 107, 0.25);
}

.pg-location-name {
    font-family: var(--pg-title-font);
    font-size: 17px;
    font-weight: 700;
    color: var(--pg-gold);
    margin-bottom: 2px;
}

.pg-location-sub {
    font-size: 12px;
    color: rgba(246, 234, 210, 0.65);
}

.pg-location-lore {
    font-size: 13.5px;
    line-height: 1.55;
    color: var(--pg-parchment);
    margin-bottom: 12px;
    background: rgba(0, 0, 0, 0.2);
    padding: 10px;
    border-radius: 8px;
    border-left: 3px solid var(--pg-gold-line);
}

.pg-location-quote {
    font-style: italic;
    font-size: 12.5px;
    color: rgba(246, 234, 210, 0.8);
    margin-bottom: 16px;
    padding: 6px 10px;
    background: rgba(242, 200, 107, 0.05);
    border-radius: 6px;
}

.pg-location-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pg-btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--pg-parchment);
    border: 1px solid rgba(242, 200, 107, 0.25);
}

.pg-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: var(--pg-gold);
}

/* ---------- STRANSKA ZGODBENA PLOŠČA (STORY WRAPPER) ---------- */
.pg-story-panel-wrap {
    background: var(--pg-panel-solid);
    border: 1px solid var(--pg-gold-line);
    border-radius: 14px;
    padding: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pg-story-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(242, 200, 107, 0.2);
}

.pg-story-title-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pg-quill-icon {
    font-size: 15px;
}

.pg-story-panel-title {
    font-family: var(--pg-title-font);
    font-size: 13.5px;
    font-weight: 700;
    color: var(--pg-gold);
}

.pg-turn-indicator {
    font-size: 11px;
    color: rgba(246, 234, 210, 0.7);
}

.pg-turn-indicator b {
    color: var(--pg-gold);
}

