@charset "UTF-8";

/* Nunito v32, değişken (wght 600–900). Google Fonts resmi CSS2 dağıtımı. */
@font-face {
  font-family: "Nunito";
  font-style: normal;
  font-weight: 600 900;
  font-display: swap;
  src: url("../assets/fonts/Nunito-latin-ext[wght].woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Nunito";
  font-style: normal;
  font-weight: 600 900;
  font-display: swap;
  src: url("../assets/fonts/Nunito-latin[wght].woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg-deep: #070b18;
  --bg-mid: #101833;
  --purple: #7b4dff;
  --purple-dark: #5a32d6;
  --found: #2ecc71;
  --found-dark: #1f9e55;
  --wrong: #e74c3c;
  --hint: #ffe566;
  --card: #ffffff;
  --text: #1a1a2e;
  --muted: #9aa3b8;
  --safe-bottom: var(--app-inset-bottom, 0px);
  --safe-top: var(--app-inset-top, 0px);
  --safe-left: var(--app-inset-left, 0px);
  --safe-right: var(--app-inset-right, 0px);
  --controls-h: calc(110px + var(--safe-bottom));
  --bar-h: 64px;
}

@supports (padding: env(safe-area-inset-top)) {
  :root {
    --safe-bottom: max(env(safe-area-inset-bottom, 0px), var(--app-inset-bottom, 0px));
    --safe-top: max(env(safe-area-inset-top, 0px), var(--app-inset-top, 0px));
    --safe-left: max(env(safe-area-inset-left, 0px), var(--app-inset-left, 0px));
    --safe-right: max(env(safe-area-inset-right, 0px), var(--app-inset-right, 0px));
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  height: 100%;
  font-family: "Nunito", system-ui, sans-serif;
  background: var(--bg-deep);
  color: #fff;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  touch-action: manipulation;
}

body {
  position: relative;
}

html.is-app,
html.is-app body {
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior: none;
}

button {
  touch-action: manipulation;
}

.space-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, #1a2a5a 0%, transparent 55%),
    radial-gradient(ellipse 60% 40% at 80% 80%, #1a1540 0%, transparent 50%),
    linear-gradient(180deg, #0b1020 0%, #070b18 100%);
  pointer-events: none;
}

.stars {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 12% 18%, rgba(255, 255, 255, 0.85), transparent),
    radial-gradient(1px 1px at 28% 62%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(1.5px 1.5px at 45% 28%, rgba(255, 255, 255, 0.75), transparent),
    radial-gradient(1px 1px at 62% 78%, rgba(255, 255, 255, 0.65), transparent),
    radial-gradient(1.5px 1.5px at 78% 22%, rgba(255, 255, 255, 0.8), transparent),
    radial-gradient(1px 1px at 88% 55%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1px 1px at 8% 88%, rgba(255, 255, 255, 0.55), transparent),
    radial-gradient(1.5px 1.5px at 52% 48%, rgba(255, 255, 255, 0.5), transparent);
  opacity: 0.9;
}

.orbit {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 50%;
}

.orbit-a {
  width: 120vmax;
  height: 120vmax;
  left: 50%;
  top: 40%;
  transform: translate(-50%, -50%);
}

.orbit-b {
  width: 70vmax;
  height: 70vmax;
  left: 55%;
  top: 35%;
  transform: translate(-50%, -50%);
  border-color: rgba(123, 77, 255, 0.12);
}

.grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at center, black 20%, transparent 75%);
  opacity: 0.5;
}

.top-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding:
    calc(12px + var(--safe-top))
    calc(16px + var(--safe-right))
    8px
    calc(16px + var(--safe-left));
  pointer-events: none;
}

.top-bar > * {
  pointer-events: auto;
}

.hidden {
  display: none !important;
}

.is-hidden {
  display: none !important;
}

.game-screen {
  position: relative;
  z-index: 1;
  height: 100%;
}

.menu-screen {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding:
    max(16px, var(--safe-top))
    max(16px, var(--safe-right))
    max(16px, var(--safe-bottom))
    max(16px, var(--safe-left));
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}

.menu-card,
.settings-card {
  width: min(100%, 380px);
  flex-shrink: 0;
  margin-block: auto;
  text-align: center;
  background: linear-gradient(165deg, rgba(28, 37, 72, 0.96) 0%, rgba(12, 16, 34, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 22px;
  padding: 36px 28px 28px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  animation: popIn 0.45s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}

.menu-kicker {
  margin: 0 0 8px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.75rem;
  color: #9bb0ff;
}

.menu-title {
  margin: 0 0 10px;
  font-size: clamp(2rem, 8vw, 2.6rem);
  font-weight: 900;
  line-height: 1.1;
  background: linear-gradient(90deg, #7bffb0, #ffe566);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.menu-privacy {
  display: inline-block;
  margin-top: 14px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
}

.menu-privacy:hover {
  color: #e8ecff;
}

.privacy-card .menu-title {
  margin-bottom: 16px;
}

.privacy-copy {
  text-align: left;
  color: #d5dcf2;
  font-weight: 700;
  font-size: 0.92rem;
  line-height: 1.45;
}

.privacy-copy p {
  margin: 0 0 12px;
}

.privacy-copy a {
  color: #9bb0ff;
}

.privacy-host {
  font-weight: 800;
}

.privacy-updated {
  color: var(--muted);
  font-size: 0.82rem;
}

.privacy-back {
  margin: 8px 0 0;
  font-size: 0.9rem;
  font-weight: 800;
}

.privacy-back a {
  color: #e8ecff;
  text-decoration: none;
}

.menu-sub {
  margin: 0 0 28px;
  color: var(--muted);
  font-weight: 700;
  line-height: 1.45;
}

.menu-actions {
  display: grid;
  gap: 12px;
}

.stats-card {
  width: min(100%, 440px);
  text-align: left;
}

.stats-card .menu-title,
.stats-card .menu-kicker {
  text-align: center;
}

.stats-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 18px;
}

.stats-summary-item {
  padding: 10px 8px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.06);
  text-align: center;
}

.stats-summary-label {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.stats-summary-item strong {
  font-size: 0.95rem;
  font-weight: 900;
}

.stats-list {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
}

.stats-group-title {
  margin: 10px 0 0;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9bb0ff;
}

.stats-row {
  padding: 8px 0 2px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.stats-name {
  font-weight: 800;
}

.stats-meta,
.stats-empty {
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.35;
}

.stats-row.is-empty .stats-name,
.stats-row.is-empty .stats-empty {
  opacity: 0.55;
}

.stats-actions {
  margin-top: 8px;
}

.menu-btn {
  appearance: none;
  border: none;
  border-radius: 14px;
  padding: 14px 18px;
  font-family: inherit;
  font-weight: 800;
  font-size: 1.05rem;
  cursor: pointer;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.menu-btn:active {
  transform: scale(0.97);
}

.menu-btn.primary {
  color: #fff;
  background: linear-gradient(160deg, var(--purple), var(--purple-dark));
  box-shadow: 0 8px 20px rgba(90, 50, 214, 0.4);
}

.menu-btn.primary.alt {
  background: linear-gradient(160deg, #2f9e6b, #1b6b48);
  box-shadow: 0 8px 20px rgba(27, 107, 72, 0.4);
}

.menu-btn.primary.earth {
  background: linear-gradient(160deg, #c47a32, #8a4b16);
  box-shadow: 0 8px 20px rgba(138, 75, 22, 0.4);
}

.menu-btn.primary.water {
  background: linear-gradient(160deg, #2aa8c4, #0e6e85);
  box-shadow: 0 8px 20px rgba(14, 110, 133, 0.4);
}

.menu-btn.primary.coast {
  background: linear-gradient(160deg, #1d7ec8, #0b4f86);
  box-shadow: 0 8px 20px rgba(11, 79, 134, 0.42);
}

.menu-btn.primary.river {
  background: linear-gradient(160deg, #2563eb, #1e3a8a);
  box-shadow: 0 8px 20px rgba(30, 58, 138, 0.42);
}

.menu-btn.primary.lake {
  background: linear-gradient(160deg, #0ea5e9, #0369a1);
  box-shadow: 0 8px 20px rgba(3, 105, 161, 0.42);
}

.menu-btn.primary.set-lake {
  background: linear-gradient(160deg, #14b8a6, #0f766e);
  box-shadow: 0 8px 20px rgba(15, 118, 110, 0.42);
}

.menu-btn.primary.coastal-lake {
  background: linear-gradient(160deg, #475569, #1e293b);
  box-shadow: 0 8px 20px rgba(30, 41, 59, 0.48);
}

.menu-btn.primary.agri {
  background: linear-gradient(160deg, #f59e0b, #65a30d 55%, #16a34a);
  box-shadow: 0 8px 20px rgba(101, 163, 13, 0.42);
}

.menu-btn.rainbow-btn {
  color: #fff !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
  background-color: #8b5cf6;
  background-image: linear-gradient(
    90deg,
    #ff4d6d,
    #ff9f1c,
    #ffe566,
    #7bffb0,
    #7ec4ff,
    #c77dff,
    #ff4d6d
  );
  background-size: 280% 100%;
  animation: rainbowShift 3.6s linear infinite;
  box-shadow: 0 0 16px rgba(255, 157, 80, 0.55), 0 0 28px rgba(139, 92, 246, 0.4);
}

@keyframes rainbowShift {
  0% {
    background-position: 0% 50%;
  }
  100% {
    background-position: 100% 50%;
  }
}

.menu-legend {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
  flex-wrap: wrap;
  font-size: 0.78rem;
  font-weight: 800;
  color: var(--muted);
}

.menu-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.leg {
  display: inline-block;
  width: 16px;
  height: 10px;
  border-radius: 2px;
}

.leg-kirik {
  background: #7b3fe4;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  width: 12px;
  height: 12px;
}

.leg-volkan {
  background: #c45a2c;
  border-radius: 50% 50% 20% 20%;
}

.leg-kivrim {
  background: linear-gradient(90deg, #2f6bff, #5b8cff);
  height: 4px;
  width: 18px;
  border-radius: 2px;
}

.mtn-target-card .mtn-badge {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.mtn-badge[data-type="kirik"] {
  background: linear-gradient(160deg, #9b6cff, #7b3fe4);
}

.mtn-badge[data-type="volkanik"] {
  background: linear-gradient(160deg, #e07a3a, #c45a2c);
}

.mtn-badge[data-type="kivrim"] {
  background: linear-gradient(160deg, #5b8cff, #2f6bff);
}

#mountains-map {
  width: min(100%, 1200px);
  height: auto;
  max-height: 100%;
  display: block;
  border-radius: 8px;
  filter: drop-shadow(0 8px 24px rgba(0, 0, 0, 0.35));
}

.mtn-marker {
  transition: filter 0.15s ease;
}

.mtn-marker:not(.found):hover {
  filter: brightness(1.15);
}

.mtn-marker.found {
  filter: drop-shadow(0 0 6px rgba(46, 204, 113, 0.85));
}

.mtn-marker.found .mtn-hit {
  fill: rgba(46, 204, 113, 0.28);
}

.mtn-marker.wrong-flash {
  animation: mtnWrong 0.7s ease;
}

.mtn-marker.hint-blink {
  filter: drop-shadow(0 0 14px #ffe566) drop-shadow(0 0 28px #ff9800);
}

.mtn-marker.hint-blink .mtn-hit {
  fill: rgba(255, 230, 50, 0.65);
  stroke: #fff59d;
  stroke-width: 3;
  animation: mtnHintCore 0.45s ease-in-out infinite;
}

.mtn-marker.hint-blink .mtn-hint-ring {
  display: block;
  animation: mtnHintHalo 0.7s ease-out infinite;
}

.mtn-hint-ring {
  display: none;
  fill: rgba(255, 229, 102, 0.2);
  stroke: #ffe566;
  stroke-width: 6;
  pointer-events: none;
}

@keyframes mtnWrong {
  0%,
  100% {
    filter: drop-shadow(0 0 8px rgba(231, 76, 60, 0.95));
  }
  50% {
    filter: drop-shadow(0 0 16px rgba(255, 120, 100, 1));
  }
}

@keyframes mtnHintCore {
  0%,
  100% {
    fill: rgba(255, 230, 50, 0.45);
    stroke-width: 3;
  }
  50% {
    fill: rgba(255, 255, 120, 0.85);
    stroke-width: 5;
  }
}

@keyframes mtnHintHalo {
  0% {
    r: 24;
    opacity: 1;
    stroke-width: 7;
  }
  100% {
    r: 52;
    opacity: 0;
    stroke-width: 2;
  }
}

.mtn-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 15px;
  paint-order: stroke fill;
  stroke: rgba(0, 0, 0, 0.75);
  stroke-width: 3px;
  pointer-events: none;
}

.plt-badge[data-type="yatay"] {
  background: linear-gradient(160deg, #b57aff, #9b4dff);
}

.plt-badge[data-type="tuf"] {
  background: linear-gradient(160deg, #444, #1a1a1a);
}

.plt-badge[data-type="lav"] {
  background: linear-gradient(160deg, #ef6b6b, #d94a4a);
}

.plt-badge[data-type="karstik"] {
  background: linear-gradient(160deg, #9ca3af, #6b7280);
}

.plt-badge[data-type="asinim"] {
  background: linear-gradient(160deg, #64748b, #334155);
}

.dlt-badge[data-type="delta"] {
  background: linear-gradient(160deg, #ff6aa8, #e83d8a);
}

.dlt-badge[data-type="nehir"] {
  background: linear-gradient(160deg, #7ec4ff, #3b9eff);
}

.spl-badge[data-type="karstik"] {
  background: linear-gradient(160deg, #9ca3af, #6b7280);
}

.spl-badge[data-type="gol"] {
  background: linear-gradient(160deg, #a78bfa, #7c3aed);
}

.spl-badge[data-type="lav"] {
  background: linear-gradient(160deg, #ef6b6b, #d94a4a);
}

.tek-badge[data-type="tektonik"] {
  background: linear-gradient(160deg, #a78bfa, #8b5cf6);
}

.mix-badge[data-type="delta"] {
  background: linear-gradient(160deg, #ff6aa8, #e83d8a);
}

.mix-badge[data-type="karstik"] {
  background: linear-gradient(160deg, #9ca3af, #6b7280);
}

.mix-badge[data-type="gol"] {
  background: linear-gradient(160deg, #a78bfa, #7c3aed);
}

.mix-badge[data-type="lav"] {
  background: linear-gradient(160deg, #ef6b6b, #d94a4a);
}

.mix-badge[data-type="tektonik"] {
  background: linear-gradient(160deg, #a78bfa, #8b5cf6);
}

.cst-badge[data-type="boyuna"] {
  background: linear-gradient(160deg, #ef6b6b, #e24b3b);
}

.cst-badge[data-type="enine"] {
  background: linear-gradient(160deg, #f5d04a, #eab308);
}

.cst-badge[data-type="ria"] {
  background: linear-gradient(160deg, #ec4899, #db2777);
}

.cst-badge[data-type="dalmacya"] {
  background: linear-gradient(160deg, #3b5bb5, #1e3a8a);
}

.cst-badge[data-type="kalankli"] {
  background: linear-gradient(160deg, #8b5cf6, #7c3aed);
}

.cst-badge[data-type="liman"] {
  background: linear-gradient(160deg, #22d3ee, #0891b2);
}

.rvr-badge[data-type="ege"] {
  background: linear-gradient(160deg, #3b82f6, #2563eb);
}

.rvr-badge[data-type="akdeniz"] {
  background: linear-gradient(160deg, #f5d04a, #eab308);
}

.rvr-badge[data-type="karadeniz"] {
  background: linear-gradient(160deg, #22d3ee, #0891b2);
}

.rvr-badge[data-type="marmara"] {
  background: linear-gradient(160deg, #a78bfa, #8b5cf6);
}

.rvr-badge[data-type="basra"] {
  background: linear-gradient(160deg, #fb923c, #f97316);
}

.rvr-badge[data-type="hazar"] {
  background: linear-gradient(160deg, #2dd4bf, #14b8a6);
}

.lak-badge[data-type="tektonik"] {
  background: linear-gradient(160deg, #3b82f6, #2563eb);
}

.lak-badge[data-type="karstik"] {
  background: linear-gradient(160deg, #fb7185, #e11d48);
}

.lak-badge[data-type="volkanik"] {
  background: linear-gradient(160deg, #fb923c, #f97316);
}

.lak-badge[data-type="lagun"] {
  background: linear-gradient(160deg, #a78bfa, #8b5cf6);
}

.sgl-badge[data-type="aluvyal"] {
  background: linear-gradient(160deg, #3b82f6, #1d4ed8);
}

.sgl-badge[data-type="heyelan"] {
  background: linear-gradient(160deg, #4ade80, #16a34a);
}

.sgl-badge[data-type="lav"] {
  background: linear-gradient(160deg, #f87171, #dc2626);
}

.csl-badge[data-type="lagun"] {
  background: linear-gradient(160deg, #334155, #111827);
}

.csl-badge[data-type="traverten"] {
  background: linear-gradient(160deg, #d1d5db, #9ca3af);
  color: #1f2937;
}

.agr-badge[data-type="tahil"] {
  background: linear-gradient(160deg, #f4d03f, #d4a017);
  color: #3e2a00;
}

.agr-badge[data-type="baklagil"] {
  background: linear-gradient(160deg, #bcaaa4, #8d6e63);
}

.agr-badge[data-type="meyve"] {
  background: linear-gradient(160deg, #fb7185, #e53935);
}

.agr-badge[data-type="sebze"] {
  background: linear-gradient(160deg, #86efac, #43a047);
  color: #14532d;
}

.agr-badge[data-type="endustri"] {
  background: linear-gradient(160deg, #ffb74d, #ef6c00);
}

.agr-badge[data-type="icecek"] {
  background: linear-gradient(160deg, #66bb6a, #1b7a3c);
}

.agc-badge[data-type="il"] {
  background: linear-gradient(160deg, #a3e635, #65a30d);
  color: #1a2e05;
}

#plateaus-map,
#deltas-map,
#special-plains-map,
#tectonic-plains-map,
#mixed-plains-map,
#coasts-map,
#rivers-map,
#lakes-map,
#set-lakes-map,
#coastal-lakes-map {
  width: min(100%, 1200px);
  height: auto;
  max-height: 100%;
  display: block;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.type-legend {
  position: fixed;
  left: calc(10px + var(--safe-left));
  top: 72px;
  top: calc(var(--bar-h) + var(--safe-top) + 8px);
  z-index: 18;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 168px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(10, 14, 32, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.45);
  font-size: 0.86rem;
  font-weight: 800;
  color: #fff;
  pointer-events: none;
}

.type-legend-title {
  margin: 0 0 2px;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #c5d2ff;
}

.type-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  line-height: 1.2;
}

.type-legend .leg,
.type-legend .leg-yatay,
.type-legend .leg-tuf,
.type-legend .leg-lav,
.type-legend .leg-karstik,
.type-legend .leg-asinim,
.type-legend .leg-delta,
.type-legend .leg-gol,
.type-legend .leg-tektonik {
  width: 18px;
  height: 12px;
  flex-shrink: 0;
}

.type-legend .leg-kirik {
  width: 14px;
  height: 14px;
}

.type-legend .leg-volkan {
  width: 14px;
  height: 14px;
}

.type-legend .leg-kivrim {
  width: 20px;
  height: 5px;
}

.type-legend .leg-nehir,
.type-legend .leg-boyuna,
.type-legend .leg-enine,
.type-legend .leg-ria,
.type-legend .leg-dalmacya,
.type-legend .leg-kalankli {
  width: 20px;
  height: 5px;
}

.type-legend .leg-liman {
  width: 16px;
  height: 10px;
}

.leg-yatay {
  background: #9b4dff;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-tuf {
  background: #1a1a1a;
  width: 14px;
  height: 10px;
  border-radius: 2px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.leg-lav {
  background: #d94a4a;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-karstik {
  background: #6b7280;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-asinim {
  background: #334155;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-delta {
  background: #e83d8a;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-gol {
  background: #7c3aed;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-tektonik {
  background: #8b5cf6;
  width: 14px;
  height: 10px;
  border-radius: 2px;
}

.leg-nehir {
  background: linear-gradient(90deg, #3b9eff, #7ec4ff);
  height: 4px;
  width: 18px;
  border-radius: 2px;
}

.leg-boyuna {
  background: #e24b3b;
  height: 5px;
  width: 20px;
  border-radius: 3px;
}

.leg-enine {
  background: #eab308;
  height: 5px;
  width: 20px;
  border-radius: 3px;
}

.leg-ria {
  background: #db2777;
  height: 5px;
  width: 20px;
  border-radius: 3px;
}

.leg-dalmacya {
  background: #1e3a8a;
  height: 5px;
  width: 20px;
  border-radius: 3px;
}

.leg-kalankli {
  background: #7c3aed;
  height: 5px;
  width: 20px;
  border-radius: 3px;
}

.leg-liman {
  background: #06b6d4;
  width: 16px;
  height: 10px;
  border-radius: 50%;
}

.leg-ege,
.leg-akdeniz,
.leg-karadeniz,
.leg-marmara-rvr,
.leg-basra,
.leg-hazar {
  height: 5px;
  width: 20px;
  border-radius: 3px;
  flex-shrink: 0;
}

.leg-ege { background: #2563eb; }
.leg-akdeniz { background: #eab308; }
.leg-karadeniz { background: #06b6d4; }
.leg-marmara-rvr { background: #8b5cf6; }
.leg-basra { background: #f97316; }
.leg-hazar { background: #14b8a6; }

.leg-lak-tektonik,
.leg-lak-karstik,
.leg-lak-volkanik,
.leg-lak-lagun {
  width: 16px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.leg-lak-tektonik { background: #2563eb; }
.leg-lak-karstik { background: #e11d48; }
.leg-lak-volkanik { background: #f97316; }
.leg-lak-lagun { background: #8b5cf6; }

.leg-sgl-aluvyal,
.leg-sgl-heyelan,
.leg-sgl-lav {
  width: 16px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.leg-sgl-aluvyal { background: #1d4ed8; }
.leg-sgl-heyelan { background: #16a34a; }
.leg-sgl-lav { background: #dc2626; }

.leg-csl-lagun,
.leg-csl-traverten {
  width: 16px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.leg-csl-lagun { background: #111827; }
.leg-csl-traverten { background: #e5e7eb; border: 1px solid #9ca3af; }

.leg-agr-tahil,
.leg-agr-baklagil,
.leg-agr-meyve,
.leg-agr-sebze,
.leg-agr-endustri,
.leg-agr-icecek {
  display: inline-block;
  width: 18px;
  height: 12px;
  border-radius: 4px;
  flex-shrink: 0;
}

.leg-agr-tahil { background: #f4d03f; }
.leg-agr-baklagil { background: #8d6e63; }
.leg-agr-meyve { background: #e53935; }
.leg-agr-sebze { background: #43a047; }
.leg-agr-endustri { background: #ef6c00; }
.leg-agr-icecek { background: #1b7a3c; }

.plt-marker {
  cursor: pointer;
  transition: filter 0.15s ease;
}

.plt-marker:not(.found):hover .plt-shape {
  filter: brightness(1.12);
}

.plt-marker.found .plt-shape {
  fill: rgba(46, 204, 113, 0.72) !important;
  stroke: #1f9e55;
}

.plt-marker.wrong-flash .plt-shape {
  animation: pltWrong 0.7s ease;
}

.plt-marker.hint-blink .plt-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.plt-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 13px;
  paint-order: stroke fill;
  stroke: rgba(0, 0, 0, 0.78);
  stroke-width: 3px;
  pointer-events: none;
  dominant-baseline: middle;
}

@keyframes pltWrong {
  0%,
  100% {
    fill: rgba(231, 76, 60, 0.8);
  }
  50% {
    fill: rgba(255, 138, 122, 0.95);
  }
}

@keyframes pltHint {
  0%,
  100% {
    fill: rgba(255, 229, 102, 0.55);
  }
  50% {
    fill: rgba(255, 255, 180, 0.9);
  }
}

.dlt-marker {
  cursor: pointer;
}

.dlt-marker:not(.found):hover .dlt-shape,
.dlt-marker:not(.found):hover .dlt-river {
  filter: brightness(1.12);
}

.dlt-river-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 16;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dlt-river {
  fill: none;
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.dlt-river-source,
.dlt-river-mouth {
  fill: #1d6fd4;
  stroke: #fff;
  stroke-width: 1.1;
}

.dlt-marker.found .dlt-shape {
  fill: rgba(46, 204, 113, 0.72) !important;
  stroke: #1f9e55;
}

.dlt-marker.found .dlt-river {
  stroke: #ffd24d !important;
  stroke-width: 3.6;
  filter: drop-shadow(0 0 2px #5a3a00);
}

.dlt-marker.found .dlt-river-source,
.dlt-marker.found .dlt-river-mouth {
  fill: #ffd24d;
  stroke: #5a3a00;
}

.dlt-marker.wrong-flash .dlt-shape {
  animation: pltWrong 0.7s ease;
}

.dlt-marker.wrong-flash .dlt-river {
  animation: dltRiverWrong 0.7s ease;
}

.dlt-marker.hint-blink .dlt-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.dlt-marker.hint-blink .dlt-river {
  animation: dltRiverHint 0.5s ease-in-out infinite;
  stroke-width: 5;
  filter: drop-shadow(0 0 10px #ffe566);
}

.dlt-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 13px;
  paint-order: stroke fill;
  stroke: rgba(0, 0, 0, 0.78);
  stroke-width: 3px;
  pointer-events: none;
  dominant-baseline: middle;
}

.spl-marker {
  cursor: pointer;
  transition: filter 0.15s ease;
}

.spl-marker:not(.found):hover .spl-shape {
  filter: brightness(1.12);
}

.spl-marker.found .spl-shape {
  fill: rgba(46, 204, 113, 0.72) !important;
  stroke: #1f9e55;
}

.spl-marker.wrong-flash .spl-shape {
  animation: pltWrong 0.7s ease;
}

.spl-marker.hint-blink .spl-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.spl-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 12px;
  paint-order: stroke fill;
  stroke: rgba(0, 0, 0, 0.78);
  stroke-width: 3px;
  pointer-events: none;
  dominant-baseline: middle;
}

.tek-marker {
  cursor: pointer;
  transition: filter 0.15s ease;
}

.tek-marker:not(.found):hover .tek-shape {
  filter: brightness(1.12);
}

.tek-marker.found .tek-shape {
  fill: rgba(46, 204, 113, 0.72) !important;
  stroke: #1f9e55;
}

.tek-marker.wrong-flash .tek-shape {
  animation: pltWrong 0.7s ease;
}

.tek-marker.hint-blink .tek-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.tek-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 11px;
  paint-order: stroke fill;
  stroke: rgba(0, 0, 0, 0.78);
  stroke-width: 3px;
  pointer-events: none;
  dominant-baseline: middle;
}

.cst-marker {
  cursor: pointer;
}

.cst-marker:not(.found):hover .cst-line,
.cst-marker:not(.found):hover .cst-shape {
  filter: brightness(1.12);
}

.cst-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 18;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cst-halo {
  fill: none;
  stroke: rgba(10, 14, 24, 0.55);
  stroke-width: 9.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cst-line {
  fill: none;
  stroke-width: 6.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cst-marker.found .cst-halo {
  stroke: #fff;
  stroke-width: 13;
}

.cst-marker.found .cst-line {
  stroke-width: 8.2;
  filter: drop-shadow(0 0 3px rgba(255, 255, 255, 0.95));
}

.cst-marker.found .cst-shape {
  stroke: #fff;
  stroke-width: 3.4;
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.9));
}

.cst-marker.wrong-flash .cst-line {
  animation: dltRiverWrong 0.7s ease;
}

.cst-marker.wrong-flash .cst-shape {
  animation: pltWrong 0.7s ease;
}

.cst-marker.hint-blink .cst-line {
  animation: dltRiverHint 0.5s ease-in-out infinite;
  stroke-width: 8;
  filter: drop-shadow(0 0 10px #ffe566);
}

.cst-marker.hint-blink .cst-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.cst-label {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 13px;
  paint-order: stroke fill;
  stroke: rgba(255, 255, 255, 0.92);
  stroke-width: 1.8px;
  pointer-events: none;
  dominant-baseline: middle;
}

.rvr-marker {
  cursor: pointer;
}

.rvr-marker:not(.found):hover .rvr-line {
  filter: brightness(1.12);
}

.rvr-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 16;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.rvr-halo {
  fill: none;
  stroke: rgba(10, 14, 24, 0.4);
  stroke-width: 5.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.rvr-line {
  fill: none;
  stroke-width: 3.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.rvr-source,
.rvr-mouth {
  stroke: #fff;
  stroke-width: 1.1;
}

.rvr-marker.found .rvr-halo {
  stroke: #fff;
  stroke-width: 8;
}

.rvr-marker.found .rvr-line {
  stroke-width: 4.4;
  filter: drop-shadow(0 0 3px rgba(255, 255, 255, 0.95));
}

.rvr-marker.wrong-flash .rvr-line {
  animation: dltRiverWrong 0.7s ease;
}

.rvr-marker.hint-blink .rvr-line {
  animation: dltRiverHint 0.5s ease-in-out infinite;
  stroke-width: 5.5;
  filter: drop-shadow(0 0 10px #ffe566);
}

.rvr-label {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 13px;
  paint-order: stroke fill;
  stroke: rgba(255, 255, 255, 0.92);
  stroke-width: 1.8px;
  pointer-events: none;
  dominant-baseline: middle;
}

.lak-marker,
.sgl-marker,
.csl-marker {
  cursor: pointer;
}

.lak-marker:not(.found):hover .lak-shape,
.sgl-marker:not(.found):hover .sgl-shape,
.csl-marker:not(.found):hover .csl-shape {
  filter: brightness(1.12);
}

.lak-marker.found .lak-shape,
.sgl-marker.found .sgl-shape,
.csl-marker.found .csl-shape {
  stroke: #fff;
  stroke-width: 3.2;
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.9));
}

.lak-marker.wrong-flash .lak-shape,
.sgl-marker.wrong-flash .sgl-shape,
.csl-marker.wrong-flash .csl-shape {
  animation: pltWrong 0.7s ease;
}

.lak-marker.hint-blink .lak-shape,
.sgl-marker.hint-blink .sgl-shape,
.csl-marker.hint-blink .csl-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.lak-label,
.sgl-label,
.csl-label {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 13px;
  paint-order: stroke fill;
  stroke: rgba(255, 255, 255, 0.92);
  stroke-width: 1.8px;
  pointer-events: none;
  dominant-baseline: middle;
}

.mix-marker {
  cursor: pointer;
  transition: filter 0.15s ease;
}

.mix-marker:not(.found):hover .mix-shape {
  filter: brightness(1.12);
}

.mix-marker.found .mix-shape {
  fill: rgba(46, 204, 113, 0.72) !important;
  stroke: #1f9e55;
}

.mix-marker.wrong-flash .mix-shape {
  animation: pltWrong 0.7s ease;
}

.mix-marker.hint-blink .mix-shape {
  animation: pltHint 0.5s ease-in-out infinite;
  stroke: #ffe566 !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 10px #ffe566) drop-shadow(0 0 22px #ff9800);
}

.mix-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 11px;
  paint-order: stroke fill;
  stroke: rgba(0, 0, 0, 0.78);
  stroke-width: 3px;
  pointer-events: none;
  dominant-baseline: middle;
}

@keyframes dltRiverWrong {
  0%,
  100% {
    stroke: #e74c3c;
  }
  50% {
    stroke: #ff8a7a;
  }
}

@keyframes dltRiverHint {
  0%,
  100% {
    stroke: #ffe566;
  }
  50% {
    stroke: #fff7b0;
  }
}


.menu-btn.ghost {
  color: #e8ecff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.settings-panel {
  position: fixed;
  inset: 0;
  z-index: 55;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding:
    max(16px, var(--safe-top))
    max(16px, var(--safe-right))
    max(16px, var(--safe-bottom))
    max(16px, var(--safe-left));
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
  background: rgba(5, 8, 20, 0.72);
  backdrop-filter: blur(6px);
}

.settings-card {
  text-align: left;
}

.settings-card h2 {
  margin: 0 0 20px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 900;
}

.setting-row {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
  font-weight: 700;
  color: #e8ecff;
}

.setting-row em {
  font-style: normal;
  color: #9bb0ff;
  font-weight: 800;
}

.setting-row input[type="range"] {
  width: 100%;
  accent-color: var(--purple);
  height: 28px;
}

.toggle-row {
  grid-template-columns: 1fr auto;
  align-items: center;
}

.toggle-switch {
  width: 56px;
  height: 32px;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  position: relative;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s ease;
}

.toggle-switch[aria-pressed="true"] {
  background: linear-gradient(160deg, #4ade80, #22c55e);
}

.app-only {
  display: none;
}

html.is-app .app-only {
  display: block;
}

.settings-section-label {
  margin: 4px 0 10px;
  font-size: 0.95rem;
  font-weight: 800;
  color: #9bb0ff;
}

.setting-row input[type="time"] {
  width: 100%;
  color: #e8ecff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 8px 10px;
  font: inherit;
}

.reminder-denied {
  margin: -6px 0 16px;
  color: #f0c674;
  font-size: 0.85rem;
  font-weight: 650;
}

.app-version-line {
  margin: 12px 0 0;
  text-align: center;
  color: #8b93a7;
  font-size: 0.8rem;
  font-weight: 650;
}

.toggle-knob {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  transition: transform 0.2s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
}

.toggle-switch[aria-pressed="true"] .toggle-knob {
  transform: translateX(24px);
}

.congrats-actions {
  display: grid;
  gap: 10px;
}

.replay-btn.ghost {
  background: rgba(255, 255, 255, 0.1);
  box-shadow: none;
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.circle-btn {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(160deg, var(--purple) 0%, var(--purple-dark) 100%);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(90, 50, 214, 0.45);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.circle-btn:active {
  transform: scale(0.94);
}

.progress-pill {
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e8ecff;
}

.stage {
  position: relative;
  z-index: 1;
  height: 100%;
  padding: 64px 8px 0;
  padding:
    calc(var(--bar-h) + var(--safe-top))
    8px
    0;
}

.map-viewport {
  width: 100%;
  height: 100%;
  overflow: hidden;
  touch-action: none;
  cursor: grab;
  border-radius: 12px 12px 0 0;
}

.map-viewport.is-panning {
  cursor: grabbing;
}

.map-stage {
  width: 100%;
  height: 100%;
  transform-origin: 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.map-stage svg {
  width: min(100%, 1100px);
  height: auto;
  max-height: 100%;
  display: block;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.mtn-label,
.plt-label,
.dlt-label,
.spl-label,
.tek-label,
.mix-label,
.cst-label,
.rvr-label,
.lak-label,
.sgl-label,
.csl-label,
.agr-label,
.city-label {
  text-rendering: geometricPrecision;
}

.province {
  cursor: pointer;
  transition: filter 0.15s ease;
  stroke: #2a2a3a;
  stroke-width: 1;
  stroke-linejoin: round;
}

.province:not(.found):hover {
  filter: brightness(1.08);
}

.province.found {
  fill: var(--found) !important;
  cursor: default;
  filter: none;
}

.province.wrong-flash {
  animation: wrongPulse 0.7s ease;
}

.province.hint-blink {
  animation: hintBlink 0.55s ease-in-out infinite;
}

#agr-map,
#agc-map,
#agd-map {
  width: min(100%, 1100px);
  height: auto;
  max-height: 100%;
  display: block;
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(80, 50, 10, 0.28);
}

#agr-map-host,
#agc-map-host,
#agd-map-host {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.agr-province {
  fill: #e7efc8;
  stroke: #6b5a32;
  stroke-width: 1;
  stroke-linejoin: round;
  cursor: pointer;
  transition: filter 0.15s ease;
}

.agr-province:not(.found):hover {
  filter: brightness(1.08);
}

.agr-province.found {
  cursor: default;
  filter: none;
  stroke-width: 1.6;
}

.agr-province.found-partial {
  cursor: pointer;
  stroke-width: 1.6;
}

.agr-province.wrong-flash {
  transition: none;
  filter: drop-shadow(0 0 8px rgba(231, 76, 60, 0.95));
}

.agr-province.hint-blink {
  animation: agrHint 0.55s ease-in-out infinite;
}

.agd-province {
  cursor: grab;
}

.agd-province.agd-grow {
  cursor: grab;
}

.agd-dot {
  fill: #1a1a1a;
  stroke: rgba(255, 255, 255, 0.55);
  stroke-width: 0.45;
}

.agd-pin-mark {
  fill: #2563eb;
  stroke: #1e3a8a;
  stroke-width: 1.1;
}

.agd-pin-hole {
  fill: #fff;
}

.agd-pin-label {
  fill: #111827;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 13px;
  paint-order: stroke fill;
  stroke: rgba(255, 255, 255, 0.95);
  stroke-width: 3.4px;
}

.agd-product-title {
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 28px;
  paint-order: stroke fill;
  stroke: #fff;
  stroke-width: 6px;
}

.agd-choice-panel {
  position: fixed;
  left: calc(10px + var(--safe-left));
  top: calc(var(--bar-h) + var(--safe-top) + 8px);
  bottom: calc(var(--controls-h, 118px) + 10px);
  z-index: 18;
  display: flex;
  flex-direction: column;
  width: min(214px, 42vw);
  padding: 10px 10px 8px;
  border-radius: 14px;
  background: rgba(10, 14, 32, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.45);
  color: #fff;
  overflow: hidden;
}

.agd-choice-hint {
  margin: 0 0 8px;
  font-size: 0.68rem;
  font-weight: 700;
  color: #c5d2ff;
  opacity: 0.9;
}

.agd-choices {
  display: grid;
  grid-template-columns: 1fr;
  gap: 5px;
  overflow-y: auto;
  padding-right: 2px;
  min-height: 0;
  flex: 1;
}

.agd-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin: 0;
  padding: 6px 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease, opacity 0.2s ease;
}

.agd-chip:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.16);
  transform: translateY(-1px);
}

.agd-chip:disabled {
  cursor: default;
}

.agd-chip.is-found {
  opacity: 0.38;
  filter: grayscale(0.35);
}

.agd-chip.is-wrong {
  animation: agdChipWrong 0.42s ease;
}

.agd-chip-emoji {
  width: 1.35em;
  text-align: center;
  flex-shrink: 0;
}

.agd-badge[data-type="guess"] {
  background: #2563eb;
}

.agd-badge[data-type="ok"] {
  background: #15803d;
}

@keyframes agdChipWrong {
  0%,
  100% {
    background: rgba(255, 255, 255, 0.08);
  }
  30% {
    background: #e74c3c;
    box-shadow: 0 0 0 2px #7f1d1d;
  }
}

.agd-next-btn {
  position: fixed;
  left: 50%;
  bottom: calc(var(--controls-h) + 18px);
  z-index: 24;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transform: translateX(-50%);
  margin: 0;
  padding: 12px 28px;
  border: 0;
  border-radius: 999px;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 900;
  color: #143016;
  background: linear-gradient(180deg, #c8f07a, #7ccf3a);
  box-shadow: 0 10px 24px rgba(70, 140, 20, 0.45);
  cursor: pointer;
  animation: popIn 0.22s ease;
}

.agd-next-btn:active {
  transform: translateX(-50%) scale(0.96);
}

@media (max-width: 720px) {
  .agd-choice-panel {
    left: calc(8px + var(--safe-left));
    right: calc(8px + var(--safe-right));
    top: auto;
    bottom: calc(var(--controls-h, 100px) + 6px);
    width: auto;
    max-height: 38vh;
    padding: 8px;
  }

  .agd-choices {
    grid-template-columns: 1fr 1fr;
  }

  .agd-chip {
    font-size: 0.76rem;
    padding: 5px 7px;
  }

  .agd-next-btn {
    left: auto;
    right: calc(12px + var(--safe-right));
    bottom: auto;
    top: calc(var(--bar-h) + var(--safe-top) + 10px);
    transform: none;
    padding: 10px 16px;
    font-size: 0.92rem;
  }

  .agd-next-btn:active {
    transform: scale(0.96);
  }
}

.agr-label {
  fill: #1a1a2e;
  font-family: "Nunito", sans-serif;
  font-weight: 800;
  text-anchor: middle;
  dominant-baseline: middle;
  pointer-events: none;
  paint-order: stroke fill;
  stroke: rgba(255, 255, 255, 0.94);
  stroke-width: 3.2px;
}

.agr-label-city {
  fill: #3e2723;
  font-weight: 900;
  letter-spacing: 0.02em;
}

@keyframes agrHint {
  0%,
  100% {
    filter: drop-shadow(0 0 2px #ffe566);
    stroke: #d4a017;
    stroke-width: 2;
  }
  50% {
    filter: brightness(1.25) drop-shadow(0 0 12px #ffe566) drop-shadow(0 0 22px #f59e0b);
    stroke: #ffe566;
    stroke-width: 3.6;
  }
}

@keyframes wrongPulse {
  0%,
  100% {
    fill: var(--wrong);
  }
  35% {
    fill: #ff8a7a;
  }
  70% {
    fill: var(--wrong);
  }
}

@keyframes hintBlink {
  0%,
  100% {
    fill: var(--hint);
    filter: drop-shadow(0 0 6px rgba(255, 229, 102, 0.7));
  }
  50% {
    fill: #fffbe0;
    filter: drop-shadow(0 0 12px rgba(255, 229, 102, 0.95));
  }
}

.city-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  text-anchor: middle;
  dominant-baseline: central;
  pointer-events: none;
  paint-order: stroke fill;
  stroke: rgba(0, 80, 40, 0.35);
  stroke-width: 0.6;
}

.city-label-abbr {
  font-weight: 900;
}

.city-label-plate {
  font-weight: 700;
  opacity: 0.95;
}

.controls {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 25;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: clamp(10px, 3vw, 28px);
  padding:
    8px
    calc(12px + var(--safe-right))
    calc(14px + var(--safe-bottom))
    calc(12px + var(--safe-left));
  background: none;
  pointer-events: none;
}

.controls > * {
  pointer-events: auto;
}

.char-btn {
  appearance: none;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  line-height: 0;
  transition: transform 0.15s ease;
  flex-shrink: 0;
}

.char-btn:active {
  transform: scale(0.92);
}

.char-btn:disabled {
  opacity: 0.45;
  cursor: default;
  transform: none;
}

.hint-icon,
.pass-icon {
  display: block;
  filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.35));
}

.target-card {
  display: flex;
  align-items: stretch;
  min-width: min(58vw, 280px);
  max-width: 340px;
  height: 56px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  margin-bottom: 8px;
}

.tr-badge {
  display: grid;
  place-items: center;
  width: 52px;
  background: linear-gradient(160deg, #3d7cff, #1f57d8);
  color: #fff;
  font-weight: 900;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
}

.target-text {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  color: var(--text);
  font-weight: 800;
  font-size: clamp(1.05rem, 3.5vw, 1.35rem);
  white-space: nowrap;
}

#plt-target-text,
#spl-target-text,
#tek-target-text,
#mix-target-text,
#cst-target-text,
#rvr-target-text,
#lak-target-text,
#sgl-target-text,
#csl-target-text,
#agr-target-text,
#agc-target-text {
  white-space: normal;
  text-align: center;
  line-height: 1.15;
  font-size: clamp(0.92rem, 3vw, 1.2rem);
}

.congrats {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: flex;
  justify-content: center;
  align-items: flex-end;
  padding:
    0
    calc(12px + var(--safe-right))
    calc(14px + var(--safe-bottom))
    calc(12px + var(--safe-left));
  background: none;
  pointer-events: none;
  overflow: visible;
}

.congrats.hidden {
  display: none;
}

.game-screen:has(.congrats:not(.hidden)) .controls,
.game-screen:has(.congrats:not(.hidden)) .agd-choice-panel,
.game-screen:has(.congrats:not(.hidden)) .agd-next-btn {
  visibility: hidden;
  pointer-events: none;
}

.congrats-card {
  pointer-events: auto;
  text-align: center;
  background: linear-gradient(165deg, rgba(28, 37, 72, 0.96) 0%, rgba(18, 24, 47, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  padding: 16px 20px 18px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  max-width: min(360px, calc(100vw - 24px));
  width: 100%;
  flex-shrink: 0;
  animation: popIn 0.35s cubic-bezier(0.2, 0.9, 0.3, 1.2);
  backdrop-filter: blur(10px);
}

.congrats-card h1 {
  margin: 0 0 4px;
  font-size: clamp(1.35rem, 5vw, 1.85rem);
  font-weight: 900;
  background: linear-gradient(90deg, #7bffb0, #ffe566);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.congrats-card p {
  margin: 0 0 12px;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.9rem;
  line-height: 1.35;
}

.replay-btn {
  border: none;
  border-radius: 12px;
  padding: 12px 22px;
  font-family: inherit;
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  background: linear-gradient(160deg, var(--purple), var(--purple-dark));
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(90, 50, 214, 0.4);
}

.replay-btn:active {
  transform: scale(0.96);
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: scale(0.86) translateY(12px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

@media (max-width: 480px) {
  :root {
    --controls-h: calc(100px + var(--safe-bottom));
  }

  .menu-card,
  .settings-card {
    padding: 24px 18px 18px;
  }

  .menu-sub {
    margin: 0 0 16px;
    font-size: 0.9rem;
  }

  .menu-actions {
    gap: 8px;
  }

  .menu-btn {
    padding: 12px 16px;
    font-size: 0.98rem;
  }

  .type-legend {
    min-width: 148px;
    padding: 10px 12px;
    font-size: 0.78rem;
    left: calc(6px + var(--safe-left));
  }

  .hint-icon {
    width: 54px;
    height: 66px;
  }

  .pass-icon {
    width: 60px;
    height: 60px;
  }

  .target-card {
    height: 50px;
    min-width: 46vw;
  }

  .tr-badge {
    width: 44px;
    font-size: 0.95rem;
  }
}

@media (max-height: 720px) {
  .menu-card,
  .settings-card {
    padding: 22px 18px 16px;
  }

  .menu-kicker {
    margin-bottom: 4px;
  }

  .menu-title {
    font-size: clamp(1.55rem, 6.5vw, 2.1rem);
    margin-bottom: 6px;
  }

  .menu-sub {
    margin: 0 0 14px;
    font-size: 0.88rem;
  }

  .menu-actions {
    gap: 8px;
  }

  .menu-btn {
    padding: 10px 16px;
    font-size: 0.95rem;
  }
}

@media (orientation: landscape) and (max-height: 500px) {
  :root {
    --controls-h: calc(84px + var(--safe-bottom));
  }

  :root {
    --bar-h: 52px;
  }

  .stage {
    padding-top: calc(var(--bar-h) + var(--safe-top));
  }

  .target-card {
    height: 44px;
    margin-bottom: 2px;
  }

  .hint-icon {
    width: 48px;
    height: 58px;
  }

  .pass-icon {
    width: 52px;
    height: 52px;
  }
}

/* Metro (Büyükşehir) - Test modu */
.metro-choices {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.metro-choice {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 13px 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-family: inherit;
  font-weight: 900;
  font-size: 1rem;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.12s ease, border-color 0.12s ease;
  text-align: center;
}

.metro-choice:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.14);
  transform: translateY(-1px);
}

.metro-choice:active:not(:disabled) {
  transform: scale(0.98);
}

.metro-choice:disabled {
  cursor: default;
  opacity: 0.75;
  transform: none;
}

.metro-choice.is-correct {
  background: rgba(46, 204, 113, 0.22);
  border-color: rgba(31, 158, 85, 0.95);
  box-shadow: 0 0 0 3px rgba(31, 158, 85, 0.25) inset;
}

.metro-choice.is-wrong {
  background: rgba(231, 76, 60, 0.20);
  border-color: rgba(231, 76, 60, 0.95);
  box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.22) inset;
}

@media (max-width: 520px) {
  .metro-choice {
    padding: 11px 10px;
    font-size: 0.95rem;
  }
}

.metro-stage {
  display: flex;
  align-items: center;
  justify-content: center;
}

.metro-panel {
  position: relative;
  z-index: 5;
  margin-block: auto;
}

.metro-panel-wrap:not(.is-hidden) {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  flex: 1;
  align-self: stretch;
}

.metro-map-wrap {
  width: 100%;
  height: 100%;
  flex: 1;
  min-height: 0;
  align-self: stretch;
}

#metro-map-host {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

#metro-map {
  width: min(100%, 1100px);
  height: auto;
  max-height: 100%;
  display: block;
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
}

.metro-province {
  fill: #e8edf8;
  stroke: #2a2a3a;
  stroke-width: 1;
  stroke-linejoin: round;
  cursor: pointer;
}

.metro-province:not(.found):hover {
  filter: brightness(1.06);
}

.metro-province.found {
  fill: var(--found) !important;
  cursor: default;
  filter: none;
}

.metro-label {
  fill: #fff;
  font-family: "Nunito", sans-serif;
  font-weight: 900;
  font-size: 12px;
  text-anchor: middle;
  dominant-baseline: middle;
  pointer-events: none;
  paint-order: stroke fill;
  stroke: rgba(0, 80, 40, 0.45);
  stroke-width: 3px;
}

.app-dialog {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: max(16px, var(--safe-top)) 16px max(16px, var(--safe-bottom));
}

.app-dialog.is-hidden {
  display: none;
}

.app-dialog-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 8, 20, 0.62);
}

.app-dialog-card {
  position: relative;
  text-align: center;
  background: linear-gradient(165deg, rgba(28, 37, 72, 0.96) 0%, rgba(18, 24, 47, 0.98) 100%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  padding: 18px 20px 16px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  max-width: min(360px, calc(100vw - 32px));
  width: 100%;
  backdrop-filter: blur(10px);
  animation: popIn 0.35s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}

.app-dialog-title {
  margin: 0 0 6px;
  font-size: clamp(1.2rem, 4.5vw, 1.5rem);
  font-weight: 900;
  color: #fff;
}

.app-dialog-message {
  margin: 0 0 16px;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.95rem;
  line-height: 1.35;
}

.app-dialog-actions {
  display: flex;
  gap: 10px;
}

.app-dialog-btn {
  flex: 1;
  border-radius: 12px;
  padding: 12px 14px;
  font-family: inherit;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
}

.app-dialog-cancel {
  color: #e8ecff;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.app-dialog-ok {
  border: none;
  color: #fff;
  background: linear-gradient(160deg, var(--purple), var(--purple-dark));
  box-shadow: 0 8px 20px rgba(90, 50, 214, 0.4);
}

.app-dialog-ok.is-danger {
  background: linear-gradient(160deg, #e74c3c, #c0392b);
  box-shadow: 0 8px 20px rgba(192, 57, 43, 0.4);
}
