:root {
  --bg-primary: #0a0f1d;
  --bg-secondary: #111827;
  --bg-card: rgba(17, 24, 39, 0.85);
  --border-color: rgba(255, 255, 255, 0.08);
  --border-glow: rgba(59, 130, 246, 0.3);
  
  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;
  
  --emerald: #10b981;
  --emerald-glow: rgba(16, 185, 129, 0.25);
  --cyan: #06b6d4;
  --cyan-glow: rgba(6, 182, 212, 0.25);
  --amber: #f59e0b;
  --amber-glow: rgba(245, 158, 11, 0.25);
  --crimson: #ef4444;
  --crimson-glow: rgba(239, 68, 68, 0.25);
  --purple: #a855f7;
  --purple-glow: rgba(168, 85, 247, 0.25);
  --slate: #475569;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-main);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.5;
  min-height: 100vh;
  overflow-x: hidden;
  background-image: radial-gradient(circle at 15% 15%, rgba(59, 130, 246, 0.08), transparent 45%),
                    radial-gradient(circle at 85% 85%, rgba(168, 85, 247, 0.08), transparent 45%);
}

.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding: 1rem 1.5rem;
  gap: 1.25rem;
}

/* TOP HEADER */
.hud-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(17, 24, 39, 0.96);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 0.9rem 1.5rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.brand {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.brand-logo {
  font-size: 2rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  padding: 0.4rem 0.6rem;
  border-radius: 12px;
}

.brand-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #fff, #93c5fd);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.hud-center {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.hud-metric {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.time-badge {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.3);
  padding: 0.3rem 1rem;
  border-radius: 8px;
}

.metric-label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--amber);
}

.metric-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  background: rgba(16, 185, 129, 0.15);
  color: var(--emerald);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-indicator .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--emerald);
  box-shadow: 0 0 8px var(--emerald);
}

.hud-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* BUTTONS */
.btn {
  padding: 0.6rem 1.1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.btn-emerald {
  background: linear-gradient(135deg, #059669, #10b981);
  color: #fff;
  box-shadow: 0 4px 14px var(--emerald-glow);
}
.btn-emerald:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px var(--emerald-glow);
}

.btn-slate {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-main);
  border-color: var(--border-color);
}
.btn-slate:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.14);
}

.btn-purple {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
}
.btn-purple:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(168, 85, 247, 0.5);
}

.btn-crimson {
  background: linear-gradient(135deg, #dc2626, #ef4444);
  color: #fff;
  box-shadow: 0 4px 14px var(--crimson-glow);
}
.btn-crimson:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px var(--crimson-glow);
}

/* MAIN DASHBOARD GRID */
.dashboard-grid {
  display: grid;
  grid-template-columns: 300px 1fr 370px;
  gap: 1.1rem;
  flex: 1;
}

.center-col {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  min-width: 0;
}

@media (max-width: 1380px) {
  .dashboard-grid {
    grid-template-columns: 280px 1fr;
  }
  .factions-card {
    grid-column: span 2;
  }
}

@media (max-width: 960px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
  .factions-card {
    grid-column: span 1;
  }
}

/* CARDS */
.card {
  background: rgba(17, 24, 39, 0.96);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  transform: translateZ(0);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.6rem;
}

.card-header h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: #fff;
}

/* BADGES */
.badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  text-transform: uppercase;
}

.badge-gold {
  background: rgba(245, 158, 11, 0.15);
  color: var(--amber);
  border: 1px solid rgba(245, 158, 11, 0.3);
}
.badge-purple {
  background: rgba(168, 85, 247, 0.15);
  color: var(--purple);
  border: 1px solid rgba(168, 85, 247, 0.3);
}

/* PLAYER STATS */
.player-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.stat-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 0.6rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.stat-label {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.progress-bar {
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.4s ease;
}

.hp-fill {
  background: linear-gradient(90deg, #ef4444, #10b981);
}
.stealth-fill {
  background: linear-gradient(90deg, #3b82f6, #06b6d4);
}

.stat-val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  font-weight: 600;
  text-align: right;
}

.stat-number {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.15rem;
  font-weight: 700;
}

.gold-text {
  color: var(--amber);
}

.inventory-section {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.section-label {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.inventory-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.item-tag {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  padding: 0.25rem 0.5rem;
  border-radius: 6px;
  font-size: 0.75rem;
  color: #e5e7eb;
}

.divider {
  border: none;
  border-top: 1px solid var(--border-color);
  margin-bottom: 1rem;
}

/* CHOICE PANEL */
.choice-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.choice-prompt-box {
  background: rgba(245, 158, 11, 0.05);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: 10px;
  padding: 0.8rem;
}

.prompt-time {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--amber);
  text-transform: uppercase;
}

.prompt-question {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  margin: 0.3rem 0;
  color: #fff;
}

.prompt-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.choice-buttons, .sub-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.choice-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 0.85rem 1.1rem;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.5rem;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  color: #fff;
  position: relative;
}

.choice-btn:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.choice-btn-main {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.op-badge-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  font-size: 0.7rem;
  margin-bottom: 2px;
}

.op-req-badge {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
  padding: 2px 7px;
  border-radius: 4px;
  font-weight: 600;
  border: 1px solid rgba(148, 163, 184, 0.25);
}

.op-risk-badge {
  padding: 2px 8px;
  border-radius: 4px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.risk-low {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.risk-med {
  background: rgba(234, 179, 8, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.risk-high {
  background: rgba(249, 115, 22, 0.18);
  color: #fb923c;
  border: 1px solid rgba(249, 115, 22, 0.35);
}

.risk-deadly {
  background: rgba(239, 68, 68, 0.22);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.45);
  animation: pulseDeadly 2.2s infinite ease-in-out;
}

@keyframes pulseDeadly {
  0%, 100% { border-color: rgba(239, 68, 68, 0.45); box-shadow: 0 0 6px rgba(239, 68, 68, 0.2); }
  50% { border-color: rgba(239, 68, 68, 0.85); box-shadow: 0 0 12px rgba(239, 68, 68, 0.4); }
}

.op-warning-tag {
  background: rgba(239, 68, 68, 0.15);
  color: #fca5a5;
  border: 1px dashed rgba(239, 68, 68, 0.4);
  padding: 3px 6px;
  border-radius: 4px;
  font-size: 0.68rem;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
}

.choice-btn.underleveled {
  border-color: rgba(239, 68, 68, 0.5) !important;
  background: rgba(239, 68, 68, 0.04);
}

.btn-icon {
  font-size: 1.4rem;
}

.btn-info strong {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
}

.btn-info small {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.choice-craft:hover {
  border-color: var(--amber);
  box-shadow: 0 0 12px var(--amber-glow);
}

.choice-explore:hover, .choice-recon:hover {
  border-color: var(--cyan);
  box-shadow: 0 0 12px var(--cyan-glow);
}

.choice-ambush:hover {
  border-color: var(--crimson);
  box-shadow: 0 0 14px var(--crimson-glow);
}

/* SUB DISCOVERY BOX */
.sub-choice-box {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  animation: fadeIn 0.3s ease;
}

.discovery-banner {
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.3);
  padding: 0.75rem;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.discovery-icon {
  font-size: 1.6rem;
}

.discovery-banner strong {
  display: block;
  font-size: 0.88rem;
  color: var(--cyan);
}

.discovery-banner p {
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* WAR BATTLE CLIMAX PANEL */
.war-choice-box {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  animation: warPulse 0.4s ease;
}

.war-banner {
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.4);
  padding: 0.8rem;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  box-shadow: 0 0 16px rgba(239, 68, 68, 0.2);
}

.war-icon {
  font-size: 1.8rem;
}

.war-banner p {
  font-size: 0.72rem;
  color: #fca5a5;
}

.war-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.choice-defense:hover {
  border-color: var(--emerald);
  box-shadow: 0 0 14px var(--emerald-glow);
}

.choice-attack:hover {
  border-color: var(--crimson);
  box-shadow: 0 0 14px var(--crimson-glow);
}

.choice-loot:hover {
  border-color: var(--amber);
  box-shadow: 0 0 14px var(--amber-glow);
}

@keyframes warPulse {
  0% { transform: scale(0.97); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.hidden {
  display: none !important;
}

/* TERMINAL LOG FEED */
.terminal-card {
  display: flex;
  flex-direction: column;
}

.terminal-title-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.terminal-dot.red { background: #ef4444; }
.terminal-dot.yellow { background: #f59e0b; }
.terminal-dot.green { background: #10b981; }

.terminal-controls {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.small-btn {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.7rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  cursor: pointer;
}
.small-btn:hover {
  color: #fff;
}

.autoscroll-toggle {
  font-size: 0.72rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.3rem;
  cursor: pointer;
}

.terminal-body {
  height: 270px;
  min-height: 220px;
  max-height: 300px;
  background: #060913;
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  padding: 0.85rem;
  overflow-y: auto;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.log-entry {
  display: flex;
  gap: 0.6rem;
  padding: 0.25rem 0.4rem;
  border-radius: 4px;
  animation: logSlide 0.2s ease-out;
}

.log-entry:hover {
  background: rgba(255, 255, 255, 0.03);
}

.log-time {
  color: var(--text-dim);
  font-size: 0.72rem;
  white-space: nowrap;
}

.log-tag {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.05rem 0.4rem;
  border-radius: 4px;
  text-transform: uppercase;
  white-space: nowrap;
}

.log-msg {
  color: #e5e7eb;
  word-break: break-word;
}

/* LOG COLORS & BADGES */
.tag-emerald, .color-emerald .log-tag, .log-emerald .log-tag {
  background: rgba(16, 185, 129, 0.22);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.45);
}
.msg-emerald, .color-emerald .log-msg { color: #d1fae5; }

.tag-cyan, .color-cyan .log-tag, .log-cyan .log-tag {
  background: rgba(6, 182, 212, 0.22);
  color: #38bdf8;
  border: 1px solid rgba(6, 182, 212, 0.45);
}
.msg-cyan, .color-cyan .log-msg { color: #e0f2fe; }

.tag-amber, .color-amber .log-tag, .log-amber .log-tag {
  background: rgba(245, 158, 11, 0.25);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.55);
}
.msg-amber, .color-amber .log-msg { color: #fef08a; }

.tag-crimson, .color-crimson .log-tag, .log-crimson .log-tag {
  background: rgba(239, 68, 68, 0.25);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.55);
}
.msg-crimson, .color-crimson .log-msg { color: #fecaca; }

.tag-purple, .color-purple .log-tag, .log-purple .log-tag {
  background: rgba(168, 85, 247, 0.25);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.55);
}
.msg-purple, .color-purple .log-msg { color: #f3e8ff; }

.tag-orange, .color-orange .log-tag, .log-orange .log-tag {
  background: rgba(249, 115, 22, 0.25);
  color: #fb923c;
  border: 1px solid rgba(249, 115, 22, 0.55);
}
.msg-orange, .color-orange .log-msg { color: #ffedd5; }

.tag-pink, .color-pink .log-tag, .log-pink .log-tag {
  background: rgba(244, 114, 182, 0.25);
  color: #f472b6;
  border: 1px solid rgba(244, 114, 182, 0.55);
}
.msg-pink, .color-pink .log-msg { color: #fce7f3; }

.tag-slate, .color-slate .log-tag, .log-slate .log-tag {
  background: rgba(148, 163, 184, 0.18);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.35);
}
.msg-slate, .color-slate .log-msg { color: #cbd5e1; }

.terminal-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.8rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--border-color);
}

.legend-item {
  font-size: 0.7rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
}
.badge-dot.emerald { background: var(--emerald); }
.badge-dot.cyan { background: var(--cyan); }
.badge-dot.amber { background: var(--amber); }
.badge-dot.purple { background: var(--purple); }
.badge-dot.crimson { background: var(--crimson); }

/* FACTIONS RADAR */
.factions-list {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  overflow-y: auto;
  max-height: 560px;
}

.faction-card-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 0.8rem;
  transition: all 0.2s ease;
}

.faction-card-item:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.15);
}

.faction-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.4rem;
}

.faction-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
}

.faction-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  font-size: 0.75rem;
}

.metric-row {
  display: flex;
  justify-content: space-between;
  color: var(--text-muted);
}
.metric-row span:last-child {
  font-family: 'JetBrains Mono', monospace;
  color: #e5e7eb;
}

.danger-tag {
  color: var(--crimson) !important;
  font-weight: 700;
}

/* MODAL */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 1.5rem;
  transform: translateZ(0);
}

.modal-content {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  width: 100%;
  max-width: 800px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.modal-header h2 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
}

.modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.25rem;
  cursor: pointer;
}
.modal-close:hover { color: #fff; }

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #d1d5db;
}

.modal-body h3 {
  color: #fff;
  margin: 1rem 0 0.4rem 0;
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border-color);
}

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

@keyframes logSlide {
  from { opacity: 0; transform: translateX(-10px); }
  to { opacity: 1; transform: translateX(0); }
}


/* REPTILIAN PSI & CHAOS STYLES */
.psi-fill {
  background: linear-gradient(90deg, #a855f7, #ec4899);
}

.chaos-text {
  color: #f97316 !important;
  font-weight: 700;
  text-shadow: 0 0 8px rgba(249, 115, 22, 0.4);
}

/* OPERATIONS & TARGETING DECK (CENTER BOTTOM) */
.operations-card {
  background: rgba(17, 24, 39, 0.96);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  transform: translateZ(0);
}

.targeting-bar {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(168, 85, 247, 0.35);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

.targeting-bar-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: #c084fc;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.targeting-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
}

@media (max-width: 900px) {
  .targeting-row {
    grid-template-columns: 1fr;
  }
}

.target-field {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.target-field label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
}

.styled-select {
  background: #0b1120;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  color: #f1f5f9;
  padding: 0.45rem 0.6rem;
  font-size: 0.8rem;
  font-family: inherit;
  outline: none;
  cursor: pointer;
  transition: all 0.2s ease;
}

.styled-select:focus {
  border-color: #a855f7;
  box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.25);
}

/* OPERATION CATEGORY TABS */
.op-tabs {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}

.op-tab-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  padding: 0.5rem 0.85rem;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.op-tab-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.op-tab-btn.active {
  background: rgba(168, 85, 247, 0.25);
  border-color: #a855f7;
  color: #f3e8ff;
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.35);
}

.op-tab-content {
  display: none;
}

.op-tab-content.active {
  display: block;
  animation: fadeIn 0.25s ease-out;
}

.op-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
}

@media (max-width: 1050px) {
  .op-grid {
    grid-template-columns: 1fr;
  }
}

/* CLIMATE STATUS CARD */
.climate-status-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 0.65rem 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 0.4rem;
}

.climate-icon {
  font-size: 1.6rem;
}

.climate-status-card strong {
  display: block;
  font-size: 0.82rem;
  color: #38bdf8;
}

.climate-status-card p {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

/* ADDITIONAL LEGEND DOTS & LOG TAGS */
.badge-dot.orange {
  background: #f97316;
  box-shadow: 0 0 6px #f97316;
}

.badge-dot.pink {
  background: #f472b6;
  box-shadow: 0 0 6px #f472b6;
}



/* SKILLS PROGRESSION PANEL */
.skills-progression-panel {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 0.8rem;
}

.progression-box {
  border-radius: 10px;
  padding: 0.65rem 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: all 0.2s ease;
}

.progression-box.highlight-purple {
  background: rgba(168, 85, 247, 0.08);
  border: 1px solid rgba(168, 85, 247, 0.4);
  box-shadow: 0 2px 10px rgba(168, 85, 247, 0.15);
}

.progression-box.highlight-emerald {
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.35);
  box-shadow: 0 2px 10px rgba(16, 185, 129, 0.12);
}

.progression-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.progression-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: #f1f5f9;
}

.progression-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
}

.prog-text {
  font-family: 'JetBrains Mono', monospace;
  color: #cbd5e1;
}

.mult-badge {
  background: rgba(234, 179, 8, 0.15);
  border: 1px solid rgba(234, 179, 8, 0.4);
  color: #fde047;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.68rem;
}

.persuasion-fill {
  background: linear-gradient(90deg, #8b5cf6, #d946ef);
}

.craft-count {
  font-size: 0.7rem;
  color: #94a3b8;
}


/* ======================================================== */
/* OTONOM DEV: TERMINAL TABS & PROGRESSION DECK 3-COL STYLES */
/* ======================================================== */

.terminal-tab-group {
  display: flex;
  gap: 0.4rem;
  margin-left: 1rem;
}

.terminal-tab {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.2);
  color: #94a3b8;
  padding: 0.3rem 0.75rem;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.terminal-tab:hover {
  background: rgba(30, 41, 59, 0.9);
  color: #f1f5f9;
}

.terminal-tab.active {
  background: rgba(99, 102, 241, 0.2);
  border-color: #818cf8;
  color: #c7d2fe;
  box-shadow: 0 0 10px rgba(99, 102, 241, 0.25);
}

.deck-mode-switcher {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.8rem;
  margin-bottom: 0.4rem;
}

.deck-mode-tab {
  flex: 1;
  padding: 0.6rem 1rem;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 8px;
  color: #94a3b8;
  font-family: 'Cinzel', serif;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.deck-mode-tab:hover {
  background: rgba(30, 41, 59, 0.95);
  color: #f8fafc;
  border-color: rgba(168, 85, 247, 0.4);
}

.deck-mode-tab.active {
  background: linear-gradient(135deg, rgba(147, 51, 234, 0.25), rgba(79, 70, 229, 0.2));
  border-color: #a855f7;
  color: #f3e8ff;
  box-shadow: 0 0 16px rgba(168, 85, 247, 0.25);
}

.progression-deck-card {
  background: rgba(15, 23, 42, 0.96);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 12px;
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  transform: translateZ(0);
  min-height: 480px;
}

.progression-deck-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
  padding-bottom: 0.6rem;
}

.progression-deck-header h3 {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  color: #e2e8f0;
  margin: 0;
}

.progression-three-col-grid {
  display: grid;
  grid-template-columns: 280px 280px 1fr;
  gap: 1rem;
  align-items: stretch;
}

.prog-col {
  background: rgba(11, 19, 38, 0.65);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.prog-col-header {
  padding: 0.65rem 0.85rem;
  background: rgba(30, 41, 59, 0.6);
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.prog-col-header h4 {
  margin: 0;
  font-size: 0.82rem;
  color: #f1f5f9;
  font-weight: 700;
}

.prog-col-body {
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  max-height: 400px;
  overflow-y: auto;
}

/* MAIN STAT CARD */
.stat-item-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: all 0.2s ease;
}

.stat-item-card:hover {
  border-color: rgba(168, 85, 247, 0.5);
  background: rgba(30, 41, 59, 0.8);
}

.stat-item-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.stat-name {
  font-weight: 600;
  font-size: 0.78rem;
  color: #e2e8f0;
}

.stat-lvl-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  background: rgba(168, 85, 247, 0.2);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.4);
}

.stat-bar-track {
  height: 6px;
  background: rgba(30, 41, 59, 0.8);
  border-radius: 3px;
  overflow: hidden;
}

.stat-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #8b5cf6);
  border-radius: 3px;
  transition: width 0.3s ease;
}

.stat-item-bot {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: #94a3b8;
  font-family: 'JetBrains Mono', monospace;
}

/* ALTER STAT CARD */
.alter-item-card {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.alter-label-group {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.alter-label {
  font-size: 0.76rem;
  color: #cbd5e1;
  font-weight: 500;
}

.alter-val-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.35);
}

/* SKILLS SEARCH & LIST */
.skills-search-bar {
  padding: 0.5rem 0.75rem;
  display: flex;
  gap: 0.5rem;
  background: rgba(15, 23, 42, 0.5);
  border-bottom: 1px solid rgba(148, 163, 184, 0.1);
}

.styled-input {
  flex: 1;
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: #f1f5f9;
  padding: 0.35rem 0.6rem;
  border-radius: 6px;
  font-size: 0.75rem;
}

.styled-input:focus {
  outline: none;
  border-color: #818cf8;
}

.styled-select-sm {
  background: rgba(15, 23, 42, 0.9);
  border: 1px solid rgba(148, 163, 184, 0.3);
  color: #cbd5e1;
  padding: 0.35rem 0.5rem;
  border-radius: 6px;
  font-size: 0.72rem;
}

.skills-scroll-body {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 0.5rem;
  max-height: 380px;
  overflow-y: auto;
}

.skill-chip {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 6px;
  padding: 0.45rem 0.6rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.skill-chip:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(99, 102, 241, 0.5);
  transform: translateY(-1px);
}

.skill-chip-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.skill-chip-name {
  font-size: 0.74rem;
  font-weight: 600;
  color: #e2e8f0;
}

.skill-chip-lvl {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.05rem 0.35rem;
  border-radius: 3px;
  background: rgba(99, 102, 241, 0.2);
  color: #a5b4fc;
}

.skill-chip-cat {
  font-size: 0.65rem;
  color: #64748b;
}

/* FUSION & BUFF BAR */
.fusion-buff-bar {
  background: rgba(30, 27, 75, 0.4);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: 8px;
  padding: 0.65rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.fusion-buff-title {
  font-size: 0.78rem;
  font-weight: 700;
  color: #e9d5ff;
}

.fusion-buff-items {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.fusion-btn {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.2), rgba(99, 102, 241, 0.25));
  border: 1px solid #c084fc;
  color: #f5d0fe;
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.fusion-btn:hover {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.4), rgba(99, 102, 241, 0.45));
  box-shadow: 0 0 12px rgba(192, 132, 252, 0.4);
  transform: scale(1.02);
}

.buff-active-tag {
  background: rgba(234, 179, 8, 0.15);
  border: 1px solid #facc15;
  color: #fef08a;
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  animation: pulseBuff 2s infinite ease-in-out;
}

@keyframes pulseBuff {
  0%, 100% { opacity: 0.85; }
  50% { opacity: 1; box-shadow: 0 0 10px rgba(250, 204, 21, 0.35); }
}


/* ======================================================== */
/* OTONOM DEV: ADVANCED CRAFTING WORKSHOP MODAL & WEAPON TIERS */
/* ======================================================== */

.crafting-modal-content {
  max-width: 980px !important;
  width: 95vw !important;
  background: rgba(15, 23, 42, 0.96) !important;
  border: 1px solid rgba(16, 185, 129, 0.4) !important;
  box-shadow: 0 0 35px rgba(16, 185, 129, 0.25) !important;
}

.modal-title-group {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.modal-icon {
  font-size: 1.8rem;
}

.modal-sub {
  font-size: 0.75rem;
  color: #94a3b8;
  margin: 0;
}

.crafting-modal-body {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 1.2rem;
  padding: 1rem 0;
  min-height: 460px;
}

.craft-categories-sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  background: rgba(11, 19, 38, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 8px;
  padding: 0.75rem;
}

.sidebar-title {
  font-size: 0.75rem;
  font-weight: 700;
  color: #94a3b8;
  text-transform: uppercase;
  margin-bottom: 0.3rem;
}

.craft-cat-btn {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(148, 163, 184, 0.2);
  color: #cbd5e1;
  padding: 0.55rem 0.75rem;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
}

.craft-cat-btn:hover {
  background: rgba(30, 41, 59, 0.9);
  color: #f1f5f9;
  border-color: rgba(16, 185, 129, 0.4);
}

.craft-cat-btn.active {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(5, 150, 105, 0.2));
  border-color: #10b981;
  color: #6ee7b7;
  box-shadow: 0 0 12px rgba(16, 185, 129, 0.25);
}

.craft-items-display {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  background: rgba(11, 19, 38, 0.6);
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 8px;
  padding: 0.85rem;
}

.craft-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
  padding-bottom: 0.6rem;
}

.craft-header-bar h3 {
  margin: 0;
  font-size: 0.95rem;
  color: #f8fafc;
}

.player-skills-indicator {
  display: flex;
  gap: 0.5rem;
}

.craft-items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 0.7rem;
  max-height: 380px;
  overflow-y: auto;
  padding-right: 0.3rem;
}

.craft-recipe-card {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 8px;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: all 0.2s ease;
}

.craft-recipe-card:hover {
  background: rgba(30, 41, 59, 0.95);
  border-color: rgba(16, 185, 129, 0.45);
  transform: translateY(-2px);
}

.recipe-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.recipe-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: #f1f5f9;
}

.recipe-tier-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  background: rgba(59, 130, 246, 0.2);
  color: #93c5fd;
  border: 1px solid rgba(59, 130, 246, 0.35);
}

.recipe-reqs {
  font-size: 0.72rem;
  color: #94a3b8;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.req-materials {
  color: #fde047;
  font-weight: 500;
}

.req-skills {
  color: #a5b4fc;
  font-size: 0.68rem;
}

.recipe-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(148, 163, 184, 0.1);
  padding-top: 0.45rem;
}

.recipe-chance {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  font-weight: 700;
}

.chance-high { color: #34d399; }
.chance-med { color: #facc15; }
.chance-low { color: #f87171; }

.btn-forge {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(5, 150, 105, 0.3));
  border: 1px solid #10b981;
  color: #a7f3d0;
  padding: 0.3rem 0.75rem;
  border-radius: 6px;
  font-size: 0.74rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-forge:hover:not(:disabled) {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.45), rgba(5, 150, 105, 0.5));
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.4);
  transform: scale(1.03);
}

.btn-forge:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  border-color: #64748b;
  color: #94a3b8;
}

.craft-tip {
  font-size: 0.72rem;
  color: #94a3b8;
}


/* MASTERY & PRESTIGE PROMOTION BUTTON & BADGES */
.btn-mastery-promote {
  background: linear-gradient(135deg, #eab308, #ca8a04);
  color: #0f172a;
  border: 1px solid #fef08a;
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.74rem;
  cursor: pointer;
  box-shadow: 0 0 14px rgba(234, 179, 8, 0.4);
  animation: pulseGold 2s infinite ease-in-out;
  transition: all 0.2s ease;
}

.btn-mastery-promote:hover {
  transform: scale(1.04);
  box-shadow: 0 0 20px rgba(250, 204, 21, 0.6);
}

@keyframes pulseGold {
  0%, 100% { box-shadow: 0 0 10px rgba(234, 179, 8, 0.3); }
  50% { box-shadow: 0 0 18px rgba(250, 204, 21, 0.7); }
}

.badge-mastery {
  background: rgba(234, 179, 8, 0.2);
  color: #fef08a;
  border: 1px solid #eab308;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
}

.status-badge-pass {
  background: rgba(16, 185, 129, 0.2);
  color: #6ee7b7;
  border: 1px solid #10b981;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.75rem;
}

.status-badge-fail {
  background: rgba(239, 68, 68, 0.2);
  color: #fca5a5;
  border: 1px solid #ef4444;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.75rem;
}


/* ======================================================== */
/* OTONOM DEV: CRAFTING 4-QUALITY & 4-FAILURE RESULT STYLES */
/* ======================================================== */

.craft-result-content {
  max-width: 560px !important;
  background: rgba(15, 23, 42, 0.98) !important;
  border-radius: 12px;
  box-shadow: 0 0 35px rgba(0, 0, 0, 0.8) !important;
}

.result-card-display {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  padding: 0.5rem;
}

.result-badge-banner {
  padding: 0.75rem 1rem;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.banner-efsanevi {
  background: linear-gradient(135deg, rgba(234, 179, 8, 0.3), rgba(202, 138, 4, 0.15));
  border: 1px solid #facc15;
  color: #fef08a;
  box-shadow: 0 0 15px rgba(250, 204, 21, 0.3);
}

.banner-destansi {
  background: linear-gradient(135deg, rgba(168, 85, 247, 0.3), rgba(126, 34, 206, 0.15));
  border: 1px solid #c084fc;
  color: #f5d0fe;
  box-shadow: 0 0 15px rgba(192, 132, 252, 0.3);
}

.banner-normal {
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.3), rgba(29, 78, 216, 0.15));
  border: 1px solid #60a5fa;
  color: #bfdbfe;
}

.banner-kusurlu {
  background: linear-gradient(135deg, rgba(148, 163, 184, 0.25), rgba(71, 85, 105, 0.15));
  border: 1px solid #94a3b8;
  color: #cbd5e1;
}

.banner-fail-kilpayi {
  background: linear-gradient(135deg, rgba(249, 115, 22, 0.25), rgba(194, 65, 12, 0.15));
  border: 1px solid #fb923c;
  color: #fed7aa;
}

.banner-fail-kismi {
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(185, 28, 28, 0.15));
  border: 1px solid #f87171;
  color: #fecaca;
}

.banner-fail-agir {
  background: linear-gradient(135deg, rgba(185, 28, 28, 0.35), rgba(127, 29, 29, 0.2));
  border: 1px solid #ef4444;
  color: #fca5a5;
}

.banner-fail-feci {
  background: linear-gradient(135deg, rgba(153, 27, 27, 0.5), rgba(69, 10, 10, 0.3));
  border: 1px solid #dc2626;
  color: #fecaca;
  box-shadow: 0 0 15px rgba(220, 38, 38, 0.4);
}

.result-stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  background: rgba(11, 19, 38, 0.7);
  padding: 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.15);
}

.result-stat-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.stat-item-label {
  font-size: 0.7rem;
  color: #94a3b8;
  text-transform: uppercase;
}

.stat-item-val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  font-weight: 700;
  color: #f8fafc;
}

.result-narrative {
  font-size: 0.78rem;
  line-height: 1.4;
  color: #cbd5e1;
  padding: 0.5rem 0.2rem;
}

/* ========================================================================= */
/* CRAFTING SPOTLIGHT BANNER (PROMINENT CENTER DASHBOARD ACCESS)             */
/* ========================================================================= */
.crafting-spotlight-box {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.12), rgba(15, 23, 42, 0.95));
  border: 2px solid rgba(16, 185, 129, 0.45);
  border-radius: 14px;
  padding: 1.1rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.18);
  margin-bottom: 0.5rem;
}

.spotlight-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.spotlight-title-group {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.spotlight-icon {
  font-size: 2.2rem;
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(16, 185, 129, 0.5);
  border-radius: 12px;
  padding: 0.35rem 0.6rem;
}

.spotlight-title-group h3 {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #a7f3d0;
  letter-spacing: 0.02em;
}

.spotlight-title-group p {
  font-size: 0.8rem;
  color: #94a3b8;
  margin-top: 0.15rem;
}

.btn-craft-pulse {
  background: linear-gradient(135deg, #10b981, #059669);
  color: #ffffff;
  font-weight: 800;
  font-size: 0.92rem;
  padding: 0.75rem 1.4rem;
  border-radius: 10px;
  border: 1px solid #34d399;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.5);
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.btn-craft-pulse:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(16, 185, 129, 0.75);
}

.spotlight-quick-info {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(16, 185, 129, 0.2);
}

.info-pill {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 8px;
  padding: 0.35rem 0.65rem;
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.info-pill strong {
  color: #38bdf8;
}

.pill-badge {
  background: rgba(168, 85, 247, 0.25);
  color: #c084fc;
  padding: 0.1rem 0.4rem;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
}

/* CRAFT DEBUG CONTROLS IN MODAL */
.craft-debug-controls {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(59, 130, 246, 0.3);
  border-radius: 8px;
  padding: 0.45rem 0.75rem;
  font-size: 0.75rem;
  margin-bottom: 0.6rem;
}

.craft-debug-controls span {
  font-weight: 600;
  color: #93c5fd;
}

.btn-sm {
  padding: 0.25rem 0.55rem;
  font-size: 0.72rem;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: all 0.15s ease;
}

.btn-sm:hover {
  filter: brightness(1.15);
}

/* 184 SKILLS CATALOG MODAL & GRID */
.skills-catalog-content {
  max-width: 1200px;
  width: 95%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
}

.skills-catalog-body {
  padding: 1rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  overflow-y: hidden;
  flex: 1;
}

.skills-filter-row {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.category-pills-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.cat-pill {
  background: rgba(30, 41, 59, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.2);
  color: #cbd5e1;
  border-radius: 20px;
  padding: 0.3rem 0.75rem;
  font-size: 0.76rem;
  cursor: pointer;
  transition: all 0.15s ease;
}

.cat-pill:hover, .cat-pill.active {
  background: #a855f7;
  color: #ffffff;
  border-color: #c084fc;
  box-shadow: 0 0 10px rgba(168, 85, 247, 0.4);
}

.skills-grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0.75rem;
  overflow-y: auto;
  max-height: 60vh;
  padding-right: 0.4rem;
  transform: translateZ(0);
}

.skill-catalog-card {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.skill-catalog-card:hover {
  transform: translateY(-2px);
  border-color: rgba(168, 85, 247, 0.5);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.skill-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.skill-card-name {
  font-weight: 700;
  font-size: 0.85rem;
  color: #f1f5f9;
}

.skill-card-en {
  font-size: 0.7rem;
  color: #94a3b8;
  font-style: italic;
}

.skill-card-badge {
  background: rgba(168, 85, 247, 0.2);
  color: #d8b4fe;
  border: 1px solid rgba(168, 85, 247, 0.35);
  font-size: 0.68rem;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  white-space: nowrap;
}

.skill-card-desc {
  font-size: 0.73rem;
  line-height: 1.35;
  color: #94a3b8;
  flex: 1;
}

.skill-card-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 0.4rem;
  border-top: 1px solid rgba(148, 163, 184, 0.1);
}

.skill-lvl-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  color: #38bdf8;
}

.btn-skill-inc {
  background: rgba(16, 185, 129, 0.2);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #34d399;
  font-size: 0.68rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 600;
}

.btn-skill-inc:hover {
  background: #10b981;
  color: #ffffff;
}

/* 184 SKILLS LAUNCHER (LEFT PANEL) */
.skills-184-launcher {
  margin-top: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.skills-summary-pills {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.pill-mini {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  font-size: 0.66rem;
  color: #cbd5e1;
  padding: 0.15rem 0.35rem;
}

/* ========================================================================= */
/* DOĞAL KAYNAK & MATERYAL TOPLAMA SAHASI                                     */
/* ========================================================================= */
.gathering-spotlight-box {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.12), rgba(15, 23, 42, 0.95));
  border: 2px solid rgba(14, 165, 233, 0.40);
  border-radius: 14px;
  padding: 1.1rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: 0 0 20px rgba(14, 165, 233, 0.15);
  margin-bottom: 0.75rem;
}

.gathering-stock-badge {
  background: rgba(14, 165, 233, 0.15);
  border: 1px solid rgba(14, 165, 233, 0.35);
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #38bdf8;
}

.gathering-buttons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 0.75rem;
}

.gather-btn {
  background: rgba(30, 41, 59, 0.75);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  color: #e2e8f0;
}

.gather-btn:hover {
  background: rgba(14, 165, 233, 0.18);
  border-color: rgba(14, 165, 233, 0.6);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(14, 165, 233, 0.25);
}

.gather-icon {
  font-size: 1.8rem;
  line-height: 1;
}

.gather-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
}

.gather-info strong {
  font-size: 0.88rem;
  color: #f1f5f9;
}

.gather-gains {
  display: flex;
  flex-direction: column;
  font-size: 0.72rem;
  line-height: 1.25;
}

.gain-stat {
  color: #fbbf24;
  font-weight: 600;
}

.gain-skill {
  color: #34d399;
}

.gather-reward {
  font-size: 0.74rem;
  font-weight: 700;
  color: #38bdf8;
  margin-top: 2px;
}



/* ==========================================================================
   THE FORGOTTEN ARRIVAL - MODULAR TABBED WORKSPACE & IMAGE 1 & 2 UI STYLES
   ========================================================================== */

.theme-dark-rpg {
  background-color: #0d0a08;
  color: #dcd0be;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

.app-layout {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* TOP GAME HEADER (Matching Image 1 & 2) */
.top-game-header {
  background: linear-gradient(180deg, #18120c 0%, #110d09 100%);
  border-bottom: 2px solid #36281b;
  padding: 10px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-branding {
  display: flex;
  align-items: center;
  gap: 14px;
}

.sidebar-toggle-btn {
  background: #241a12;
  border: 1px solid #4d3826;
  color: #dfcfb8;
  width: 38px;
  height: 38px;
  border-radius: 6px;
  font-size: 1.25rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.sidebar-toggle-btn:hover {
  background: #38271a;
  border-color: #c69a48;
  color: #fce8cc;
  transform: scale(1.05);
}

.title-meta {
  display: flex;
  flex-direction: column;
}

.game-main-title {
  font-family: 'Cinzel', serif;
  font-size: 1.35rem;
  font-weight: 800;
  color: #f1e3ce;
  letter-spacing: 1.5px;
  margin: 0;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.8), 0 0 10px rgba(198, 154, 72, 0.25);
}

.game-subtitle {
  font-family: 'Crimson Text', serif;
  font-size: 0.82rem;
  color: #9c8a77;
  margin: 2px 0 0 0;
  font-style: italic;
  letter-spacing: 0.3px;
}

/* SIMULATION CONTROLS IN HEADER */
.header-sim-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.sim-time-badge {
  background: #1e1610;
  border: 1px solid #4a3826;
  border-radius: 6px;
  padding: 6px 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 700;
  color: #e5d7c3;
  margin-right: 4px;
}

.btn-top-action {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  border-radius: 6px;
  padding: 7px 12px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.18s ease;
  border: 1px solid transparent;
  white-space: nowrap;
}

.btn-sim-play {
  background: rgba(13, 148, 136, 0.2);
  border-color: #14b8a6;
  color: #5eead4;
}
.btn-sim-play:hover {
  background: #0d9488;
  color: #fff;
  box-shadow: 0 0 12px rgba(20, 184, 166, 0.5);
}

.btn-sim-pause {
  background: rgba(30, 58, 95, 0.3);
  border-color: #38bdf8;
  color: #7dd3fc;
}
.btn-sim-pause:hover:not(:disabled) {
  background: #0284c7;
  color: #fff;
}
.btn-sim-pause:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  border-color: #475569;
  color: #94a3b8;
}

.btn-sim-step {
  background: rgba(147, 51, 234, 0.25);
  border-color: #a855f7;
  color: #d8b4fe;
}
.btn-sim-step:hover {
  background: #7e22ce;
  color: #fff;
  box-shadow: 0 0 12px rgba(168, 85, 247, 0.45);
}

.btn-sim-reset {
  background: rgba(63, 63, 70, 0.3);
  border-color: #71717a;
  color: #d4d4d8;
}
.btn-sim-reset:hover {
  background: #52525b;
  color: #fff;
}

.btn-sim-pdf {
  background: rgba(225, 29, 72, 0.25);
  border-color: #f43f5e;
  color: #fda4af;
  font-weight: 800;
}
.btn-sim-pdf:hover {
  background: #be123c;
  color: #fff;
  box-shadow: 0 0 14px rgba(244, 63, 94, 0.5);
}

/* WORKSPACE LAYOUT */
.game-workspace {
  display: flex;
  flex: 1;
  min-height: calc(100vh - 65px);
  position: relative;
}

/* LEFT COLLAPSIBLE SIDEBAR */
.game-sidebar {
  width: 175px;
  background: #130e0a;
  border-right: 2px solid #2d2116;
  display: flex;
  flex-direction: column;
  transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-x: hidden;
  z-index: 50;
}

.game-sidebar.collapsed {
  width: 54px;
}

.sidebar-header-bar {
  padding: 10px;
  display: flex;
  justify-content: flex-start;
  border-bottom: 1px solid #261b12;
}

.sidebar-close-btn {
  background: transparent;
  border: none;
  color: #bfa892;
  font-size: 1.25rem;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all 0.2s;
}

.sidebar-close-btn:hover {
  color: #ffd899;
  background: rgba(198, 154, 72, 0.15);
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  padding: 8px 6px;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 10px 12px;
  color: #aa9885;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s ease;
  white-space: nowrap;
}

.nav-item:hover {
  background: rgba(198, 154, 72, 0.08);
  border-color: #4a3723;
  color: #f0e2cf;
}

.nav-item.active {
  background: linear-gradient(90deg, rgba(198, 154, 72, 0.2) 0%, rgba(198, 154, 72, 0.05) 100%);
  border-color: #c69a48;
  color: #fff;
  box-shadow: inset 3px 0 0 #c69a48;
}

.nav-icon {
  font-size: 1.15rem;
  min-width: 24px;
  text-align: center;
}

.game-sidebar.collapsed .nav-label {
  display: none;
}

/* MAIN VIEWPORT */
.main-content-viewport {
  flex: 1;
  background: #0f0b08;
  padding: 16px 20px;
  overflow-y: auto;
  max-width: 100%;
}

.content-view-pane {
  display: none;
}

.content-view-pane.active {
  display: block;
  animation: fadeInView 0.2s ease-in-out;
}

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

/* ==========================================================================
   VIEW 1: IMAGE 1 & 2 MATCHING SECTIONS
   ========================================================================== */

/* ROW 1: ATELIER SPOTLIGHT CARD */
.atelier-spotlight-card {
  background: linear-gradient(135deg, #18120c 0%, #140e09 100%);
  border: 1px solid #3d2c1d;
  border-radius: 8px;
  padding: 16px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  position: relative;
}

.atelier-left-content {
  display: flex;
  align-items: center;
  gap: 16px;
}

.atelier-icon-wrap {
  width: 44px;
  height: 44px;
  background: rgba(198, 154, 72, 0.1);
  border: 1px solid #5a4128;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

.atelier-meta h2 {
  font-family: 'Cinzel', serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: #eedcc4;
  margin: 0;
  letter-spacing: 0.5px;
}

.atelier-meta p {
  font-size: 0.82rem;
  color: #968370;
  margin: 3px 0 0 0;
}

.btn-atelier-open {
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid #10b981;
  color: #34d399;
  font-family: 'Inter', sans-serif;
  font-size: 0.86rem;
  font-weight: 800;
  padding: 9px 18px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
}

.btn-atelier-open:hover {
  background: #10b981;
  color: #064e3b;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.5);
  transform: translateY(-1px);
}

/* ROW 2: GATHERING SECTION CARD */
.gathering-section-card {
  background: #140e0a;
  border: 1px solid #332417;
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 16px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}

.gathering-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.gathering-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
}

.gather-flask-icon {
  width: 40px;
  height: 40px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid #1e3a2f;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  color: #10b981;
}

.gathering-title {
  font-family: 'Cinzel', serif;
  font-size: 1.02rem;
  font-weight: 700;
  color: #e8d7c0;
  margin: 0;
}

.gathering-desc {
  font-size: 0.8rem;
  color: #93806f;
  margin: 2px 0 0 0;
}

.btn-gather-info {
  background: rgba(14, 116, 144, 0.2);
  border: 1px solid #0891b2;
  color: #38bdf8;
  font-size: 0.82rem;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.gathering-areas-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.gather-area-card {
  background: #1a130d;
  border: 1px solid #3a291b;
  border-radius: 8px;
  padding: 14px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}

.gather-area-card:hover {
  background: #231911;
  border-color: #c69a48;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4), 0 0 10px rgba(198, 154, 72, 0.2);
  transform: translateY(-2px);
}

.gather-area-card:active {
  transform: translateY(0);
}

.area-icon-box {
  font-size: 1.6rem;
  min-width: 36px;
  text-align: center;
}

.area-name {
  font-size: 0.86rem;
  font-weight: 700;
  color: #ead9c3;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.area-meta {
  font-size: 0.74rem;
  color: #8c7967;
  margin-top: 3px;
}

/* ROW 3: TASKS DASHBOARD CARD */
.tasks-dashboard-card {
  background: #140e0a;
  border: 1px solid #332417;
  border-radius: 8px;
  padding: 16px 20px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}

.tasks-filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}

.task-tabs-group {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.task-tab-btn {
  background: #1d1610;
  border: 1px solid #3c2a1c;
  color: #a89684;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.16s ease;
}

.task-tab-btn:hover {
  background: #281d14;
  color: #f1e2ce;
  border-color: #5d422b;
}

.task-tab-btn.active {
  background: #f1e2cc;
  color: #17110a;
  border-color: #f1e2cc;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.tasks-sort-select {
  background: #1c150e;
  border: 1px solid #3e2c1c;
  color: #cebeaa;
  font-size: 0.8rem;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  outline: none;
}

.tasks-sort-select:hover,
.tasks-sort-select:focus {
  border-color: #c69a48;
}

.task-cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.task-card-item {
  background: #19120c;
  border: 1px solid #362618;
  border-radius: 8px;
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  transition: all 0.18s ease;
}

.task-card-item:hover {
  background: #201710;
  border-color: #4f3925;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.35);
}

.task-card-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.task-icon-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #241a12;
  border: 1px solid #4a3624;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  flex-shrink: 0;
}

.icon-warn {
  color: #f59e0b;
  border-color: rgba(245, 158, 11, 0.4);
}

.icon-scout {
  color: #60a5fa;
  border-color: rgba(96, 165, 250, 0.4);
}

.icon-craft {
  color: #34d399;
  border-color: rgba(52, 211, 153, 0.4);
}

.icon-herbs {
  color: #4ade80;
  border-color: rgba(74, 222, 128, 0.4);
}

.icon-team {
  color: #c084fc;
  border-color: rgba(192, 132, 252, 0.4);
}

.icon-mine {
  color: #fb923c;
  border-color: rgba(251, 146, 60, 0.4);
}

.task-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #ece0cc;
  margin: 0;
}

.task-desc {
  font-size: 0.77rem;
  color: #8c7b6a;
  margin: 2px 0 0 0;
}

.task-badge {
  font-size: 0.74rem;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 6px;
  white-space: nowrap;
}

.badge-ongoing {
  background: rgba(220, 38, 38, 0.15);
  border: 1px solid #b91c1c;
  color: #fca5a5;
}

.badge-completed {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid #10b981;
  color: #6ee7b7;
}

/* OTHER PANES (Inventory, Factions, Operations) */
.pane-grid-two-col {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 16px;
}

@media (max-width: 1200px) {
  .gathering-areas-row {
    grid-template-columns: repeat(3, 1fr);
  }
  .task-cards-grid {
    grid-template-columns: 1fr;
  }
  .pane-grid-two-col {
    grid-template-columns: 1fr;
  }
}


/* ==========================================================================
   TACTILE VISUAL RPG INVENTORY SYSTEM (#viewInventory)
   ========================================================================== */
.rpg-inventory-container {
  background: linear-gradient(145deg, #16100b 0%, #100c08 100%);
  border: 1px solid #3c2a1a;
  border-radius: 10px;
  padding: 18px 22px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.65);
}

.inv-top-status-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid #2e2014;
  margin-bottom: 14px;
}

.inv-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
}

.inv-bag-crest {
  width: 46px;
  height: 46px;
  background: rgba(198, 154, 72, 0.14);
  border: 1px solid #8a6429;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.55rem;
}

.inv-main-heading {
  font-family: 'Cinzel', serif;
  font-size: 1.12rem;
  font-weight: 800;
  color: #f3e3c9;
  margin: 0;
  letter-spacing: 0.6px;
}

.inv-sub-heading {
  font-size: 0.8rem;
  color: #9c8873;
  margin: 3px 0 0 0;
}

.inv-metrics-pills {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.inv-metric-pill {
  background: #1b130d;
  border: 1px solid #3e2c1c;
  border-radius: 8px;
  padding: 7px 13px;
  display: flex;
  align-items: center;
  gap: 9px;
}

.inv-metric-pill .m-ico {
  font-size: 1.2rem;
}

.inv-metric-pill small {
  display: block;
  font-size: 0.68rem;
  color: #8f7c68;
  text-transform: uppercase;
}

.inv-metric-pill strong {
  font-size: 0.9rem;
  color: #f4e6d2;
  font-family: 'JetBrains Mono', monospace;
}

.gold-pill { border-color: rgba(234, 179, 8, 0.45); }
.gold-pill strong { color: #facc15; }
.mat-pill { border-color: rgba(16, 185, 129, 0.45); }
.mat-pill strong { color: #34d399; }

.inv-filter-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.inv-category-tabs {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.inv-tab-pill {
  background: #1c140e;
  border: 1px solid #3b2a1a;
  color: #b5a18c;
  font-size: 0.81rem;
  font-weight: 700;
  padding: 7px 14px;
  border-radius: 20px;
  cursor: pointer;
  transition: all 0.18s ease;
}

.inv-tab-pill:hover {
  background: #281c13;
  color: #f4e6d2;
  border-color: #7c5826;
}

.inv-tab-pill.active {
  background: linear-gradient(180deg, #c69a48 0%, #91632d 100%);
  color: #160e07;
  border-color: #e5be72;
  box-shadow: 0 2px 10px rgba(198, 154, 72, 0.35);
}

.inv-search-box input {
  background: #18110b;
  border: 1px solid #3f2d1d;
  color: #eedcc4;
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 0.82rem;
  min-width: 250px;
  outline: none;
}

.inv-search-box input:focus {
  border-color: #c69a48;
}

.inv-three-col-layout {
  display: grid;
  grid-template-columns: 270px 1fr 310px;
  gap: 16px;
  align-items: start;
}

/* PAPERDOLL PANEL */
.inv-paperdoll-panel {
  background: #17110b;
  border: 1px solid #382718;
  border-radius: 8px;
  padding: 14px;
}

.paperdoll-header h3 {
  font-family: 'Cinzel', serif;
  font-size: 0.92rem;
  color: #e8d4ac;
  margin: 0;
}

.paperdoll-sub {
  font-size: 0.73rem;
  color: #8c7864;
}

.paperdoll-slots-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 12px 0;
}

.doll-slot-row {
  background: #1f160f;
  border: 1px solid #3b2919;
  border-radius: 6px;
  padding: 8px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.doll-slot-ico {
  font-size: 1.25rem;
  width: 28px;
  text-align: center;
}

.doll-slot-info small {
  display: block;
  font-size: 0.68rem;
  color: #8c7865;
}

.doll-slot-info strong {
  font-size: 0.8rem;
  color: #efdrc4;
  color: #f0dfc8;
}

.paperdoll-combat-summary {
  background: #120d08;
  border: 1px solid #332315;
  border-radius: 6px;
  padding: 8px 10px;
  display: flex;
  justify-content: space-between;
  font-size: 0.76rem;
}

.c-sum-item span { color: #8c7865; }
.c-sum-item strong { color: #c69a48; margin-left: 3px; }

/* VISUAL SLOTS GRID */
.inv-slots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
  gap: 10px;
  max-height: 540px;
  overflow-y: auto;
  padding-right: 4px;
}

.inv-slot-card {
  background: linear-gradient(160deg, #21170f 0%, #17100a 100%);
  border: 1px solid #3e2c1b;
  border-radius: 8px;
  padding: 10px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 132px;
  transition: all 0.16s ease;
  position: relative;
}

.inv-slot-card:hover {
  transform: translateY(-2px);
  border-color: #c69a48;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.55);
}

.inv-slot-card.active-slot {
  border-color: #facc15;
  box-shadow: 0 0 0 1px #facc15, 0 4px 14px rgba(250, 204, 21, 0.25);
  background: linear-gradient(160deg, #2b1e13 0%, #1d140c 100%);
}

.inv-slot-card.rarity-uncommon { border-left: 3px solid #34d399; }
.inv-slot-card.rarity-rare { border-left: 3px solid #60a5fa; }
.inv-slot-card.rarity-epic { border-left: 3px solid #c084fc; }
.inv-slot-card.rarity-legendary { border-left: 3px solid #f59e0b; }

.slot-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.68rem;
}

.slot-tier-tag {
  color: #9c8873;
  font-weight: 600;
}

.slot-eq-badge {
  background: rgba(16, 185, 129, 0.22);
  border: 1px solid #10b981;
  color: #6ee7b7;
  font-size: 0.6rem;
  font-weight: 800;
  padding: 1px 5px;
  border-radius: 4px;
}

.slot-qty-tag {
  background: #120c07;
  border: 1px solid #47321f;
  color: #f3e3c9;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 4px;
}

.slot-center-art {
  text-align: center;
  margin: 8px 0;
}

.slot-icon-glyph {
  font-size: 2.1rem;
  filter: drop-shadow(0 2px 6px rgba(0,0,0,0.6));
}

.slot-item-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: #f1e2cc;
  line-height: 1.2;
}

.slot-spec-preview {
  font-size: 0.7rem;
  color: #c69a48;
  margin-top: 2px;
}

/* RIGHT INSPECTION PANEL */
.inv-inspect-panel {
  background: #17110b;
  border: 1px solid #3c2a1a;
  border-radius: 8px;
  padding: 16px;
}

.inv-inspect-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid #2e2014;
}

.inv-inspect-art-box {
  width: 56px;
  height: 56px;
  background: #23180f;
  border: 1px solid #6b4c24;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  flex-shrink: 0;
}

.inv-badges-row {
  display: flex;
  gap: 6px;
  margin-bottom: 4px;
}

.inv-rarity-badge {
  font-size: 0.66rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  background: #291d12;
  color: #d8be8f;
}

.inv-tier-badge {
  font-size: 0.66rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(198, 154, 72, 0.2);
  color: #facc15;
}

.inv-inspect-titles h3 {
  font-family: 'Cinzel', serif;
  font-size: 0.98rem;
  color: #f5e6cf;
  margin: 0;
}

.inv-cat-label {
  font-size: 0.73rem;
  color: #9c8873;
}

.inv-inspect-specs {
  margin: 12px 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #120d08;
  border: 1px solid #2d1f13;
  border-radius: 6px;
  padding: 10px;
}

.inv-spec-line {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
}

.inv-spec-line span { color: #937f6b; }
.inv-spec-line strong { color: #efe0ca; }

.inv-inspect-desc {
  font-size: 0.8rem;
  color: #cbbba6;
  line-height: 1.45;
  margin: 10px 0;
}

.inv-inspect-quote {
  font-family: 'Crimson Text', serif;
  font-style: italic;
  font-size: 0.82rem;
  color: #c69a48;
  border-left: 2px solid #91632d;
  padding-left: 10px;
  margin: 10px 0 14px 0;
}

.inv-inspect-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.btn-inv-action {
  width: 100%;
  padding: 9px 12px;
  border-radius: 6px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.16s ease;
}

.btn-inv-primary {
  background: linear-gradient(180deg, #c69a48 0%, #8f6129 100%);
  border: 1px solid #e6c278;
  color: #170f07;
}

.btn-inv-craft {
  background: rgba(16, 185, 129, 0.16);
  border: 1px solid #10b981;
  color: #6ee7b7;
}

.btn-inv-sell {
  background: rgba(234, 179, 8, 0.14);
  border: 1px solid #ca8a04;
  color: #fde047;
}

/* ==========================================================================
   GRIMOIRE 184 SKILLS PARCHMENT LIST & PILLS
   ========================================================================== */
.grimoire-skills-filter-bar {
  margin-bottom: 10px;
}

.grimoire-search-input {
  width: 100%;
  background: #f5e9d0;
  border: 1px solid #91632d;
  color: #2d1a0f;
  padding: 7px 11px;
  border-radius: 6px;
  font-size: 0.82rem;
  margin-bottom: 8px;
  outline: none;
}

.grimoire-cat-pills {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

.g-cat-pill {
  background: #e2d1b0;
  border: 1px solid #91632d;
  color: #382013;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 9px;
  border-radius: 14px;
  cursor: pointer;
}

.g-cat-pill.active {
  background: #382013;
  color: #f5e6c8;
  border-color: #c69a48;
}

.grimoire-skills-scroll-list {
  max-height: 360px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-right: 4px;
}

.grimoire-skill-row {
  background: rgba(232, 212, 172, 0.75);
  border: 1px solid #b08954;
  border-radius: 6px;
  padding: 7px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.14s ease;
}

.grimoire-skill-row:hover,
.grimoire-skill-row.active {
  background: #f6e7c6;
  border-color: #724a1d;
  box-shadow: 0 2px 6px rgba(56, 32, 19, 0.2);
}

.g-skill-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.g-skill-icon {
  font-size: 1.25rem;
}

.g-skill-name {
  font-family: 'Cinzel', serif;
  font-size: 0.84rem;
  font-weight: 700;
  color: #2d1a0f;
}

.g-skill-meta {
  font-size: 0.68rem;
  color: #5a3a1e;
  display: flex;
  gap: 6px;
}

.g-skill-right {
  text-align: right;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}

.g-skill-level-text {
  font-size: 0.74rem;
  font-weight: 700;
  color: #382013;
}

.g-skill-bar-wrap {
  width: 90px;
  height: 5px;
  background: #cbb286;
  border-radius: 3px;
  overflow: hidden;
}

.g-skill-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #91632d, #c69a48);
}

.btn-g-skill-inc {
  background: #382013;
  color: #f3dfc1;
  border: 1px solid #91632d;
  border-radius: 4px;
  font-size: 0.66rem;
  font-weight: 700;
  padding: 2px 7px;
  cursor: pointer;
}

.btn-g-skill-inc:hover {
  background: #52301c;
}

@media (max-width: 1200px) {
  .inv-three-col-layout {
    grid-template-columns: 1fr;
  }
}
