/* ==========================================================================
   DIRILIŞ ONLINE - THEME: CLASSIC LIGHT PARCHMENT (Açık Parşömen)
   Inspired by Ancient Cartography, Steppe Leather, Papyrus & Antique Bronze
   Strictly Scoped to: html[data-theme="parchment"]
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. ROOT THEME DESIGN TOKENS (WARM IVORY, AGED PARCHMENT & ANTIQUE BRONZE)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] {
  --dirilis-bg-dark: #f5efe0;
  --dirilis-panel-bg: rgba(246, 241, 230, 0.75);
  --dirilis-panel-border: #8c6534;
  --dirilis-gold-accent: #7c4d16;
  --dirilis-gold-glow: rgba(140, 101, 52, 0.35);
  --dirilis-text-bright: #221810;
  --dirilis-text-muted: #63503c;
  --dirilis-wood-gradient: linear-gradient(180deg, rgba(247, 242, 230, 0.75) 0%, rgba(235, 226, 206, 0.75) 100%);
  --dirilis-gold-button: linear-gradient(180deg, #c7883a 0%, #a46722 100%);
  --dirilis-blue-button: linear-gradient(180deg, #2563eb 0%, #1d4ed8 100%);
  --dirilis-red-button: linear-gradient(180deg, #dc2626 0%, #991b1b 100%);
  --dirilis-green-button: linear-gradient(180deg, #16a34a 0%, #15803d 100%);

  /* Backward-compatibility aliases */
  --targun-bg-dark: var(--dirilis-bg-dark);
  --targun-panel-bg: var(--dirilis-panel-bg);
  --targun-panel-border: var(--dirilis-panel-border);
  --targun-gold-accent: var(--dirilis-gold-accent);
  --targun-gold-glow: var(--dirilis-gold-glow);
  --targun-text-bright: var(--dirilis-text-bright);
  --targun-text-muted: var(--dirilis-text-muted);
  --targun-wood-gradient: var(--dirilis-wood-gradient);
  --targun-gold-button: var(--dirilis-gold-button);
  --targun-blue-button: var(--dirilis-blue-button);
  --targun-red-button: var(--dirilis-red-button);
  --targun-green-button: var(--dirilis-green-button);

  /* Parchment Specific Tokens */
  --parchment-base: rgba(251, 247, 238, 0.75);
  --parchment-surface: rgba(245, 237, 224, 0.75);
  --parchment-well: rgba(238, 229, 211, 0.75);
  --parchment-border: #8c6534;
  --parchment-border-subtle: #bba689;
  --parchment-text-primary: #221810;
  --parchment-text-secondary: #5c4530;
  --parchment-text-muted: #63503c;
  --parchment-gold-text: #7c4d16;
}

/* --------------------------------------------------------------------------
   2. MODALS & DIALOG CONTAINERS (WARM PAPYRUS WITH 25% TRANSPARENCY & BRONZE FRAME)
   -------------------------------------------------------------------------- */
/* Modal Backdrops / Dimming */
html[data-theme="parchment"] .modal-overlay,
html[data-theme="parchment"] .modal-backdrop,
html[data-theme="parchment"] div[class*="modal-overlay"],
html[data-theme="parchment"] div[class*="modal-backdrop"],
html[data-theme="parchment"] div[id$="Modal"] {
  background: rgba(35, 26, 16, 0.25) !important;
  backdrop-filter: blur(3px) !important;
  -webkit-backdrop-filter: blur(3px) !important;
}

/* Modal Window Cards (25% Transparency = 0.75 Alpha) */
html[data-theme="parchment"] .modal-dark-card,
html[data-theme="parchment"] .modal-window,
html[data-theme="parchment"] .modal-content,
html[data-theme="parchment"] .custom-modal,
html[data-theme="parchment"] .hud-panel,
html[data-theme="parchment"] .ranking-modal-card,
html[data-theme="parchment"] .send-movement-modal-card,
html[data-theme="parchment"] .mobile-menu-drawer-card,
html[data-theme="parchment"] div[id*="Modal"] > .modal-dark-card,
html[data-theme="parchment"] div[id*="Modal"] > .modal-window,
html[data-theme="parchment"] div[id*="Modal"] > div[class*="card"],
html[data-theme="parchment"] div[id$="Modal"] .modal-dark-card,
html[data-theme="parchment"] div[id$="Modal"] .modal-window,
html[data-theme="parchment"] div[id$="Modal"] > div:first-child:not(.modal-close-btn),
html[data-theme="parchment"] .modal-overlay > div:first-child,
html[data-theme="parchment"] .modal-backdrop > div:first-child {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  border-radius: 14px !important;
  color: #241a12 !important;
  box-shadow: 0 20px 50px rgba(45, 30, 15, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.75), 0 0 0 1px rgba(140, 101, 52, 0.35) !important;
}

/* Modal Body Transparency */
html[data-theme="parchment"] .modal-window .modal-body,
html[data-theme="parchment"] .modal-body {
  background: transparent !important;
  color: #241a12 !important;
}

/* Modal Headers */
html[data-theme="parchment"] .modal-header,
html[data-theme="parchment"] .modal-dark-card > div:first-child,
html[data-theme="parchment"] .modal-window .modal-header,
html[data-theme="parchment"] .ranking-modal-card > div:first-child,
html[data-theme="parchment"] .modal-overlay .modal-header,
html[data-theme="parchment"] .modal-backdrop .modal-header,
html[data-theme="parchment"] .modal-dark-card .modal-header,
html[data-theme="parchment"] div[id$="Modal"] .modal-header {
  position: relative !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  text-align: center !important;
  padding: 10px 52px !important;
  border-bottom: 1.5px solid rgba(140, 101, 52, 0.35) !important;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6) !important;
  background: transparent !important;
}

html[data-theme="parchment"] .modal-header > div:not(.modal-close-btn):not(.modal-info-btn),
html[data-theme="parchment"] .modal-dark-card > div:first-child > div:not(.modal-close-btn):not(.modal-info-btn),
html[data-theme="parchment"] .modal-window .modal-header > div:not(.modal-close-btn):not(.modal-info-btn),
html[data-theme="parchment"] div[id$="Modal"] .modal-header > div:not(.modal-close-btn):not(.modal-info-btn) {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  margin: 0 auto !important;
}

/* Hide raw loose emoji floating outside plaque on modal headers */
html[data-theme="parchment"] .modal-header > div > span:first-child:not([class]):not(#clanModalHeaderIcon),
html[data-theme="parchment"] .modal-dark-card > div:first-child > div > span:first-child:not([class]):not(#clanModalHeaderIcon) {
  display: none !important;
}

/* Modal Title Parchment Plaque */
html[data-theme="parchment"] .modal-dark-card #modalTitle,
html[data-theme="parchment"] .modal-dark-card > div:first-child h3,
html[data-theme="parchment"] .modal-dark-card > div:first-child h2,
html[data-theme="parchment"] .modal-window .modal-header h3,
html[data-theme="parchment"] .ranking-modal-card > div:first-child h3,
html[data-theme="parchment"] #medreseResearchModal .modal-dark-card > div:first-child h3,
html[data-theme="parchment"] #cephaneArmoryModal .modal-dark-card > div:first-child h3,
html[data-theme="parchment"] #clanModal #clanModalHeaderTitle,
html[data-theme="parchment"] #sendMovementModal #sendMovementModalTitle,
html[data-theme="parchment"] #buildingDetailConstructModal #constructDetailName,
html[data-theme="parchment"] .modal-dark-card .modal-header-plaque,
html[data-theme="parchment"] .modal-window .modal-header-plaque {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 5px 18px !important;
  background: linear-gradient(180deg, rgba(235, 220, 197, 0.85) 0%, rgba(216, 196, 164, 0.85) 100%) !important;
  border: 1.5px solid #8c6534 !important;
  border-radius: 6px !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6), 0 2px 6px rgba(40, 25, 10, 0.15) !important;
  color: #2b1d0c !important;
  text-shadow: none !important;
  font-weight: 800 !important;
  font-size: 14px !important;
  letter-spacing: 0.8px !important;
  text-transform: uppercase !important;
  margin: 0 auto !important;
}

/* Modal Close & Info Buttons */
html[data-theme="parchment"] .modal-close-btn,
html[data-theme="parchment"] button[onclick*="closeModal"],
html[data-theme="parchment"] button.modal-close-btn,
html[data-theme="parchment"] div[id$="Modal"] .modal-close-btn {
  background: linear-gradient(180deg, #ebdcc5 0%, #dbcaae 100%) !important;
  color: #5c4228 !important;
  border: 1.5px solid #8c6534 !important;
  border-radius: 50% !important;
  box-shadow: 0 2px 5px rgba(50, 35, 20, 0.15) !important;
  cursor: pointer !important;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease !important;
}

/* Modal close button hover: color change & glow only, ZERO position jump or shift */
html[data-theme="parchment"] .modal-close-btn:hover,
html[data-theme="parchment"] button.modal-close-btn:hover,
html[data-theme="parchment"] div[id$="Modal"] .modal-close-btn:hover,
html[data-theme="parchment"] button[onclick*="closeModal"]:hover {
  background: #dfd2b8 !important;
  color: #991b1b !important;
  border-color: #991b1b !important;
  box-shadow: 0 0 12px rgba(153, 27, 27, 0.5), 0 2px 6px rgba(50, 35, 20, 0.2) !important;
}

html[data-theme="parchment"] .modal-info-btn,
html[data-theme="parchment"] button.modal-info-btn {
  background: #ede3cf !important;
  color: #5c4228 !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: 0 2px 5px rgba(50, 35, 20, 0.15) !important;
}

html[data-theme="parchment"] .modal-info-btn:hover,
html[data-theme="parchment"] .modal-info-btn.is-active,
html[data-theme="parchment"] .modal-info-btn.is-open {
  background: #dfd2b8 !important;
  color: #8c6534 !important;
  transform: translateY(-50%) !important;
}

/* Modal Info Drawer */
html[data-theme="parchment"] .modal-info-drawer {
  background: linear-gradient(180deg, rgba(247, 242, 230, 0.75) 0%, rgba(235, 225, 204, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  box-shadow: 0 10px 25px rgba(35, 25, 15, 0.25) !important;
}

html[data-theme="parchment"] .modal-info-drawer-close {
  background: #e2d5bd !important;
  color: #5c4228 !important;
  border: 1px solid #8c6534 !important;
}

/* --------------------------------------------------------------------------
   3. SUNKEN INNER WELLS, ROWS & DARK BACKGROUND OVERRIDES
   -------------------------------------------------------------------------- */
/* Sunken inner cards and items inside modals */
html[data-theme="parchment"] .glass-sunken-well,
html[data-theme="parchment"] .cost-res-well,
html[data-theme="parchment"] .send-movement-troops-box,
html[data-theme="parchment"] .well-card,
html[data-theme="parchment"] .inner-panel,
html[data-theme="parchment"] .modal-well,
html[data-theme="parchment"] .modal-dark-card div[style*="background:rgba(255,255,255,0.0"],
html[data-theme="parchment"] .modal-dark-card div[style*="background:rgba(255, 255, 255, 0.0"],
html[data-theme="parchment"] .modal-dark-card div[style*="background: rgba(255, 255, 255, 0.0"],
html[data-theme="parchment"] .modal-dark-card div[style*="background: rgba(255,255,255,0.0"],
html[data-theme="parchment"] .modal-dark-card div[style*="background:rgba(0,0,0"],
html[data-theme="parchment"] .modal-dark-card div[style*="background: rgba(0,0,0"],
html[data-theme="parchment"] .modal-window div[style*="background:rgba(255,255,255,0.0"],
html[data-theme="parchment"] .modal-window div[style*="background:rgba(0,0,0"],
html[data-theme="parchment"] .ranking-modal-card div[style*="background:rgba(0,0,0"],
html[data-theme="parchment"] .modal-overlay [style*="background:#120b06"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#120b06"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#120b06"],
html[data-theme="parchment"] .modal-window [style*="background:#120b06"],
html[data-theme="parchment"] .modal-overlay [style*="background:#120c06"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#120c06"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#120c06"],
html[data-theme="parchment"] .modal-window [style*="background:#120c06"],
html[data-theme="parchment"] .modal-overlay [style*="background:#181008"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#181008"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#181008"],
html[data-theme="parchment"] .modal-window [style*="background:#181008"],
html[data-theme="parchment"] .modal-overlay [style*="background:#181009"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#181009"],
html[data-theme="parchment"] .modal-overlay [style*="background:#140d08"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#140d08"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#140d08"],
html[data-theme="parchment"] .modal-overlay [style*="background:#1a130e"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#1a130e"],
html[data-theme="parchment"] .modal-overlay [style*="background:#1e140d"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#1e140d"],
html[data-theme="parchment"] .modal-overlay [style*="background:#0b111e"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#0b111e"],
html[data-theme="parchment"] .modal-overlay [style*="background:#0a0604"],
html[data-theme="parchment"] .modal-dark-card [style*="background:#0a0604"],
html[data-theme="parchment"] .modal-overlay [style*="background:#0b0f19"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#0b0f19"],
html[data-theme="parchment"] .modal-window [style*="background:#0b0f19"],
html[data-theme="parchment"] .modal-overlay [style*="background:#1e1b4b"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#1e1b4b"],
html[data-theme="parchment"] .modal-window [style*="background:#1e1b4b"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#0f172a"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#111827"],
html[data-theme="parchment"] .modal-backdrop [style*="background:#1e293b"],
html[data-theme="parchment"] .modal-overlay [style*="background:#1e293b"],
html[data-theme="parchment"] .modal-overlay [style*="background:linear-gradient(180deg, #18110b"],
html[data-theme="parchment"] .modal-dark-card [style*="background:linear-gradient(180deg, #18110b"],
html[data-theme="parchment"] .modal-overlay [style*="background:linear-gradient(180deg, #1a120b"],
html[data-theme="parchment"] .modal-dark-card [style*="background:linear-gradient(180deg, #1a120b"],
html[data-theme="parchment"] .modal-overlay [style*="background:rgba(20, 13, 8"],
html[data-theme="parchment"] .modal-overlay [style*="background:rgba(20,13,8"],
html[data-theme="parchment"] .modal-backdrop [style*="background:rgba(20, 13, 8"],
html[data-theme="parchment"] .modal-backdrop [style*="background:rgba(20,13,8"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(20, 13, 8"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(20,13,8"],
html[data-theme="parchment"] .modal-window [style*="background:rgba(20, 13, 8"],
html[data-theme="parchment"] .modal-overlay [style*="background:rgba(20, 14, 9"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(20, 14, 9"],
html[data-theme="parchment"] .modal-overlay [style*="background:rgba(18, 14, 10"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(18, 14, 10"],
html[data-theme="parchment"] .modal-overlay [style*="background:rgba(18, 12, 8"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(18, 12, 8"],
html[data-theme="parchment"] .modal-overlay [style*="background:rgba(15, 10, 6"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(15, 10, 6"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(15,20,30"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(20,28,42"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(12,18,28"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(15,23,42"],
html[data-theme="parchment"] .modal-dark-card [style*="background:rgba(30,41,59"] {
  background: linear-gradient(180deg, rgba(238, 229, 211, 0.75) 0%, rgba(227, 217, 196, 0.75) 100%) !important;
  border: 1px solid #b8a387 !important;
  color: #241a12 !important;
  box-shadow: inset 0 1px 3px rgba(45, 30, 15, 0.08) !important;
}

/* Settings Modal Specific Item Rows */
html[data-theme="parchment"] #settingsModal .modal-dark-card > div[style*="display:flex; flex-direction:column; gap:12px;"] > div {
  background: linear-gradient(180deg, rgba(242, 232, 215, 0.75) 0%, rgba(232, 221, 199, 0.75) 100%) !important;
  border: 1px solid #bba689 !important;
  border-radius: 12px !important;
  box-shadow: 0 1px 4px rgba(40, 25, 10, 0.08) !important;
}

/* Settings Modal Theme & Troop Step Buttons */
html[data-theme="parchment"] #settingsThemeButtonGroup button,
html[data-theme="parchment"] #settingsTroopStepButtonGroup button,
html[data-theme="parchment"] .settings-troop-step-btn {
  background: #e5d7c3 !important;
  border: 1px solid #aa9277 !important;
  color: #443220 !important;
  font-weight: 700 !important;
  box-shadow: none !important;
}

html[data-theme="parchment"] #settingsThemeButtonGroup button.active,
html[data-theme="parchment"] #settingsTroopStepButtonGroup button.active,
html[data-theme="parchment"] .settings-troop-step-btn.active {
  background: linear-gradient(180deg, #c7883a 0%, #a46722 100%) !important;
  border: 1.5px solid #784812 !important;
  color: #ffffff !important;
  font-weight: 900 !important;
  box-shadow: 0 0 10px rgba(140, 101, 52, 0.45) !important;
}

/* Settings Ambassador Notice Banner */
html[data-theme="parchment"] #settingsAmbassadorActiveBanner {
  background: linear-gradient(135deg, rgba(224, 231, 255, 0.75) 0%, rgba(199, 210, 254, 0.75) 100%) !important;
  border: 1.5px solid #6366f1 !important;
}

html[data-theme="parchment"] #settingsAmbassadorNoticeText {
  color: #3730a3 !important;
}

html[data-theme="parchment"] #settingsAmbassadorNoticeSub {
  color: #4f46e5 !important;
}

/* --------------------------------------------------------------------------
   4. TYPOGRAPHY & TEXT OVERRIDES (DARK CRISP INK ON LIGHT PARCHMENT)
   -------------------------------------------------------------------------- */
/* Modal Titles & Headings */
html[data-theme="parchment"] .modal-overlay h1,
html[data-theme="parchment"] .modal-overlay h2,
html[data-theme="parchment"] .modal-overlay h3,
html[data-theme="parchment"] .modal-backdrop h1,
html[data-theme="parchment"] .modal-backdrop h2,
html[data-theme="parchment"] .modal-backdrop h3,
html[data-theme="parchment"] .modal-dark-card h1,
html[data-theme="parchment"] .modal-dark-card h2,
html[data-theme="parchment"] .modal-dark-card h3,
html[data-theme="parchment"] .modal-window h1,
html[data-theme="parchment"] .modal-window h2,
html[data-theme="parchment"] .modal-window h3,
html[data-theme="parchment"] .ranking-modal-card h1,
html[data-theme="parchment"] .ranking-modal-card h2,
html[data-theme="parchment"] .ranking-modal-card h3,
html[data-theme="parchment"] .modal-dark-card > div:first-child h2,
html[data-theme="parchment"] .modal-dark-card > div:first-child h3,
html[data-theme="parchment"] .ranking-modal-card > div:first-child h3,
html[data-theme="parchment"] .modal-header h3,
html[data-theme="parchment"] #sendMovementModalTitle,
html[data-theme="parchment"] #clanModalHeaderTitle,
html[data-theme="parchment"] #clanProfileClanName,
html[data-theme="parchment"] #profileUsername {
  color: #241a12 !important;
  text-shadow: none !important;
  font-weight: 800 !important;
}

/* Subheadings & Subtitles */
html[data-theme="parchment"] .modal-overlay h4,
html[data-theme="parchment"] .modal-backdrop h4,
html[data-theme="parchment"] .modal-dark-card h4,
html[data-theme="parchment"] .modal-window h4,
html[data-theme="parchment"] .ranking-modal-card h4,
html[data-theme="parchment"] .modal-overlay h5,
html[data-theme="parchment"] .modal-backdrop h5,
html[data-theme="parchment"] .modal-dark-card h5,
html[data-theme="parchment"] .modal-window h5,
html[data-theme="parchment"] .modal-header-subtitle,
html[data-theme="parchment"] #empireProdSubtitle,
html[data-theme="parchment"] #clanModalHeaderSubtitle,
html[data-theme="parchment"] #rankingsSubtitle,
html[data-theme="parchment"] #newsSubtitle,
html[data-theme="parchment"] #reportsSubtitle,
html[data-theme="parchment"] #farmListSubHeader,
html[data-theme="parchment"] #farmSettingsTitle {
  color: #5c4530 !important;
}

/* Hardcoded Light/White Text Overrides to Dark Espresso Ink */
html[data-theme="parchment"] .modal-dark-card [style*="color:#fff"],
html[data-theme="parchment"] .modal-dark-card [style*="color: #fff"],
html[data-theme="parchment"] .modal-dark-card [style*="color:#ffffff"],
html[data-theme="parchment"] .modal-dark-card [style*="color: #ffffff"],
html[data-theme="parchment"] .modal-dark-card [style*="color:#f8fafc"],
html[data-theme="parchment"] .modal-dark-card [style*="color:#f1f5f9"],
html[data-theme="parchment"] .modal-dark-card [style*="color:#e2e8f0"],
html[data-theme="parchment"] .modal-window [style*="color:#fff"],
html[data-theme="parchment"] .modal-window [style*="color:#ffffff"],
html[data-theme="parchment"] .modal-window [style*="color:#f8fafc"],
html[data-theme="parchment"] .modal-window [style*="color:#e2e8f0"],
html[data-theme="parchment"] .ranking-modal-card [style*="color:#fff"],
html[data-theme="parchment"] .ranking-modal-card [style*="color:#e2e8f0"],
html[data-theme="parchment"] .modal-overlay [style*="color:#fff"],
html[data-theme="parchment"] .modal-overlay [style*="color:#e2e8f0"],
html[data-theme="parchment"] div[id$="Modal"] [style*="color:#fff"]:not(.btn-primary):not(.btn-danger):not(.btn-success),
html[data-theme="parchment"] div[id$="Modal"] [style*="color:#ffffff"]:not(.btn-primary):not(.btn-danger):not(.btn-success) {
  color: #241a12 !important;
}

/* Hardcoded Gray/Muted Text Overrides to Warm Sepia Bronze */
html[data-theme="parchment"] .modal-dark-card [style*="color:#cbd5e1"],
html[data-theme="parchment"] .modal-dark-card [style*="color:#94a3b8"],
html[data-theme="parchment"] .modal-dark-card [style*="color:var(--dirilis-text-muted)"],
html[data-theme="parchment"] .modal-window [style*="color:#cbd5e1"],
html[data-theme="parchment"] .modal-window [style*="color:#94a3b8"],
html[data-theme="parchment"] .modal-window [style*="color:var(--dirilis-text-muted)"],
html[data-theme="parchment"] div[id$="Modal"] [style*="color:#cbd5e1"],
html[data-theme="parchment"] div[id$="Modal"] [style*="color:#94a3b8"],
html[data-theme="parchment"] div[id$="Modal"] [style*="color:var(--dirilis-text-muted)"] {
  color: #63503c !important;
}

/* Gold Text Accent Overrides to Rich Burnt Amber */
html[data-theme="parchment"] .modal-dark-card [style*="color:var(--dirilis-gold-accent)"],
html[data-theme="parchment"] .modal-window [style*="color:var(--dirilis-gold-accent)"],
html[data-theme="parchment"] div[id$="Modal"] [style*="color:var(--dirilis-gold-accent)"] {
  color: #7c4d16 !important;
}

/* General Body text in modals */
html[data-theme="parchment"] .modal-dark-card p,
html[data-theme="parchment"] .modal-dark-card label,
html[data-theme="parchment"] .modal-window p,
html[data-theme="parchment"] .modal-window label {
  color: #2e2216 !important;
}

/* --------------------------------------------------------------------------
   5. BUTTONS (WARM AMBER LEATHER PRIMARY, LINEN CREAM SECONDARY)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .btn {
  font-family: inherit !important;
  font-weight: 700 !important;
  border-radius: 6px !important;
  transition: all 0.2s ease !important;
}

html[data-theme="parchment"] .btn-primary,
html[data-theme="parchment"] button.btn-primary,
html[data-theme="parchment"] .modal-dark-card button.btn-primary,
html[data-theme="parchment"] #modalUpgradeConfirmBtn:not(:disabled) {
  background: linear-gradient(180deg, #c7883a 0%, #ab6d25 50%, #8e5414 100%) !important;
  border: 1.5px solid #6b4010 !important;
  color: #ffffff !important;
  box-shadow: 0 2px 6px rgba(70, 40, 10, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.3) !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.4) !important;
}

html[data-theme="parchment"] .btn-primary:hover,
html[data-theme="parchment"] button.btn-primary:hover,
html[data-theme="parchment"] #modalUpgradeConfirmBtn:not(:disabled):hover {
  background: linear-gradient(180deg, #d99948 0%, #b87a2e 50%, #9e5f18 100%) !important;
  box-shadow: 0 4px 12px rgba(70, 40, 10, 0.35) !important;
  transform: translateY(-1px) !important;
}

html[data-theme="parchment"] .btn-secondary,
html[data-theme="parchment"] button.btn-secondary,
html[data-theme="parchment"] .modal-dark-card button.btn-secondary,
html[data-theme="parchment"] button[onclick*="closeModal('sendMovementModal')"],
html[data-theme="parchment"] #modalUpgradeCancelBtn {
  background: linear-gradient(180deg, #f5eee0 0%, #e6dccb 100%) !important;
  border: 1.5px solid #a38c72 !important;
  color: #382a1d !important;
  box-shadow: 0 1px 4px rgba(40, 30, 20, 0.1) !important;
}

html[data-theme="parchment"] .btn-secondary:hover,
html[data-theme="parchment"] button.btn-secondary:hover,
html[data-theme="parchment"] button[onclick*="closeModal('sendMovementModal')"]:hover,
html[data-theme="parchment"] #modalUpgradeCancelBtn:hover {
  background: #eee3d0 !important;
  border-color: #8c6534 !important;
  color: #1a120b !important;
}

html[data-theme="parchment"] .btn-danger,
html[data-theme="parchment"] button.btn-danger {
  background: linear-gradient(180deg, #dc2626 0%, #b91c1c 100%) !important;
  border: 1.5px solid #7f1d1d !important;
  color: #ffffff !important;
}

html[data-theme="parchment"] .btn-success,
html[data-theme="parchment"] button.btn-success {
  background: linear-gradient(180deg, #16a34a 0%, #15803d 100%) !important;
  border: 1.5px solid #14532d !important;
  color: #ffffff !important;
}

/* Speed Boost Button */
html[data-theme="parchment"] #btnMovementSpeedBoost {
  background: linear-gradient(180deg, #eef9fb 0%, #d8eff5 100%) !important;
  border: 1.5px solid #0891b2 !important;
  color: #0e7490 !important;
}

html[data-theme="parchment"] #btnMovementSpeedBoost span:last-child {
  color: #92400e !important;
  font-weight: 800 !important;
}

/* Min / Max Buttons & Quick Send Buttons */
html[data-theme="parchment"] .send-movement-troops-grid button,
html[data-theme="parchment"] #movementTroopCardsContainer button {
  background: #ebdcc5 !important;
  border: 1px solid #9c7b56 !important;
  color: #3d2b1a !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] .send-movement-troops-grid button:hover,
html[data-theme="parchment"] #movementTroopCardsContainer button:hover {
  background: #ded0b6 !important;
  color: #1a120a !important;
  border-color: #7a5833 !important;
}

/* --------------------------------------------------------------------------
   6. FORM CONTROLS & DROPDOWNS (IVORY BACKGROUND, BRONZE BORDER, DARK INK)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .input-field,
html[data-theme="parchment"] input[type="text"],
html[data-theme="parchment"] input[type="number"],
html[data-theme="parchment"] input[type="password"],
html[data-theme="parchment"] select,
html[data-theme="parchment"] textarea,
html[data-theme="parchment"] .send-movement-villages-select {
  background: rgba(253, 252, 249, 0.85) !important;
  border: 1.5px solid #9c7b56 !important;
  color: #1e1610 !important;
  border-radius: 7px !important;
}

html[data-theme="parchment"] .input-field:focus,
html[data-theme="parchment"] input:focus,
html[data-theme="parchment"] select:focus,
html[data-theme="parchment"] textarea:focus {
  border-color: #8c6534 !important;
  box-shadow: 0 0 0 2px rgba(140, 101, 52, 0.25) !important;
  outline: none !important;
}

html[data-theme="parchment"] select option {
  background: #faf6ee !important;
  color: #241a12 !important;
}

/* --------------------------------------------------------------------------
   7. LEFT NAVIGATION SIDEBAR (AUTHENTIC AGED LEATHER / PARCHMENT DOCK)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .left-sidebar {
  background: linear-gradient(180deg, rgba(251, 247, 238, 0.75) 0%, rgba(239, 229, 210, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-right: 1.5px solid #8c6534 !important;
  box-shadow: 4px 0 20px rgba(40, 25, 10, 0.15) !important;
}

html[data-theme="parchment"] .left-sidebar.collapsed {
  border-right: none !important;
  box-shadow: none !important;
}

html[data-theme="parchment"] .left-sidebar .menu-item-btn {
  background: transparent !important;
  border: none !important;
  border-radius: 10px !important;
  color: #2e1d0d !important;
  box-shadow: none !important;
}

html[data-theme="parchment"] .left-sidebar .menu-item-btn:hover {
  background: transparent !important;
  border: none !important;
  color: #1a1005 !important;
  box-shadow: none !important;
  transform: translateY(-2px) !important;
}

html[data-theme="parchment"] .left-sidebar .menu-item-btn span {
  color: #2e1d0d !important;
  font-weight: 700 !important;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.65) !important;
}

html[data-theme="parchment"] .left-sidebar .quick-village-btn {
  background: linear-gradient(180deg, #c7883a 0%, #a46722 100%) !important;
  border: 1.5px solid #784812 !important;
  color: #ffffff !important;
  box-shadow: 0 2px 6px rgba(70, 40, 10, 0.25) !important;
}

html[data-theme="parchment"] .left-sidebar .quick-village-btn #quickToggleLabel,
html[data-theme="parchment"] .left-sidebar .quick-village-btn #quickToggleIcon {
  color: #ffffff !important;
}

html[data-theme="parchment"] .left-sidebar-toggle-btn {
  background: linear-gradient(90deg, rgba(237, 226, 205, 0.75) 0%, rgba(223, 210, 185, 0.75) 100%) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: 1.5px solid #8c6534 !important;
  border-left: none !important;
  color: #6b4010 !important;
}

html[data-theme="parchment"] .left-sidebar-toggle-btn:hover {
  background: linear-gradient(90deg, rgba(223, 210, 185, 0.9) 0%, rgba(208, 190, 158, 0.9) 100%) !important;
  color: #241a12 !important;
}

/* --------------------------------------------------------------------------
   8. TOP HORIZONTAL RESOURCE BAR (WARM IVORY SURFACE & CRISP STATS)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .top-mobile-resource-bar {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(243, 236, 224, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-bottom: 1.5px solid #8c6534 !important;
  box-shadow: 0 3px 12px rgba(40, 25, 10, 0.12) !important;
}

html[data-theme="parchment"] .inline-res-item {
  background: linear-gradient(180deg, rgba(247, 241, 228, 0.75) 0%, rgba(235, 225, 207, 0.75) 100%) !important;
  border: 1px solid #bfaea1 !important;
  border-radius: 8px !important;
  color: #241a12 !important;
  box-shadow: 0 1px 3px rgba(40, 25, 10, 0.08) !important;
}

html[data-theme="parchment"] .inline-res-item span:not(.res-buff-indicator) {
  color: #241a12 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] .inline-res-item.res-gold span:not(.res-buff-indicator),
html[data-theme="parchment"] #topResGoldVal {
  color: #92580a !important;
}

html[data-theme="parchment"] .inline-res-item.res-diamond {
  background: linear-gradient(180deg, rgba(238, 249, 253, 0.75) 0%, rgba(220, 241, 249, 0.75) 100%) !important;
  border: 1px solid #38bdf8 !important;
  color: #0369a1 !important;
}

html[data-theme="parchment"] .inline-res-item.res-diamond span {
  color: #0369a1 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .res-diamond-plus {
  background: #0284c7 !important;
  color: #ffffff !important;
}

html[data-theme="parchment"] .village-name-badge,
html[data-theme="parchment"] .top-village-badge {
  background: linear-gradient(180deg, rgba(245, 235, 217, 0.75) 0%, rgba(235, 224, 202, 0.75) 100%) !important;
  border: 1px solid #8c6534 !important;
  color: #241a12 !important;
}

/* --------------------------------------------------------------------------
   9. BOTTOM TROOP DOCK & TROOP CARDS (CARTRIDGE LEATHER DOCK)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .bottom-troop-bar-toggle-btn {
  background: linear-gradient(180deg, rgba(237, 226, 205, 0.75) 0%, rgba(223, 210, 185, 0.75) 100%) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: 1.5px solid #8c6534 !important;
  border-bottom: none !important;
  color: #6b4010 !important;
  box-shadow: 0 -2px 8px rgba(40, 25, 10, 0.15) !important;
}

html[data-theme="parchment"] .bottom-troop-bar-toggle-btn:hover {
  background: rgba(250, 243, 232, 0.9) !important;
  border-color: #6b4010 !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .bottom-troop-bar {
  background: linear-gradient(0deg, rgba(251, 247, 238, 0.75) 0%, rgba(239, 229, 210, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: 0 -4px 16px rgba(40, 25, 10, 0.12) !important;
}

html[data-theme="parchment"] .bottom-troop-bar.collapsed {
  border: none !important;
  box-shadow: none !important;
}

html[data-theme="parchment"] .troop-card-item {
  background: linear-gradient(180deg, rgba(247, 241, 228, 0.75) 0%, rgba(235, 225, 207, 0.75) 100%) !important;
  border: 1.5px solid #b8a387 !important;
  border-radius: 8px !important;
  box-shadow: 0 2px 6px rgba(40, 25, 10, 0.1) !important;
}

html[data-theme="parchment"] .troop-card-item:hover {
  background: rgba(253, 250, 244, 0.9) !important;
  border-color: #8c6534 !important;
  box-shadow: 0 4px 12px rgba(140, 101, 52, 0.3) !important;
}

html[data-theme="parchment"] .troop-card-item .troop-card-name {
  color: #2c1d0f !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .troop-card-item .troop-card-count {
  color: #6b4010 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .troop-card-item.locked {
  background: rgba(234, 226, 210, 0.75) !important;
  border-color: #c9bea9 !important;
  opacity: 0.6 !important;
}

/* --------------------------------------------------------------------------
   10. RIGHT SIDEBAR & RESOURCES PANEL
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .right-sidebar {
  background: linear-gradient(180deg, rgba(251, 247, 238, 0.75) 0%, rgba(239, 229, 210, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-left: 1.5px solid #8c6534 !important;
  box-shadow: -4px 0 20px rgba(40, 25, 10, 0.15) !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .right-sidebar.collapsed {
  border-left: none !important;
  box-shadow: none !important;
}

html[data-theme="parchment"] .right-sidebar .logo-header .dirilis-logo-text,
html[data-theme="parchment"] .right-sidebar .logo-header .targun-logo-text {
  color: #5c3810 !important;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.8) !important;
}

html[data-theme="parchment"] .right-sidebar .player-subtitle {
  color: #5c4530 !important;
}

html[data-theme="parchment"] .right-sidebar .player-subtitle span {
  color: #2b1d0d !important;
}

html[data-theme="parchment"] .right-sidebar .avatar-xp-badge {
  background: linear-gradient(180deg, rgba(245, 236, 216, 0.75) 0%, rgba(234, 221, 197, 0.75) 100%) !important;
  border: 1px solid #bfaea1 !important;
  box-shadow: 0 2px 6px rgba(40, 25, 10, 0.08) !important;
}

html[data-theme="parchment"] .right-sidebar .avatar-xp-badge .xp-title,
html[data-theme="parchment"] .right-sidebar .avatar-xp-badge #sidebarVillageTpName,
html[data-theme="parchment"] .right-sidebar .avatar-xp-badge #sidebarVillageTpLabel {
  color: #63503c !important;
}

html[data-theme="parchment"] .right-sidebar .avatar-xp-badge .xp-val,
html[data-theme="parchment"] .right-sidebar #xpValDisplay,
html[data-theme="parchment"] #xpValDisplay {
  color: #221810 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .right-sidebar .player-subtitle #sidebarTribeName,
html[data-theme="parchment"] #sidebarTribeName {
  color: #241a12 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] .right-sidebar .avatar-xp-badge #sidebarVillageTpRatio {
  color: #8c5310 !important;
}

html[data-theme="parchment"] .right-sidebar .panel-section-title {
  color: #6e4414 !important;
  border-bottom: 1.5px solid rgba(140, 101, 52, 0.3) !important;
}

html[data-theme="parchment"] .right-sidebar .shield-table-pill {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #8c6534 !important;
  color: #3b2713 !important;
}

html[data-theme="parchment"] .right-sidebar .resource-row {
  background: rgba(247, 241, 228, 0.75) !important;
  border: 1px solid #c9bea9 !important;
}

html[data-theme="parchment"] .right-sidebar .resource-label span:not(.res-buff-indicator) {
  color: #362617 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] .right-sidebar .resource-val {
  color: #1e140a !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .right-sidebar .resource-val#resGoldVal {
  color: #92580a !important;
}

html[data-theme="parchment"] .right-sidebar .cities-grid .city-btn,
html[data-theme="parchment"] .right-sidebar .cities-grid .city-card,
html[data-theme="parchment"] .right-sidebar .cities-grid > div,
html[data-theme="parchment"] .right-sidebar .city-btn {
  background: linear-gradient(180deg, rgba(247, 241, 228, 0.75) 0%, rgba(236, 224, 204, 0.75) 100%) !important;
  border: 1.5px solid #bda88e !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .right-sidebar .cities-grid .city-btn:hover,
html[data-theme="parchment"] .right-sidebar .city-btn:hover {
  background: linear-gradient(180deg, rgba(250, 243, 232, 0.9) 0%, rgba(232, 221, 199, 0.9) 100%) !important;
  border-color: #8c6534 !important;
}

html[data-theme="parchment"] .right-sidebar .cities-grid .city-btn.active,
html[data-theme="parchment"] .right-sidebar .cities-grid .city-card.active,
html[data-theme="parchment"] .right-sidebar .cities-grid > div.active,
html[data-theme="parchment"] .right-sidebar .city-btn.active {
  background: linear-gradient(180deg, rgba(254, 250, 240, 0.85) 0%, rgba(250, 237, 215, 0.85) 100%) !important;
  border-color: #8c6534 !important;
  box-shadow: 0 0 8px rgba(140, 101, 52, 0.3) !important;
}

html[data-theme="parchment"] .right-sidebar .city-btn .city-name,
html[data-theme="parchment"] .right-sidebar .city-btn div,
html[data-theme="parchment"] .right-sidebar .city-btn span:not(.event-badge),
html[data-theme="parchment"] .right-sidebar .cities-grid div[style*="color:#f1f5f9"],
html[data-theme="parchment"] .right-sidebar .cities-grid div[style*="color:#fff"],
html[data-theme="parchment"] .right-sidebar .cities-grid div[style*="color:#ffffff"],
html[data-theme="parchment"] .city-btn .city-name,
html[data-theme="parchment"] .city-btn div {
  color: #241a12 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] .right-sidebar .city-btn.active .city-name,
html[data-theme="parchment"] .right-sidebar .city-btn.active div,
html[data-theme="parchment"] .right-sidebar .cities-grid .city-btn.active div[style*="color"],
html[data-theme="parchment"] .city-btn.active .city-name {
  color: #7c4d16 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .right-sidebar .event-circle-btn {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  color: #362617 !important;
}

html[data-theme="parchment"] .right-sidebar .event-circle-btn span {
  color: #362617 !important;
  text-shadow: 0 1px 2px rgba(255, 255, 255, 0.65) !important;
}

html[data-theme="parchment"] .right-sidebar-toggle-btn {
  background: linear-gradient(270deg, rgba(237, 226, 205, 0.75) 0%, rgba(223, 210, 185, 0.75) 100%) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: 1.5px solid #8c6534 !important;
  border-right: none !important;
  color: #6b4010 !important;
}

/* --------------------------------------------------------------------------
   11. CHAT SLIDE WINDOW & TABS
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] #chatSlideWindow,
html[data-theme="parchment"] .chat-window {
  background: linear-gradient(180deg, rgba(251, 247, 238, 0.75) 0%, rgba(239, 229, 210, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-left: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .right-chat-tabs button {
  background: rgba(235, 220, 197, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #4a3420 !important;
}

html[data-theme="parchment"] .right-chat-tabs button.active {
  background: rgba(253, 250, 244, 0.9) !important;
  border-color: #8c6534 !important;
  color: #1a1005 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] #chatInput {
  background: rgba(255, 255, 255, 0.85) !important;
  border: 1.5px solid #9c7b56 !important;
  color: #241a12 !important;
}

/* --------------------------------------------------------------------------
   12. TABLES, GRIDS & REPORTS (BATTLE REPORTS, RANKINGS, PRODUCTION)
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] table {
  color: #241a12 !important;
}

html[data-theme="parchment"] table thead th {
  background: rgba(234, 222, 203, 0.75) !important;
  color: #4a3420 !important;
  border-bottom: 1.5px solid #8c6534 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] table tbody tr {
  border-bottom: 1px solid rgba(140, 101, 52, 0.15) !important;
}

html[data-theme="parchment"] table tbody tr:nth-child(even) {
  background: rgba(235, 225, 206, 0.45) !important;
}

html[data-theme="parchment"] table tbody tr:hover {
  background: rgba(199, 136, 58, 0.15) !important;
}

html[data-theme="parchment"] table tbody td {
  color: #2e2419 !important;
}

/* Pinned Battle Report Detail Navigation Footer */
html[data-theme="parchment"] .report-detail-pinned-footer {
  background: linear-gradient(180deg, rgba(235, 226, 207, 0.75) 0%, rgba(222, 210, 188, 0.75) 100%) !important;
  border-top: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .report-detail-pinned-footer span {
  color: #3b2816 !important;
}

html[data-theme="parchment"] .report-detail-pinned-footer span[style*="background"] {
  background: rgba(223, 210, 184, 0.75) !important;
  color: #1e140a !important;
  border-color: #8c6534 !important;
}

/* Sub-tabs and Navigation Pills */
html[data-theme="parchment"] .tab-btn,
html[data-theme="parchment"] .chat-chamfer-tab-btn,
html[data-theme="parchment"] .quests-tab-btn,
html[data-theme="parchment"] .ranking-tab-btn,
html[data-theme="parchment"] .clan-tab-btn {
  background: rgba(235, 220, 197, 0.75) !important;
  border: 1px solid #b8a387 !important;
  color: #4a3420 !important;
}

html[data-theme="parchment"] .tab-btn.active,
html[data-theme="parchment"] .chat-chamfer-tab-btn.active,
html[data-theme="parchment"] .quests-tab-btn.active,
html[data-theme="parchment"] .ranking-tab-btn.active,
html[data-theme="parchment"] .clan-tab-btn.active {
  background: rgba(252, 250, 244, 0.9) !important;
  border-color: #8c6534 !important;
  color: #1a1005 !important;
  font-weight: 800 !important;
  box-shadow: 0 2px 6px rgba(40, 25, 10, 0.1) !important;
}

/* --------------------------------------------------------------------------
   13. TOOLTIPS, TOASTS & FLOATING DIALOGS
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] #troopHoverTooltip,
html[data-theme="parchment"] #quickTroopCard,
html[data-theme="parchment"] .troop-mini-modal,
html[data-theme="parchment"] #mapHoverTooltip,
html[data-theme="parchment"] #buildingTooltip {
  background: rgba(253, 250, 244, 0.75) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  box-shadow: 0 12px 32px rgba(40, 25, 10, 0.28) !important;
  border-radius: 10px !important;
}

html[data-theme="parchment"] .troop-hover-card-inner {
  background: transparent !important;
}

html[data-theme="parchment"] .troop-hover-stat-pill {
  background: rgba(240, 229, 209, 0.75) !important;
  border: 1px solid #bfaea1 !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .troop-hover-stat-pill strong {
  color: #241a12 !important;
}

html[data-theme="parchment"] .troop-hover-cost-well {
  background: rgba(237, 226, 203, 0.75) !important;
  border: 1px solid #bfaea1 !important;
  color: #241a12 !important;
}

/* Toasts */
html[data-theme="parchment"] .game-toast-box,
html[data-theme="parchment"] #gameToastNotification {
  background: rgba(253, 250, 244, 0.75) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #221810 !important;
  box-shadow: 0 8px 25px rgba(40, 25, 10, 0.2) !important;
  border-radius: 10px !important;
}

/* Confirmation Modal Card */
html[data-theme="parchment"] .confirm-modal-card {
  background: linear-gradient(180deg, rgba(250, 247, 240, 0.75) 0%, rgba(243, 235, 224, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #221810 !important;
}

html[data-theme="parchment"] .confirm-modal-card h3 {
  color: #241a12 !important;
}

html[data-theme="parchment"] .confirm-modal-card p {
  color: #4a3622 !important;
}

/* Upgrade Level Badges */
html[data-theme="parchment"] .upgrade-level-badge {
  background: rgba(240, 229, 209, 0.75) !important;
  border: 1px solid #8c6534 !important;
  color: #241a12 !important;
}

/* --------------------------------------------------------------------------
   14. VILLAGE VIEWPORT & CANVAS BACKGROUND (WARM IVORY PARCHMENT AMBIENCE)
   Eliminates black gap/frame surrounding central palisade wall board
   -------------------------------------------------------------------------- */
html[data-theme="parchment"] .center-game-area {
  background: #ede3d0 !important;
}

html[data-theme="parchment"] .village-view-container {
  background: radial-gradient(circle at 50% 50%, #fbf8f2 0%, #ede3d0 100%) !important;
}

html[data-theme="parchment"] .village-scroll-viewport {
  background: transparent !important;
}

html[data-theme="parchment"] .palisade-wall-wrapper {
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

/* In-Village Action Circle Buttons (Araştır, Geliştir, Üretim, Pazar, Destek, Gelen, Giden) */
html[data-theme="parchment"] .action-circle-btn {
  background: linear-gradient(180deg, rgba(251, 247, 238, 0.78) 0%, rgba(239, 229, 210, 0.72) 100%) !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1.5px solid rgba(140, 101, 52, 0.75) !important;
  color: #241a12 !important;
  box-shadow: 0 4px 12px rgba(45, 30, 15, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.65) !important;
}

html[data-theme="parchment"] .action-circle-btn span {
  color: #241a12 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .action-circle-btn:hover {
  background: linear-gradient(180deg, rgba(253, 250, 244, 0.90) 0%, rgba(237, 225, 203, 0.85) 100%) !important;
  border-color: #6b4010 !important;
  transform: translateY(-2px) !important;
}

html[data-theme="parchment"] .action-circle-btn.action-btn-danger:not(.movement-active),
html[data-theme="parchment"] .action-circle-btn.action-btn-warning:not(.movement-active),
html[data-theme="parchment"] .action-circle-btn.action-btn-info:not(.movement-active) {
  border-color: rgba(148, 163, 184, 0.65) !important;
  opacity: 0.62;
}

html[data-theme="parchment"] .action-circle-btn.action-btn-danger:not(.movement-active) span,
html[data-theme="parchment"] .action-circle-btn.action-btn-warning:not(.movement-active) span,
html[data-theme="parchment"] .action-circle-btn.action-btn-info:not(.movement-active) span {
  color: #64748b !important;
}

html[data-theme="parchment"] .action-circle-btn.action-btn-danger.movement-active {
  border-color: rgba(220, 38, 38, 0.85) !important;
  opacity: 1;
}

html[data-theme="parchment"] .action-circle-btn.action-btn-warning.movement-active {
  border-color: rgba(217, 119, 6, 0.85) !important;
  opacity: 1;
}

html[data-theme="parchment"] .action-circle-btn.action-btn-info.movement-active {
  border-color: rgba(2, 132, 199, 0.85) !important;
  opacity: 1;
}

/* Village Picker Modal Text & Rows */
html[data-theme="parchment"] .village-picker-name,
html[data-theme="parchment"] #villagePickerListContainer .village-picker-name,
html[data-theme="parchment"] #villagePickerListContainer div[style*="font-weight:700"] {
  color: #241a12 !important;
}

/* ==============================================================================
   15. PART 1 & PART 2 COMPREHENSIVE CONTRAST & MODULE PARCHMENT OVERRIDES
   Ensures 100% readability across Quests, Farm Raid, Empire Overview,
   Combat Simulator & Lock Calc, Rankings, Game Wiki, Diamond Shop, Shields,
   Medrese and Armory.
   ============================================================================== */

/* --- 15.1 UNIVERSAL DURATION & TECH BADGES (Medrese & Cephane) --- */
html[data-theme="parchment"] .duration-time-badge,
html[data-theme="parchment"] #medreseResearchModal span[style*="rgba(234,179,8,0.15)"],
html[data-theme="parchment"] #cephaneArmoryModal span[style*="rgba(234,179,8,0.15)"],
html[data-theme="parchment"] #medreseResearchModal span[style*="⏱️"],
html[data-theme="parchment"] #cephaneArmoryModal span[style*="⏱️"] {
  background: rgba(240, 229, 209, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
  color: #7c4d16 !important;
  font-weight: 800 !important;
  box-shadow: 0 1px 3px rgba(45, 30, 15, 0.12) !important;
}

/* --- 15.2 MEDRESE CATEGORY TABS & CARDS --- */
html[data-theme="parchment"] .medrese-cat-btn {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  font-weight: 700 !important;
}
html[data-theme="parchment"] .medrese-cat-btn:hover:not(.active) {
  background: rgba(253, 250, 244, 0.9) !important;
  color: #7c4d16 !important;
}
html[data-theme="parchment"] .medrese-cat-btn.active {
  background: linear-gradient(135deg, #8c6534, #6b4010) !important;
  border-color: #52310a !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  box-shadow: 0 2px 8px rgba(140, 101, 52, 0.3) !important;
}
html[data-theme="parchment"] #medreseResearchModal .modal-dark-card {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #medreseResearchModal #medreseSearchInput {
  background: rgba(255, 255, 255, 0.85) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #medreseResearchModal #medreseResearchesGrid > div {
  background: rgba(252, 250, 244, 0.75) !important;
  border: 1.5px solid #d4c5b0 !important;
}
html[data-theme="parchment"] #medreseResearchModal #medreseResearchesGrid p {
  background: rgba(237, 227, 206, 0.75) !important;
  color: #3b2713 !important;
  border: 1px solid #d4c5b0 !important;
}
html[data-theme="parchment"] #medreseResearchModal #medreseResearchesGrid span[style*="color:#fff"] {
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] #medreseResearchModal #medreseResearchesGrid div[style*="repeat(4"] > div {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
}
html[data-theme="parchment"] #medreseResearchModal #medreseResearchesGrid div[style*="repeat(4"] span {
  color: #241a12 !important;
}

/* --- 15.3 CEPHANE ARMORY CARDS & UPGRADE ROWS --- */
html[data-theme="parchment"] #cephaneArmoryModal .modal-dark-card {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #cephaneArmoryModal .modal-body > div > div {
  background: rgba(252, 250, 244, 0.75) !important;
  border: 1.5px solid #d4c5b0 !important;
}
html[data-theme="parchment"] #cephaneArmoryModal div[style*="background:rgba(0,0,0,0.35)"] {
  background: rgba(247, 241, 228, 0.75) !important;
  border: 1px solid #c9bea9 !important;
}
html[data-theme="parchment"] #cephaneArmoryModal div[style*="background:rgba(0,0,0,0.3)"] {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
}
html[data-theme="parchment"] #cephaneArmoryModal div[style*="color:#cbd5e1"] {
  color: #523f2f !important;
}

/* --- 15.4 GÖREVLER & BAŞARIMLAR (Quests & Milestones) --- */
html[data-theme="parchment"] #questsAndMilestonesModal .modal-window {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-bar {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  align-items: stretch !important;
  gap: 6px !important;
  padding: 6px 10px !important;
  background: rgba(237, 227, 206, 0.75) !important;
  border: none !important;
  border-bottom: 1.5px solid #8c6534 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  overflow: visible !important;
}
html[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-btn {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #4a3420 !important;
  white-space: normal !important;
}
html[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-btn.active {
  background: linear-gradient(135deg, #d97706, #b45309) !important;
  color: #ffffff !important;
  border-color: #92400e !important;
}
html.mobile-portrait-mode[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-btn,
html.mobile-landscape-mode[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-btn,
html.mobile-portrait-mode[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-btn span:not(.event-badge),
html.mobile-landscape-mode[data-theme="parchment"] #questsAndMilestonesModal .quests-tab-btn span:not(.event-badge) {
  font-size: 10px !important;
  line-height: 1.18 !important;
  white-space: normal !important;
}
html[data-theme="parchment"] #questsAndMilestonesModal div[style*="background:rgba(0,0,0,0.4)"] {
  background: rgba(240, 229, 209, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #questsAndMilestonesModal div[style*="background:rgba(0,0,0,0.4)"] span[style*="color:#f8fafc"] {
  color: #241a12 !important;
}
html[data-theme="parchment"] #questsAndMilestonesModal div[style*="background:rgba(0,0,0,0.4)"] span[style*="color:#94a3b8"],
html[data-theme="parchment"] #questsAndMilestonesModal div[style*="background:rgba(0,0,0,0.4)"] div[style*="color:#94a3b8"] {
  color: #523f2f !important;
}
html[data-theme="parchment"] .quest-item-card,
html[data-theme="parchment"] #dailyQuestsListContainer > div,
html[data-theme="parchment"] #milestonesListContainer > div {
  background: rgba(252, 250, 244, 0.75) !important;
  border: 1.5px solid #d4c5b0 !important;
  box-shadow: 0 2px 8px rgba(45, 30, 15, 0.08) !important;
}
html[data-theme="parchment"] .quest-item-card.is-ready,
html[data-theme="parchment"] #dailyQuestsListContainer > div[style*="34,197,94"],
html[data-theme="parchment"] #milestonesListContainer > div[style*="34,197,94"] {
  background: rgba(240, 253, 244, 0.8) !important;
  border: 1.5px solid #22c55e !important;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.25) !important;
}
html[data-theme="parchment"] .quest-item-card.is-done,
html[data-theme="parchment"] #dailyQuestsListContainer > div[style*="0.65"],
html[data-theme="parchment"] #milestonesListContainer > div[style*="0.65"] {
  background: rgba(245, 239, 230, 0.7) !important;
  border: 1px solid #e2d7c5 !important;
  opacity: 0.8 !important;
}
html[data-theme="parchment"] .quest-item-card .quest-title,
html[data-theme="parchment"] #dailyQuestsListContainer span[style*="color:#fff"],
html[data-theme="parchment"] #milestonesListContainer span[style*="color:#fff"] {
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] .quest-item-card .quest-desc,
html[data-theme="parchment"] #dailyQuestsListContainer span[style*="color:#94a3b8"],
html[data-theme="parchment"] #milestonesListContainer div[style*="color:#cbd5e1"] {
  color: #523f2f !important;
}
html[data-theme="parchment"] #dailyQuestsListContainer div[style*="background:rgba(0,0,0,0.5)"],
html[data-theme="parchment"] #milestonesListContainer div[style*="background:rgba(0,0,0,0.5)"] {
  background: rgba(237, 224, 202, 0.75) !important;
  border: 1px solid #bda88e !important;
}
html[data-theme="parchment"] .quest-clean-reward-chip {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #241a12 !important;
  box-shadow: 0 1px 3px rgba(45, 30, 15, 0.1) !important;
}
html[data-theme="parchment"] .quest-clean-reward-chip span {
  color: #241a12 !important;
}

/* --- 15.5 YAĞMA LİSTESİ (Farm Raid Modal) --- */
html[data-theme="parchment"] #farmListModal .modal-window {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
/* Stamina Bar Box */
html[data-theme="parchment"] #farmListModal .farm-stamina-card,
html[data-theme="parchment"] #farmListModal .modal-body > div:first-child,
html[data-theme="parchment"] #farmListModal div[style*="YAĞMA ENERJİ BARI"] {
  background: linear-gradient(145deg, rgba(247, 241, 228, 0.75) 0%, rgba(235, 224, 202, 0.75) 100%) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: 0 4px 12px rgba(45, 30, 15, 0.12) !important;
}
html[data-theme="parchment"] #farmListModal .farm-stamina-card span[style*="color:#fde047"],
html[data-theme="parchment"] #farmListModal .modal-body > div:first-child span[style*="color:#fde047"] {
  color: #8c5816 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] #farmListModal #farmStaminaText {
  color: #241a12 !important;
  font-weight: 900 !important;
}
html[data-theme="parchment"] #farmListModal #farmStaminaMultiplierBadge {
  background: rgba(240, 229, 209, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
  color: #7c4d16 !important;
}
html[data-theme="parchment"] #farmListModal #farmStaminaNextTimer {
  color: #523f2f !important;
}
html[data-theme="parchment"] #farmListModal #farmStaminaTierPerk {
  color: #6e4414 !important;
}
html[data-theme="parchment"] #farmListModal .farm-stamina-card div[style*="rgba(0,0,0,0.5)"],
html[data-theme="parchment"] #farmListModal .modal-body > div:first-child div[style*="rgba(0,0,0,0.5)"] {
  background: rgba(223, 208, 183, 0.75) !important;
  border: 1px solid #bda88e !important;
}
/* Hedef Sayısı Action Bar */
html[data-theme="parchment"] #farmListModal .farm-actions-bar,
html[data-theme="parchment"] #farmListModal .modal-body > div:nth-child(2),
html[data-theme="parchment"] #farmListModal div[style*="Hedef Sayısı:"] {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1.5px solid #bda88e !important;
  box-shadow: 0 2px 6px rgba(45, 30, 15, 0.08) !important;
}
html[data-theme="parchment"] #farmListModal .farm-actions-bar span[style*="color:#94a3b8"],
html[data-theme="parchment"] #farmListModal .modal-body > div:nth-child(2) span[style*="color:#94a3b8"] {
  color: #5c4530 !important;
}
html[data-theme="parchment"] #farmListModal #farmListCountDisplay {
  color: #241a12 !important;
  font-weight: 900 !important;
}
html[data-theme="parchment"] #farmListModal .farm-raid-btn {
  padding: 5px 9px !important;
  min-height: 26px !important;
  line-height: 1.25 !important;
}
html[data-theme="parchment"] #farmListModal .farm-target-row td {
  white-space: nowrap !important;
}
/* General Farm Troop Settings Drawer */
html[data-theme="parchment"] #farmSettingsDrawer {
  background: linear-gradient(145deg, rgba(251, 248, 242, 0.75) 0%, rgba(243, 235, 217, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  box-shadow: 0 8px 24px rgba(45, 30, 15, 0.2) !important;
}
html[data-theme="parchment"] #farmSettingsTitle {
  color: #6e4414 !important;
}
html[data-theme="parchment"] #farmSettingsSubtitle {
  color: #523f2f !important;
}
html[data-theme="parchment"] #farmSettingsDrawer div[style*="Gönderilecek Çıkış Köyü:"] {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
}
html[data-theme="parchment"] #farmSettingsSourceVillage {
  background: rgba(255, 255, 255, 0.85) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] .farm-setting-unit-card,
html[data-theme="parchment"] #farmSettingsTroopSelectors > div {
  background: rgba(245, 237, 224, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
}
html[data-theme="parchment"] .farm-setting-unit-card div[style*="color:#93c5fd"],
html[data-theme="parchment"] #farmSettingsTroopSelectors div[style*="color:#93c5fd"] {
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] .farm-setting-unit-card span[style*="color:#64748b"],
html[data-theme="parchment"] #farmSettingsTroopSelectors span[style*="color:#64748b"] {
  color: #6e4414 !important;
}
html[data-theme="parchment"] .farm-setting-unit-card input,
html[data-theme="parchment"] #farmSettingsTroopSelectors input {
  background: rgba(255, 255, 255, 0.85) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] .farm-setting-unit-card button,
html[data-theme="parchment"] #farmSettingsTroopSelectors button {
  background: rgba(237, 227, 206, 0.85) !important;
  border: 1px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #farmSettingsDrawer div[style*="Elmasla Hızlandırılmış Sefer"] {
  background: rgba(255, 248, 235, 0.75) !important;
  border: 1.5px solid #d4af37 !important;
  color: #7c4d16 !important;
}

/* --- 15.6 İMPARATORLUK GENEL DURUMU (Empire Overview) --- */
html[data-theme="parchment"] #empireOverviewModal .modal-window {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
/* Top 3 KPI stat cards */
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:first-child > div {
  background: rgba(247, 241, 228, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
}
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:first-child > div div[style*="color:#94a3b8"] {
  color: #6e4414 !important;
  font-weight: 700 !important;
}
html[data-theme="parchment"] #overviewTotalVillages,
html[data-theme="parchment"] #overviewTotalGrain {
  color: #241a12 !important;
}
/* Shared Resource Pool Card */
html[data-theme="parchment"] #empireOverviewModal .overview-shared-pool-card,
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(2),
html[data-theme="parchment"] #empireOverviewModal div[style*="ORTAK İMPARATORLUK KAYNAK HAVUZU"] {
  background: linear-gradient(145deg, rgba(251, 248, 242, 0.75) 0%, rgba(240, 230, 210, 0.75) 100%) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: 0 4px 12px rgba(45, 30, 15, 0.12) !important;
}
html[data-theme="parchment"] #empireOverviewModal .overview-shared-pool-card > div:first-child,
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(2) > div:first-child {
  border-bottom: 1px solid #d4c5b0 !important;
}
html[data-theme="parchment"] #empireOverviewModal .overview-shared-pool-card div[style*="var(--dirilis-gold-accent)"],
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(2) div[style*="var(--dirilis-gold-accent)"] {
  color: #7c4d16 !important;
}
html[data-theme="parchment"] #empireOverviewModal .overview-shared-pool-card div[style*="color:#94a3b8"],
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(2) div[style*="color:#94a3b8"] {
  color: #5c4530 !important;
}
html[data-theme="parchment"] #overviewSharedResourcesGrid > div {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
}
html[data-theme="parchment"] #overviewSharedResourcesGrid div[style*="color:#f8fafc"] {
  color: #241a12 !important;
}
html[data-theme="parchment"] #overviewSharedResourcesGrid div[style*="color:#94a3b8"] span {
  color: #4a3420 !important;
}
/* Army garrison table */
html[data-theme="parchment"] #empireOverviewModal .overview-military-card,
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(3),
html[data-theme="parchment"] #empireOverviewModal div[style*="KÖYLERİN ASKERİ MEVCUTLARI"] {
  background: linear-gradient(145deg, rgba(251, 248, 242, 0.75) 0%, rgba(240, 230, 210, 0.75) 100%) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: 0 4px 12px rgba(45, 30, 15, 0.12) !important;
}
html[data-theme="parchment"] #empireOverviewModal .overview-military-card > div:first-child,
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(3) > div:first-child {
  border-bottom: 1px solid #d4c5b0 !important;
}
html[data-theme="parchment"] #empireOverviewModal .overview-military-card h4,
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(3) h4 {
  color: #2c4d75 !important;
}
html[data-theme="parchment"] #empireOverviewModal .overview-military-card span[style*="color:#94a3b8"],
html[data-theme="parchment"] #empireOverviewModal .modal-body > div:nth-child(3) span[style*="color:#94a3b8"] {
  color: #5c4530 !important;
}
html[data-theme="parchment"] #overviewVillagesList table {
  background: transparent !important;
}
html[data-theme="parchment"] #overviewVillagesList th {
  background: rgba(237, 227, 206, 0.75) !important;
  color: #6e4414 !important;
  border-bottom: 1.5px solid #8c6534 !important;
}
html[data-theme="parchment"] #overviewVillagesList tr {
  border-bottom: 1px solid #d4c5b0 !important;
}
html[data-theme="parchment"] #overviewVillagesList td div[style*="color:#f8fafc"] {
  color: #241a12 !important;
}
html[data-theme="parchment"] #overviewVillagesList span[style*="Konuşlu birlik yok"] {
  color: #78614d !important;
  font-weight: 600 !important;
}
html[data-theme="parchment"] #overviewVillagesList td span[style*="background:rgba(15,23,42"],
html[data-theme="parchment"] #overviewVillagesList span[style*="background:rgba(15,23,42"],
html[data-theme="parchment"] #overviewVillagesList td span[style*="background:linear-gradient(135deg, rgba(30,58,138"],
html[data-theme="parchment"] #overviewVillagesList span[style*="background:linear-gradient(135deg, rgba(30,58,138"] {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #8c6534 !important;
}
html[data-theme="parchment"] #overviewVillagesList td span[style*="color:#cbd5e1"],
html[data-theme="parchment"] #overviewVillagesList span[style*="color:#e2e8f0"] {
  color: #241a12 !important;
}
html[data-theme="parchment"] #overviewVillagesList td strong[style*="color:#67e8f9"],
html[data-theme="parchment"] #overviewVillagesList strong[style*="color:#fbbf24"] {
  color: #7c4d16 !important;
}
html[data-theme="parchment"] #overviewVillagesList span[style*="background:rgba(59,130,246,0.15)"],
html[data-theme="parchment"] #overviewVillagesList span[style*="color:#93c5fd"] {
  background: rgba(226, 211, 186, 0.75) !important;
  border: 1px solid #8c6534 !important;
  color: #1e3a8a !important;
}
html[data-theme="parchment"] #overviewVillagesList span[style*="background:rgba(30,41,59"] {
  background: rgba(232, 220, 199, 0.75) !important;
  border: 1px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #overviewVillagesList tr[style*="TOPLAM İMPARATORLUK ORDUSU"] {
  background: rgba(237, 224, 200, 0.75) !important;
  border-top: 2px solid #8c6534 !important;
}

/* --- 15.7 SAVAŞ SİMÜLATÖRÜ & KİLİT HESAPLAYICI (Combat Sim & Lock Calc) --- */
html[data-theme="parchment"] #combatSimulatorModal .modal-window {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card {
  background: linear-gradient(145deg, rgba(251, 248, 242, 0.75) 0%, rgba(240, 229, 209, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  box-shadow: 0 8px 30px rgba(45, 30, 15, 0.15) !important;
}
html[data-theme="parchment"] #lockCalcModeSelect {
  background: rgba(237, 227, 206, 0.85) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card label,
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card div[style*="color:#e2e8f0"],
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card span[style*="color:#f8fafc"] {
  color: #241a12 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card div[style*="border-bottom:1px dashed"] {
  border-bottom-color: #8c6534 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card div[style*="background:#18120c"],
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card div[style*="background:#090d16"] {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card input {
  background: rgba(255, 255, 255, 0.85) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card div[style*="DÜŞMAN ASKERİ"] {
  background: rgba(253, 242, 242, 0.75) !important;
  border: 1.5px solid #f87171 !important;
}
html[data-theme="parchment"] #combatSimulatorModal .lock-calc-card div[style*="BİZİM ASKERİMİZ"] {
  background: rgba(240, 253, 244, 0.75) !important;
  border: 1.5px solid #4ade80 !important;
}

/* --- 15.8 İMPARATORLUK SIRALAMALARI (Rankings Modal) --- */
html[data-theme="parchment"] .rankings-table-wrapper {
  background: rgba(251, 248, 242, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: inset 0 1px 4px rgba(45, 30, 15, 0.08) !important;
}
html[data-theme="parchment"] .imperial-table th {
  background: rgba(237, 227, 206, 0.85) !important;
  color: #6e4414 !important;
  border-bottom: 2px solid #8c6534 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] .imperial-row {
  background: rgba(255, 255, 255, 0.65) !important;
  border-bottom: 1px solid #e5d9c7 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] .imperial-row:nth-child(even) {
  background: rgba(247, 241, 228, 0.75) !important;
}
html[data-theme="parchment"] .imperial-row:hover {
  background: rgba(237, 225, 203, 0.85) !important;
}
html[data-theme="parchment"] .imperial-row.podium-1 {
  background: linear-gradient(90deg, rgba(234, 179, 8, 0.25) 0%, rgba(234, 179, 8, 0.08) 100%) !important;
  border-left: 3.5px solid #d97706 !important;
}
html[data-theme="parchment"] .imperial-row.podium-2 {
  background: linear-gradient(90deg, rgba(148, 163, 184, 0.25) 0%, rgba(148, 163, 184, 0.08) 100%) !important;
  border-left: 3.5px solid #64748b !important;
}
html[data-theme="parchment"] .imperial-row.podium-3 {
  background: linear-gradient(90deg, rgba(180, 83, 9, 0.25) 0%, rgba(180, 83, 9, 0.08) 100%) !important;
  border-left: 3.5px solid #92400e !important;
}
html[data-theme="parchment"] .imperial-row.is-self {
  background: linear-gradient(90deg, rgba(34, 197, 94, 0.28) 0%, rgba(34, 197, 94, 0.08) 100%) !important;
  border-left: 3.5px solid #16a34a !important;
}
html[data-theme="parchment"] .imperial-row td {
  color: #241a12 !important;
}
html[data-theme="parchment"] .ranking-player-name,
html[data-theme="parchment"] .ranking-clan-name {
  color: #241a12 !important;
}
html[data-theme="parchment"] .rankings-pagination-footer {
  background: rgba(237, 227, 206, 0.75) !important;
  border-top: 1px solid #8c6534 !important;
  color: #241a12 !important;
}

/* --- 15.9 OYUN REHBERİ & ANSİKLOPEDİ (Wiki Modal) --- */
html[data-theme="parchment"] #gameWikiModal .modal-dark-card {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] #gameWikiModal #wikiSearchInput {
  background: rgba(255, 255, 255, 0.85) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] .wiki-tab-btn {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #4a3420 !important;
}
html[data-theme="parchment"] .wiki-tab-btn.active {
  background: linear-gradient(135deg, #8c6534, #6b4010) !important;
  border-color: #52310a !important;
  color: #ffffff !important;
}
html[data-theme="parchment"] #gameWikiModal div[style*="Bina Geliştirme Kılavuzu:"] {
  background: rgba(253, 248, 237, 0.75) !important;
  border: 1.5px solid #d4af37 !important;
  color: #7c4d16 !important;
}
html[data-theme="parchment"] .wiki-card {
  background: rgba(252, 250, 244, 0.75) !important;
  border: 1.5px solid #d4c5b0 !important;
  box-shadow: 0 2px 8px rgba(45, 30, 15, 0.08) !important;
}
html[data-theme="parchment"] .wiki-card:hover {
  border-color: #8c6534 !important;
  background: rgba(255, 255, 255, 0.9) !important;
  box-shadow: 0 6px 18px rgba(45, 30, 15, 0.15) !important;
}
html[data-theme="parchment"] .wiki-card-icon {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #8c6534 !important;
}
html[data-theme="parchment"] .wiki-card-title {
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] .wiki-card-subtitle {
  color: #78614d !important;
}
html[data-theme="parchment"] .wiki-card-body {
  color: #3b2713 !important;
}
html[data-theme="parchment"] .wiki-stat-row {
  border-top: 1px solid #e5d9c7 !important;
}
html[data-theme="parchment"] .wiki-stat-label {
  color: #78614d !important;
}
html[data-theme="parchment"] .wiki-stat-val {
  color: #241a12 !important;
  font-weight: 800 !important;
}

/* --- 15.10 ELMAS MAĞAZASI (Plus & Pro, Barış Kalkanları) --- */
html[data-theme="parchment"] #diamondShopModal .modal-window {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
}
html[data-theme="parchment"] .diamond-shop-tabs-bar {
  background: rgba(237, 227, 206, 0.75) !important;
  border-bottom: 1.5px solid #8c6534 !important;
}
html[data-theme="parchment"] .diamond-shop-tabs-bar .chat-chamfer-tab-btn {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #4a3420 !important;
}
html[data-theme="parchment"] .diamond-shop-tabs-bar .chat-chamfer-tab-btn.active {
  background: rgba(251, 248, 242, 0.9) !important;
  border-color: #8c6534 !important;
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] #shopStatusBanner {
  background: rgba(237, 227, 206, 0.75) !important;
  border: 1.5px solid #bda88e !important;
}
html[data-theme="parchment"] #shopStatusBanner .shop-status-banner-label {
  color: #6e4414 !important;
  font-weight: 700 !important;
}
html[data-theme="parchment"] #shopStatusBanner .shop-status-banner-val {
  color: #241a12 !important;
}
/* Plus Account Card */
html[data-theme="parchment"] .shop-subs-grid > div:first-child {
  background: linear-gradient(180deg, rgba(245, 249, 255, 0.75) 0%, rgba(237, 244, 254, 0.75) 100%) !important;
  border: 2px solid #60a5fa !important;
}
html[data-theme="parchment"] .shop-subs-grid > div:first-child h4 {
  color: #1e3a8a !important;
}
html[data-theme="parchment"] .shop-subs-grid > div:first-child p,
html[data-theme="parchment"] .shop-subs-grid > div:first-child ul {
  color: #1e293b !important;
}
/* Pro Account Card */
html[data-theme="parchment"] .shop-subs-grid > div:last-child {
  background: linear-gradient(180deg, rgba(254, 250, 240, 0.75) 0%, rgba(250, 237, 215, 0.75) 100%) !important;
  border: 2px solid #d97706 !important;
}
html[data-theme="parchment"] .shop-subs-grid > div:last-child h4 {
  color: #78350f !important;
}
html[data-theme="parchment"] .shop-subs-grid > div:last-child p,
html[data-theme="parchment"] .shop-subs-grid > div:last-child ul {
  color: #241a12 !important;
}
/* Shield Cards & Alert */
html[data-theme="parchment"] #shopShieldInfoBox {
  background: rgba(255, 241, 242, 0.75) !important;
  border: 1.5px solid #f87171 !important;
  color: #991b1b !important;
}
html[data-theme="parchment"] .shop-shields-grid .shop-item-card {
  background: rgba(252, 250, 244, 0.75) !important;
  border: 1.5px solid #d4c5b0 !important;
  box-shadow: 0 2px 8px rgba(45, 30, 15, 0.08) !important;
}
html[data-theme="parchment"] .shop-shields-grid .shop-item-card h5 {
  color: #241a12 !important;
  font-weight: 800 !important;
}
html[data-theme="parchment"] .shop-shields-grid .shop-item-card div[style*="color:#94a3b8"] {
  color: #6e4414 !important;
  font-weight: 600 !important;
}
html[data-theme="parchment"] .shop-shields-grid .shop-item-card [disabled] {
  background: rgba(237, 224, 202, 0.75) !important;
  border: 1px solid #bda88e !important;
  color: #6e4414 !important;
}

/* ==========================================================================
   16. PART-3 ENHANCEMENTS: WEB HUD, MOBILE BOTTOM NAV, REPORTS, SEND MOVEMENT & TOOLTIPS
   ========================================================================== */

/* 16.1 WEB HUD ELEMENTS (CHAT TABS, CENTER OWN VILLAGE, CENTER HUD BAR) */
html[data-theme="parchment"] .right-chat-tabs .chat-tab-vertical {
  background: linear-gradient(90deg, rgba(237, 224, 202, 0.75) 0%, rgba(219, 204, 168, 0.75) 100%) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: none !important;
  color: #4a3420 !important;
  font-weight: 800 !important;
  text-shadow: none !important;
  box-shadow: -3px 3px 10px rgba(50, 35, 20, 0.2) !important;
}

html[data-theme="parchment"] .right-chat-tabs .chat-tab-vertical:hover {
  background: linear-gradient(90deg, rgba(245, 235, 216, 0.9) 0%, rgba(230, 216, 182, 0.9) 100%) !important;
  color: #1a1005 !important;
  border: none !important;
  box-shadow: -4px 4px 14px rgba(110, 68, 20, 0.3) !important;
}

html[data-theme="parchment"] .right-chat-tabs .chat-tab-vertical.tab-assistant {
  background: linear-gradient(90deg, rgba(219, 234, 254, 0.75) 0%, rgba(191, 219, 254, 0.75) 100%) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  border: none !important;
  color: #1e40af !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .right-chat-tabs .chat-tab-vertical.tab-assistant:hover {
  background: linear-gradient(90deg, rgba(239, 246, 255, 0.9) 0%, rgba(219, 234, 254, 0.9) 100%) !important;
  color: #172554 !important;
  border: none !important;
}

html[data-theme="parchment"] .right-chat-tabs .chat-vertical-badge {
  background: #dc2626 !important;
  color: #ffffff !important;
  font-weight: 800 !important;
  border: 1px solid #991b1b !important;
}

/* Floating Focus Own Village Button on Map & Village Top Header */
html[data-theme="parchment"] #btnCenterOwnVillage,
html[data-theme="parchment"] .btn-center-own-village,
html[data-theme="parchment"] #btnVillageBackToMap,
html[data-theme="parchment"] #villageConstructionQueueBar {
  background: linear-gradient(135deg, rgba(252, 248, 237, 0.75) 0%, rgba(237, 224, 202, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #4a3420 !important;
  font-weight: 800 !important;
  box-shadow: 0 6px 18px rgba(50, 35, 20, 0.22) !important;
  text-shadow: none !important;
}

html[data-theme="parchment"] #villageConstructionQueueBar span,
html[data-theme="parchment"] #villageConstructionQueueBar div {
  color: #241a12 !important;
}

html[data-theme="parchment"] #btnCenterOwnVillage:hover,
html[data-theme="parchment"] .btn-center-own-village:hover,
html[data-theme="parchment"] #btnVillageBackToMap:hover {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(244, 232, 211, 0.9) 100%) !important;
  border-color: #6e4414 !important;
  color: #241a12 !important;
  box-shadow: 0 8px 22px rgba(110, 68, 20, 0.3) !important;
}

/* Bottom Center Server Time & Coordinates HUD Bar */
html[data-theme="parchment"] #centerHudBar,
html[data-theme="parchment"] .center-hud-bar {
  background: linear-gradient(135deg, rgba(253, 250, 244, 0.75), rgba(237, 224, 202, 0.75)) !important;
  border: 1.5px solid #8c6534 !important;
  color: #4a3420 !important;
  box-shadow: 0 6px 20px rgba(50, 35, 20, 0.2) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

html[data-theme="parchment"] #centerHudBar #hudServerTime {
  color: #0369a1 !important;
  font-weight: 900 !important;
  font-family: monospace !important;
}

html[data-theme="parchment"] #centerHudBar #hudCoordsText {
  color: #92400e !important;
  font-weight: 900 !important;
}

/* 16.2 MOBILE BOTTOM NAVIGATION BAR */
html[data-theme="parchment"] .mobile-bottom-nav {
  background: linear-gradient(180deg, rgba(247, 240, 225, 0.75) 0%, rgba(235, 224, 202, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border-top: 1.5px solid #8c6534 !important;
  box-shadow: 0 -4px 18px rgba(50, 35, 20, 0.18) !important;
}

html[data-theme="parchment"] .mobile-nav-item {
  color: #6e4e2b !important;
}

html[data-theme="parchment"] .mobile-nav-label {
  color: #5c4228 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] .mobile-nav-item:active,
html[data-theme="parchment"] .mobile-nav-item.active {
  color: #854d0e !important;
}

html[data-theme="parchment"] .mobile-nav-item.active .mobile-nav-label {
  color: #78350f !important;
  font-weight: 900 !important;
}

html[data-theme="parchment"] .mobile-nav-item.active .mobile-nav-icon {
  filter: drop-shadow(0 2px 5px rgba(133, 77, 14, 0.45)) !important;
}

/* 16.3 BATTLE REPORTS READABILITY & CONTRAST */
html[data-theme="parchment"] .report-tp-badge-attacker,
html[data-theme="parchment"] #reportsModal span[title*="Saldıran"],
html[data-theme="parchment"] div[id*="report"] span[title*="Saldıran"] {
  background: rgba(254, 226, 226, 0.8) !important;
  border: 1px solid #dc2626 !important;
  color: #991b1b !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-tp-badge-defender,
html[data-theme="parchment"] #reportsModal span[title*="Savunan"],
html[data-theme="parchment"] div[id*="report"] span[title*="Savunan"] {
  background: rgba(224, 242, 254, 0.8) !important;
  border: 1px solid #2563eb !important;
  color: #1e40af !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box {
  background: rgba(253, 250, 244, 0.75) !important;
  border: 1.5px solid #d4c5b0 !important;
  border-radius: 8px !important;
  box-shadow: 0 2px 6px rgba(45, 30, 15, 0.08) !important;
}

html[data-theme="parchment"] .report-box div[style*="SALDIRAN"] {
  color: #92400e !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box div[style*="SAVUNAN"] {
  color: #b91c1c !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box .ranking-player-name {
  color: #1a1005 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box span[onclick*="focusMapOnCoords"] {
  color: #78350f !important;
  font-weight: 600 !important;
}

html[data-theme="parchment"] .report-power-text,
html[data-theme="parchment"] .report-box div[style*="Saldırı Gücü"],
html[data-theme="parchment"] .report-box div[style*="Casus Gücü"] {
  color: #78350f !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-power-defender,
html[data-theme="parchment"] .report-box div[style*="Savunma Gücü"] {
  color: #1e40af !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box div[style*="minmax(72px, 1fr)"] > div {
  background: rgba(248, 243, 232, 0.75) !important;
  border: 1px solid #c9b497 !important;
  border-radius: 6px !important;
  box-shadow: 0 2px 4px rgba(45, 30, 15, 0.08) !important;
  color: #241a12 !important;
}

html[data-theme="parchment"] .report-box div[style*="minmax(72px, 1fr)"] > div div:nth-child(2) {
  color: #1a1005 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box div[style*="minmax(72px, 1fr)"] > div div:nth-child(3) {
  color: #5c4228 !important;
}

html[data-theme="parchment"] .report-box div[style*="minmax(72px, 1fr)"] > div div:nth-child(3) b {
  color: #1a1005 !important;
}

html[data-theme="parchment"] .report-box .report-box-title,
html[data-theme="parchment"] .report-box div[style*="Ganimetler"] {
  color: #78350f !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box div[style*="Yük:"] {
  background: rgba(254, 243, 199, 0.8) !important;
  border: 1px solid #d97706 !important;
  color: #92400e !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .report-box div[style*="Yük:"] span {
  color: #1a1005 !important;
}

html[data-theme="parchment"] .reports-mobile-back-btn,
html[data-theme="parchment"] #reportsModal button[onclick*="showReportsList"] {
  background: rgba(253, 245, 214, 0.85) !important;
  border: 1.5px solid #d97706 !important;
  color: #78350f !important;
  font-weight: 800 !important;
}

/* 16.4 ASKER GÖNDERME PANELİ HEADER PILLS & SAFE BOUNDING */
html[data-theme="parchment"] .send-movement-header-inner,
html[data-theme="parchment"] #sendMovementModal .send-movement-header-inner {
  padding: 0 48px !important;
  box-sizing: border-box !important;
}

html[data-theme="parchment"] #movementEtaContainer {
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 5px !important;
}

html[data-theme="parchment"] .movement-eta-pill,
html[data-theme="parchment"] #movementEtaContainer > span {
  box-shadow: 0 1px 3px rgba(50, 35, 20, 0.1) !important;
}

html[data-theme="parchment"] .eta-pill-server,
html[data-theme="parchment"] #movementEtaContainer span[title*="Saat"] {
  background: rgba(234, 246, 234, 0.8) !important;
  border: 1.5px solid #4ade80 !important;
  color: #14532d !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] #movementServerClockDisplay {
  color: #15803d !important;
  font-weight: 900 !important;
}

html[data-theme="parchment"] .eta-pill-duration,
html[data-theme="parchment"] #movementEtaContainer span[title*="Süre"] {
  background: rgba(254, 247, 224, 0.8) !important;
  border: 1.5px solid #f59e0b !important;
  color: #78350f !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] #movementEtaDisplay {
  color: #92400e !important;
  font-weight: 900 !important;
}

html[data-theme="parchment"] .eta-pill-arrival,
html[data-theme="parchment"] #movementEtaContainer span[title*="Varış"] {
  background: rgba(232, 244, 253, 0.8) !important;
  border: 1.5px solid #0284c7 !important;
  color: #075985 !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] #movementArrivalClockDisplay {
  color: #0369a1 !important;
  font-weight: 900 !important;
}

html[data-theme="parchment"] .eta-pill-boost,
html[data-theme="parchment"] #movementSpeedBoostBadge {
  background: rgba(207, 250, 254, 0.8) !important;
  border: 1.5px solid #0891b2 !important;
  color: #0e7490 !important;
  font-weight: 900 !important;
}

/* 16.5 MAP HOVER TOOLTIP (CAPACITY & WORKERS CONTRAST) */
html[data-theme="parchment"] #mapHoverTooltip {
  background: rgba(254, 253, 249, 0.75) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  color: #241a12 !important;
  box-shadow: 0 10px 30px rgba(50, 35, 20, 0.3) !important;
  border-radius: 10px !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-title-row,
html[data-theme="parchment"] #mapHoverTooltip > div:first-child {
  color: #78350f !important;
  font-weight: 900 !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-level-badge,
html[data-theme="parchment"] #mapHoverTooltip span[style*="Seviye"] {
  background: rgba(240, 229, 209, 0.75) !important;
  border: 1px solid #8c6534 !important;
  color: #78350f !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-cap-row,
html[data-theme="parchment"] #mapHoverTooltip div[style*="#cbd5e1"] {
  color: #5c4228 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-cap-val,
html[data-theme="parchment"] #mapHoverTooltip div[style*="#cbd5e1"] strong {
  color: #1a1005 !important;
  font-weight: 900 !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-workers-row {
  color: #15803d !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-reach-in,
html[data-theme="parchment"] #mapHoverTooltip div[style*="#4ade80"] {
  color: #166534 !important;
  font-weight: 700 !important;
}

html[data-theme="parchment"] #mapHoverTooltip .map-tooltip-reach-out,
html[data-theme="parchment"] #mapHoverTooltip div[style*="#f87171"] {
  color: #b91c1c !important;
  font-weight: 700 !important;
}

/* --- 15.11 SAATLİK ÜRETİM TABLOSU (Hourly Production Matrix) --- */
html[data-theme="parchment"] #resourceProductionModal .res-prod-card {
  background: linear-gradient(180deg, rgba(253, 251, 247, 0.75) 0%, rgba(246, 239, 226, 0.75) 100%) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: 0 16px 40px rgba(45, 30, 15, 0.25) !important;
}

html[data-theme="parchment"] .res-prod-table-container,
html[data-theme="parchment"] #resourceProductionModal .res-prod-table-container {
  background: rgba(251, 247, 239, 0.75) !important;
  border: 1.5px solid #8c6534 !important;
  box-shadow: inset 0 1px 3px rgba(40, 25, 10, 0.08) !important;
}

html[data-theme="parchment"] .res-prod-table {
  color: #241a12 !important;
}

/* Sticky Header Row */
html[data-theme="parchment"] .res-prod-table thead th {
  background: linear-gradient(180deg, rgba(237, 227, 206, 0.85) 0%, rgba(226, 211, 186, 0.85) 100%) !important;
  border-bottom: 2px solid #8c6534 !important;
  color: #5c4228 !important;
  font-weight: 800 !important;
}

/* Sticky City Column Header */
html[data-theme="parchment"] .res-prod-table thead th.res-prod-th-city {
  background: linear-gradient(180deg, rgba(235, 220, 197, 0.9) 0%, rgba(219, 202, 174, 0.9) 100%) !important;
  border-right: 1.5px solid #8c6534 !important;
  color: #3b2814 !important;
}

/* Table Body Rows */
html[data-theme="parchment"] .res-prod-table tbody tr {
  background: rgba(253, 251, 247, 0.65) !important;
  border-bottom: 1px solid #e5d8c3 !important;
}

html[data-theme="parchment"] .res-prod-table tbody tr:nth-child(even) {
  background: rgba(245, 238, 223, 0.75) !important;
}

html[data-theme="parchment"] .res-prod-table tbody tr:hover {
  background: rgba(236, 224, 204, 0.85) !important;
}

html[data-theme="parchment"] .res-prod-table tbody td {
  border-bottom: 1px solid #e5d8c3 !important;
  color: #241a12 !important;
}

/* Sticky City Column in Body */
html[data-theme="parchment"] .res-prod-table tbody td.res-prod-col-city {
  background: rgba(247, 240, 226, 0.85) !important;
  border-right: 1.5px solid #bda88e !important;
}

html[data-theme="parchment"] .res-prod-table tbody tr:nth-child(even) td.res-prod-col-city {
  background: rgba(240, 230, 212, 0.85) !important;
}

html[data-theme="parchment"] .res-prod-table tbody tr:hover td.res-prod-col-city {
  background: rgba(235, 220, 197, 0.9) !important;
}

html[data-theme="parchment"] .res-prod-table tbody tr.res-prod-current-row td.res-prod-col-city {
  background: rgba(230, 213, 188, 0.9) !important;
  border-left: 3px solid #8c6534 !important;
}

html[data-theme="parchment"] .res-prod-city-title {
  color: #2b1d0c !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .res-prod-active-badge {
  color: #166534 !important;
  font-weight: 800 !important;
}

/* Production Numbers in Parchment */
html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#cbd5e1"],
html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#94a3b8"],
html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#e2e8f0"] {
  color: #3d2b19 !important;
}

html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#4ade80"] {
  color: #15803d !important;
}

html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#fbbf24"],
html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#f59e0b"] {
  color: #b45309 !important;
}

html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#ef4444"],
html[data-theme="parchment"] .res-prod-table tbody td span[style*="color:#ef4444"] {
  color: #b91c1c !important;
}

html[data-theme="parchment"] .res-prod-table tbody td[style*="color:#38bdf8"] {
  color: #0369a1 !important;
}

/* Sticky Total Footer Row */
html[data-theme="parchment"] .res-prod-table tfoot tr {
  background: linear-gradient(180deg, rgba(237, 227, 206, 0.85) 0%, rgba(219, 202, 174, 0.85) 100%) !important;
  border-top: 2px solid #8c6534 !important;
  border-bottom: 2px solid #8c6534 !important;
}

html[data-theme="parchment"] .res-prod-table tfoot td {
  background: rgba(235, 220, 197, 0.85) !important;
  border-top: 2px solid #8c6534 !important;
  border-bottom: 2px solid #8c6534 !important;
  color: #2b1d0c !important;
  font-weight: 800 !important;
}

html[data-theme="parchment"] .res-prod-table tfoot td[style*="color:#fff"],
html[data-theme="parchment"] .res-prod-table tfoot td[style*="color:#cbd5e1"] {
  color: #2b1d0c !important;
}

html[data-theme="parchment"] .res-prod-table tfoot td[style*="color:#4ade80"] {
  color: #15803d !important;
}

html[data-theme="parchment"] .res-prod-table tfoot td.res-prod-total-city {
  background: rgba(226, 209, 181, 0.9) !important;
  border-right: 1.5px solid #8c6534 !important;
  color: #3b2814 !important;
  font-weight: 900 !important;
}

/* ==========================================================================
   17. DYNAMIC USER-CONFIGURABLE PANEL TRANSPARENCY & DUAL BACKGROUND COLOR ENGINE
   Driven by CSS variables on <html>:
   --panel-alpha, --panel-well-alpha, --panel-blur,
   --panel-bg-top-rgb, --panel-bg-bot-rgb (Main Semi-Transparent Panels & Modals)
   --panel-well-rgb (Inner Resource Boxes, City Rows, Troop Cards & Modal Wells)
   ========================================================================== */

/* 17.1 Main Semi-Transparent HUD Panels (Left/Right Sidebars, Resource Bar, Troop Bar, Chat, HUD Bars)
   Zero real-time backdrop-filter over active 60-120fps game canvas/village board to prevent GPU blur overdraw! */
html[data-theme]:not([data-theme="gokturk"]) body .left-sidebar,
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar,
html[data-theme]:not([data-theme="gokturk"]) body .top-mobile-resource-bar,
html[data-theme]:not([data-theme="gokturk"]) body .bottom-troop-bar:not(.collapsed),
html[data-theme]:not([data-theme="gokturk"]) body #chatSlideWindow,
html[data-theme]:not([data-theme="gokturk"]) body .chat-window,
html[data-theme]:not([data-theme="gokturk"]) body .mobile-bottom-nav,
html[data-theme]:not([data-theme="gokturk"]) body #centerHudBar,
html[data-theme]:not([data-theme="gokturk"]) body .center-hud-bar,
html[data-theme]:not([data-theme="gokturk"]) body #btnCenterOwnVillage,
html[data-theme]:not([data-theme="gokturk"]) body .btn-center-own-village,
html[data-theme]:not([data-theme="gokturk"]) body #btnVillageBackToMap,
html[data-theme]:not([data-theme="gokturk"]) body .village-back-to-map-btn,
html[data-theme]:not([data-theme="gokturk"]) body #villageConstructionQueueBar,
html[data-theme]:not([data-theme="gokturk"]) body .action-circle-btn,
html[data-theme]:not([data-theme="gokturk"]) body .left-sidebar-toggle-btn,
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar-toggle-btn,
html[data-theme]:not([data-theme="gokturk"]) body .bottom-troop-bar-toggle-btn {
  background: linear-gradient(180deg, rgba(var(--panel-bg-top-rgb, 253, 251, 247), var(--panel-alpha, 0.85)) 0%, rgba(var(--panel-bg-bot-rgb, 243, 235, 220), var(--panel-alpha, 0.85)) 100%) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* 17.2 All Modals in Parchment & Classic Themes */
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .modal-dark-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .modal-content,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .custom-modal,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .hud-panel,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .ranking-modal-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .send-movement-modal-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .mobile-menu-drawer-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .confirm-modal-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .modal-info-drawer,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #farmSettingsDrawer,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #medreseResearchModal .modal-dark-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #cephaneArmoryModal .modal-dark-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #questsAndMilestonesModal .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #farmListModal .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #empireOverviewModal .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #combatSimulatorModal .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #gameWikiModal .modal-dark-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #diamondShopModal .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #resourceProductionModal .res-prod-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #troopHoverTooltip,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #quickTroopCard,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .troop-mini-modal,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #mapHoverTooltip,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #buildingTooltip,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .game-toast-box,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body #gameToastNotification,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body div[id*="Modal"] > .modal-dark-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body div[id*="Modal"] > .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body div[id*="Modal"] > div[class*="card"],
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body div[id$="Modal"] .modal-dark-card,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body div[id$="Modal"] .modal-window,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body div[id$="Modal"] > div:first-child:not(.modal-close-btn),
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .modal-overlay > div:first-child,
html[data-theme]:not([data-theme="glassmorphism"]):not([data-theme="gokturk"]) body .modal-backdrop > div:first-child {
  background: linear-gradient(180deg, rgba(var(--panel-bg-top-rgb, 253, 251, 247), var(--panel-alpha, 0.75)) 0%, rgba(var(--panel-bg-bot-rgb, 243, 235, 220), var(--panel-alpha, 0.75)) 100%) !important;
  backdrop-filter: blur(var(--panel-blur, 10px)) !important;
  -webkit-backdrop-filter: blur(var(--panel-blur, 10px)) !important;
}

/* 17.3 All Modals in Glassmorphism Theme (Preserving Gold Filigree Corners & Crests without Tiling) */
html[data-theme="glassmorphism"] body .modal-dark-card,
html[data-theme="glassmorphism"] body .modal-window,
html[data-theme="glassmorphism"] body .modal-content,
html[data-theme="glassmorphism"] body .custom-modal,
html[data-theme="glassmorphism"] body .hud-panel,
html[data-theme="glassmorphism"] body .ranking-modal-card,
html[data-theme="glassmorphism"] body .send-movement-modal-card,
html[data-theme="glassmorphism"] body .mobile-menu-drawer-card,
html[data-theme="glassmorphism"] body #medreseResearchModal .modal-dark-card,
html[data-theme="glassmorphism"] body #cephaneArmoryModal .modal-dark-card,
html[data-theme="glassmorphism"] body #questsAndMilestonesModal .modal-window,
html[data-theme="glassmorphism"] body #farmListModal .modal-window,
html[data-theme="glassmorphism"] body #empireOverviewModal .modal-window,
html[data-theme="glassmorphism"] body #combatSimulatorModal .modal-window,
html[data-theme="glassmorphism"] body #gameWikiModal .modal-dark-card,
html[data-theme="glassmorphism"] body #diamondShopModal .modal-window,
html[data-theme="glassmorphism"] body #resourceProductionModal .res-prod-card,
html[data-theme="glassmorphism"] body div[id*="Modal"] > .modal-dark-card,
html[data-theme="glassmorphism"] body div[id*="Modal"] > .modal-window,
html[data-theme="glassmorphism"] body div[id$="Modal"] .modal-dark-card,
html[data-theme="glassmorphism"] body div[id$="Modal"] .modal-window,
html[data-theme="glassmorphism"] body div[id$="Modal"] > div:first-child:not(.modal-close-btn),
html[data-theme="glassmorphism"] body .modal-overlay > div:first-child,
html[data-theme="glassmorphism"] body .modal-backdrop > div:first-child {
  background-color: transparent !important;
  background-image:
    url('../../assets/ui/theme-glassmorphism/filigree-corner-tl.svg'),
    url('../../assets/ui/theme-glassmorphism/filigree-corner-tr.svg'),
    url('../../assets/ui/theme-glassmorphism/filigree-corner-bl.svg'),
    url('../../assets/ui/theme-glassmorphism/filigree-corner-br.svg'),
    url('../../assets/ui/theme-glassmorphism/filigree-crest-bottom.svg'),
    url('../../assets/ui/theme-glassmorphism/filigree-crest-top.svg'),
    linear-gradient(175deg, rgba(var(--panel-bg-top-rgb, 58, 76, 102), var(--panel-alpha, 0.75)) 0%, rgba(var(--panel-bg-bot-rgb, 36, 50, 72), var(--panel-alpha, 0.75)) 100%) !important;
  background-position:
    top 0 left 0,
    top 0 right 0,
    bottom 0 left 0,
    bottom 0 right 0,
    bottom -1px center,
    top -1px center,
    0 0 !important;
  background-size:
    44px 44px,
    44px 44px,
    44px 44px,
    44px 44px,
    80px 24px,
    120px 28px,
    auto !important;
  background-repeat: no-repeat !important;
  background-origin: border-box !important;
  background-clip: border-box !important;
  backdrop-filter: blur(var(--panel-blur, 14px)) saturate(130%) !important;
  -webkit-backdrop-filter: blur(var(--panel-blur, 14px)) saturate(130%) !important;
}

/* Compact Glassmorphism Popups & Tooltips (No Filigree Corner SVGs) */
html[data-theme="glassmorphism"] body .confirm-modal-card,
html[data-theme="glassmorphism"] body #troopHoverTooltip,
html[data-theme="glassmorphism"] body #quickTroopCard,
html[data-theme="glassmorphism"] body .troop-mini-modal {
  background: linear-gradient(175deg, rgba(var(--panel-bg-top-rgb, 58, 76, 102), var(--panel-alpha, 0.75)) 0%, rgba(var(--panel-bg-bot-rgb, 36, 50, 72), var(--panel-alpha, 0.75)) 100%) !important;
  backdrop-filter: blur(var(--panel-blur, 14px)) saturate(130%) !important;
  -webkit-backdrop-filter: blur(var(--panel-blur, 14px)) saturate(130%) !important;
}

/* 17.4 Inner Boxes, Resource Pills, City Rows, Troop Cards & Modal Sunken Wells */
html[data-theme]:not([data-theme="gokturk"]) body .top-mobile-resource-bar .inline-res-item:not(.res-diamond) {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  border-radius: 6px !important;
  padding: 1px 4px !important;
}

html[data-theme]:not([data-theme="gokturk"]) body .glass-sunken-well,
html[data-theme]:not([data-theme="gokturk"]) body .cost-res-well,
html[data-theme]:not([data-theme="gokturk"]) body .send-movement-troops-box,
html[data-theme]:not([data-theme="gokturk"]) body .well-card,
html[data-theme]:not([data-theme="gokturk"]) body .inner-panel,
html[data-theme]:not([data-theme="gokturk"]) body .modal-well,
html[data-theme]:not([data-theme="gokturk"]) body .bottom-troop-bar .troop-card-item:not(.locked),
html[data-theme]:not([data-theme="gokturk"]) body .troop-card-item:not(.locked),
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar .avatar-xp-badge,
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar .resource-row,
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar .cities-grid .city-btn:not(.active),
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar .cities-grid .city-card:not(.active),
html[data-theme]:not([data-theme="gokturk"]) body .right-sidebar .city-btn:not(.active),
html[data-theme]:not([data-theme="gokturk"]) body #settingsModal .modal-dark-card > div[style*="display:flex; flex-direction:column; gap:12px;"] > div:not(#settingsAmbassadorRow),
html[data-theme]:not([data-theme="gokturk"]) body #medreseResearchModal #medreseResearchesGrid > div,
html[data-theme]:not([data-theme="gokturk"]) body #cephaneArmoryModal .modal-body > div > div,
html[data-theme]:not([data-theme="gokturk"]) body .quest-item-card:not(.is-ready),
html[data-theme]:not([data-theme="gokturk"]) body #dailyQuestsListContainer > div:not([style*="34,197,94"]),
html[data-theme]:not([data-theme="gokturk"]) body #milestonesListContainer > div:not([style*="34,197,94"]),
html[data-theme]:not([data-theme="gokturk"]) body #farmListModal .farm-stamina-card,
html[data-theme]:not([data-theme="gokturk"]) body #farmListModal .farm-actions-bar,
html[data-theme]:not([data-theme="gokturk"]) body #empireOverviewModal .modal-body > div:first-child > div,
html[data-theme]:not([data-theme="gokturk"]) body #empireOverviewModal .overview-shared-pool-card,
html[data-theme]:not([data-theme="gokturk"]) body #empireOverviewModal .overview-military-card,
html[data-theme]:not([data-theme="gokturk"]) body #combatSimulatorModal .lock-calc-card,
html[data-theme]:not([data-theme="gokturk"]) body .rankings-table-wrapper,
html[data-theme]:not([data-theme="gokturk"]) body .wiki-card,
html[data-theme]:not([data-theme="gokturk"]) body .shop-shields-grid .shop-item-card,
html[data-theme]:not([data-theme="gokturk"]) body .report-box,
html[data-theme]:not([data-theme="gokturk"]) body .res-prod-table-container,
html[data-theme]:not([data-theme="gokturk"]) body #resourceProductionModal .res-prod-table-container,
html[data-theme]:not([data-theme="gokturk"]) body .mobile-drawer-item {
  background: rgba(var(--panel-well-rgb, 237, 227, 206), var(--panel-well-alpha, 0.72)) !important;
}

/* 17.5 Main Panel & Modal Text Contrast Adaptation (data-panel-tone="dark|light") */
html[data-theme][data-panel-tone="dark"] body .left-sidebar,
html[data-theme][data-panel-tone="dark"] body .left-sidebar .menu-item-btn span,
html[data-theme][data-panel-tone="dark"] body .right-sidebar,
html[data-theme][data-panel-tone="dark"] body .right-sidebar .logo-header .dirilis-logo-text,
html[data-theme][data-panel-tone="dark"] body .right-sidebar .logo-header .targun-logo-text,
html[data-theme][data-panel-tone="dark"] body .right-sidebar .panel-section-title,
html[data-theme][data-panel-tone="dark"] body .right-sidebar .event-circle-btn span:not(.event-badge),
html[data-theme][data-panel-tone="dark"] body .right-sidebar #sidebarTribeName,
html[data-theme][data-panel-tone="dark"] body .action-circle-btn span,
html[data-theme][data-panel-tone="dark"] body .modal-dark-card,
html[data-theme][data-panel-tone="dark"] body .modal-window,
html[data-theme][data-panel-tone="dark"] body .modal-dark-card h1,
html[data-theme][data-panel-tone="dark"] body .modal-dark-card h2,
html[data-theme][data-panel-tone="dark"] body .modal-dark-card h3:not(#modalTitle),
html[data-theme][data-panel-tone="dark"] body .modal-window h1,
html[data-theme][data-panel-tone="dark"] body .modal-window h2,
html[data-theme][data-panel-tone="dark"] body .modal-window h3:not(.modal-header-plaque),
html[data-theme][data-panel-tone="dark"] body .modal-dark-card p,
html[data-theme][data-panel-tone="dark"] body .modal-dark-card label,
html[data-theme][data-panel-tone="dark"] body .modal-window p,
html[data-theme][data-panel-tone="dark"] body .modal-window label,
html[data-theme][data-panel-tone="dark"] body #centerHudBar,
html[data-theme][data-panel-tone="dark"] body #btnCenterOwnVillage,
html[data-theme][data-panel-tone="dark"] body #btnVillageBackToMap,
html[data-theme][data-panel-tone="dark"] body #villageConstructionQueueBar span,
html[data-theme][data-panel-tone="dark"] body #villageConstructionQueueBar div {
  color: #f8fafc !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.65) !important;
}

html[data-theme][data-panel-tone="dark"] body .right-sidebar .player-subtitle,
html[data-theme][data-panel-tone="dark"] body .modal-header-subtitle {
  color: #cbd5e1 !important;
}

html[data-theme][data-panel-tone="light"] body .left-sidebar,
html[data-theme][data-panel-tone="light"] body .left-sidebar .menu-item-btn span,
html[data-theme][data-panel-tone="light"] body .right-sidebar,
html[data-theme][data-panel-tone="light"] body .right-sidebar .logo-header .dirilis-logo-text,
html[data-theme][data-panel-tone="light"] body .right-sidebar .logo-header .targun-logo-text,
html[data-theme][data-panel-tone="light"] body .right-sidebar .panel-section-title,
html[data-theme][data-panel-tone="light"] body .right-sidebar .event-circle-btn span:not(.event-badge),
html[data-theme][data-panel-tone="light"] body .right-sidebar #sidebarTribeName,
html[data-theme][data-panel-tone="light"] body .action-circle-btn span,
html[data-theme][data-panel-tone="light"] body .modal-dark-card,
html[data-theme][data-panel-tone="light"] body .modal-window,
html[data-theme][data-panel-tone="light"] body .modal-dark-card [style*="color:#fff"],
html[data-theme][data-panel-tone="light"] body .modal-dark-card [style*="color: #fff"],
html[data-theme][data-panel-tone="light"] body .modal-dark-card [style*="color:#f8fafc"],
html[data-theme][data-panel-tone="light"] body .modal-dark-card [style*="color:#e2e8f0"],
html[data-theme][data-panel-tone="light"] body .modal-window [style*="color:#fff"],
html[data-theme][data-panel-tone="light"] body .modal-window [style*="color:#f8fafc"],
html[data-theme][data-panel-tone="light"] body .modal-window [style*="color:#e2e8f0"],
html[data-theme][data-panel-tone="light"] body #centerHudBar,
html[data-theme][data-panel-tone="light"] body #btnCenterOwnVillage,
html[data-theme][data-panel-tone="light"] body #btnVillageBackToMap,
html[data-theme][data-panel-tone="light"] body #villageConstructionQueueBar span,
html[data-theme][data-panel-tone="light"] body #villageConstructionQueueBar div {
  color: #241a12 !important;
  text-shadow: none !important;
}

html[data-theme][data-panel-tone="light"] body .right-sidebar .player-subtitle,
html[data-theme][data-panel-tone="light"] body .modal-header-subtitle {
  color: #5c4530 !important;
}

/* 17.6 Inner Box & Row Text Contrast Adaptation (data-well-tone="dark|light") */
html[data-theme][data-well-tone="dark"] body .top-mobile-resource-bar .inline-res-item:not(.res-diamond):not(.res-gold) span:not(.res-buff-indicator),
html[data-theme][data-well-tone="dark"] body .right-sidebar .resource-label span:not(.res-buff-indicator),
html[data-theme][data-well-tone="dark"] body .right-sidebar .resource-val:not(#resGoldVal):not(#resIdleWorkersVal):not(#resDiamondsVal),
html[data-theme][data-well-tone="dark"] body .right-sidebar .cities-grid .city-btn:not(.active) .city-name,
html[data-theme][data-well-tone="dark"] body .right-sidebar .cities-grid .city-btn:not(.active) div,
html[data-theme][data-well-tone="dark"] body .right-sidebar .city-btn:not(.active) .city-name,
html[data-theme][data-well-tone="dark"] body .right-sidebar .city-btn:not(.active) div,
html[data-theme][data-well-tone="dark"] body .right-sidebar #xpValDisplay,
html[data-theme][data-well-tone="dark"] body .troop-card-item .troop-card-name,
html[data-theme][data-well-tone="dark"] body .wiki-card-title,
html[data-theme][data-well-tone="dark"] body .wiki-stat-val,
html[data-theme][data-well-tone="dark"] body .quest-item-card .quest-title,
html[data-theme][data-well-tone="dark"] body table tbody td,
html[data-theme][data-well-tone="dark"] body .imperial-row td,
html[data-theme][data-well-tone="dark"] body .mobile-drawer-item,
html[data-theme][data-well-tone="dark"] body .mobile-drawer-item span {
  color: #f8fafc !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.65) !important;
}

html[data-theme][data-well-tone="dark"] body .right-sidebar .avatar-xp-badge .xp-title,
html[data-theme][data-well-tone="dark"] body .right-sidebar .avatar-xp-badge #sidebarVillageTpName,
html[data-theme][data-well-tone="dark"] body .wiki-card-body,
html[data-theme][data-well-tone="dark"] body .quest-item-card .quest-desc {
  color: #cbd5e1 !important;
}

html[data-theme][data-well-tone="light"] body .top-mobile-resource-bar .inline-res-item:not(.res-diamond):not(.res-gold) span:not(.res-buff-indicator),
html[data-theme][data-well-tone="light"] body .right-sidebar .resource-label span:not(.res-buff-indicator),
html[data-theme][data-well-tone="light"] body .right-sidebar .resource-val:not(#resGoldVal):not(#resIdleWorkersVal):not(#resDiamondsVal),
html[data-theme][data-well-tone="light"] body .right-sidebar .cities-grid .city-btn:not(.active) .city-name,
html[data-theme][data-well-tone="light"] body .right-sidebar .cities-grid .city-btn:not(.active) div,
html[data-theme][data-well-tone="light"] body .right-sidebar .city-btn:not(.active) .city-name,
html[data-theme][data-well-tone="light"] body .right-sidebar .city-btn:not(.active) div,
html[data-theme][data-well-tone="light"] body .right-sidebar #xpValDisplay,
html[data-theme][data-well-tone="light"] body .troop-card-item .troop-card-name,
html[data-theme][data-well-tone="light"] body .wiki-card-title,
html[data-theme][data-well-tone="light"] body .wiki-stat-val,
html[data-theme][data-well-tone="light"] body .quest-item-card .quest-title,
html[data-theme][data-well-tone="light"] body table tbody td,
html[data-theme][data-well-tone="light"] body .imperial-row td,
html[data-theme][data-well-tone="light"] body .mobile-drawer-item,
html[data-theme][data-well-tone="light"] body .mobile-drawer-item span {
  color: #241a12 !important;
  text-shadow: none !important;
}

html[data-theme][data-well-tone="light"] body .right-sidebar .avatar-xp-badge .xp-title,
html[data-theme][data-well-tone="light"] body .right-sidebar .avatar-xp-badge #sidebarVillageTpName,
html[data-theme][data-well-tone="light"] body .wiki-card-body,
html[data-theme][data-well-tone="light"] body .quest-item-card .quest-desc {
  color: #5c4530 !important;
}

/* 17.7 Compact Resource Buff Indicator Badges (+%20) in Top Bar & Right Sidebar (~30% Smaller) */
html[data-theme] body .top-mobile-resource-bar .res-buff-indicator,
html[data-theme] body .top-mobile-resource-bar .res-buff-indicator.top-bar-buff {
  font-size: 6.5px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  padding: 1px 2.5px !important;
  border-radius: 3px !important;
  margin-left: 1px !important;
}

html[data-theme] body .right-sidebar .res-buff-indicator,
html[data-theme] body .right-sidebar .res-buff-indicator.side-bar-buff {
  font-size: 7px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  padding: 1px 3px !important;
  border-radius: 3px !important;
  margin-left: 4px !important;
}

/* 17.8 Mobile Hybrid Landscape Overrides for Top Resource Bar & Buff Badges */
html.mobile-landscape-mode[data-theme] body .top-mobile-resource-bar .inline-res-item:not(.res-diamond),
html.mobile-landscape-mode[data-theme] body .top-mobile-resource-bar .inline-res-item.res-diamond {
  padding: 1px 3px !important;
  height: 18px !important;
  min-height: 18px !important;
  font-size: 9.5px !important;
}

html.mobile-landscape-mode[data-theme] body .top-mobile-resource-bar .res-buff-indicator,
html.mobile-landscape-mode[data-theme] body .top-mobile-resource-bar .res-buff-indicator.top-bar-buff {
  display: none !important;
}

/* 17.9 Unified Sidebar & Vertical Chat Tabs (10px) and Bottom Troop Bar (11px) Typography (Web & Mobile) */
html[data-theme] body .left-sidebar .menu-item-btn,
html[data-theme] body .left-sidebar .menu-item-btn span:not(.item-icon):not(.event-badge) {
  font-size: 10px !important;
  font-weight: 500 !important;
}

html[data-theme] body .right-sidebar .event-circle-btn span:not(.event-badge) {
  font-size: 10px !important;
  font-weight: 500 !important;
}

html[data-theme] body .right-sidebar .event-circle-btn.has-notification,
html[data-theme] body #sidebarReportsBtn.has-notification,
html[data-theme] body #sidebarMessagesBtn.has-notification {
  background: linear-gradient(180deg, #f97316 0%, #ea580c 100%) !important;
  border: 1.5px solid #fdba74 !important;
  border-radius: 8px !important;
  box-shadow: 0 0 14px rgba(249, 115, 22, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.4) !important;
}
html[data-theme] body .left-sidebar .quick-village-btn,
html[data-theme] body .left-sidebar .quick-village-btn #quickToggleLabel,
html[data-theme] body .left-sidebar .btn-sidebar-logout,
html[data-theme] body .right-chat-tabs .chat-tab-vertical,
html[data-theme] body .right-chat-tabs .chat-tab-vertical span,
html[data-theme] body .right-sidebar .player-subtitle,
html[data-theme] body .right-sidebar .player-subtitle span,
html[data-theme] body .right-sidebar #sidebarPlayerName,
html[data-theme] body .right-sidebar #sidebarTribeName,
html[data-theme] body .right-sidebar .avatar-xp-badge .xp-title,
html[data-theme] body .right-sidebar .avatar-xp-badge .xp-val,
html[data-theme] body .right-sidebar #xpValDisplay,
html[data-theme] body .right-sidebar #sidebarVillageTpLabel,
html[data-theme] body .right-sidebar #sidebarVillageTpName,
html[data-theme] body .right-sidebar #sidebarVillageTpRatio,
html[data-theme] body .right-sidebar .panel-section-title,
html[data-theme] body .right-sidebar .panel-section-title span,
html[data-theme] body .right-sidebar .shield-table-pill,
html[data-theme] body .right-sidebar .shield-table-pill span,
html[data-theme] body .right-sidebar .resource-row,
html[data-theme] body .right-sidebar .resource-row .resource-label,
html[data-theme] body .right-sidebar .resource-row .resource-label span:not(.res-buff-indicator),
html[data-theme] body .right-sidebar .resource-row .resource-val,
html[data-theme] body .right-sidebar .resource-row .resource-val span:not(.res-buff-indicator),
html[data-theme] body .right-sidebar .cities-grid .city-btn,
html[data-theme] body .right-sidebar .cities-grid .city-btn div,
html[data-theme] body .right-sidebar .cities-grid .city-btn span,
html[data-theme] body .right-sidebar .cities-grid .city-btn .city-name,
html[data-theme] body .right-sidebar .event-circle-btn span:not(.event-badge) {
  font-size: 10px !important;
}

html[data-theme] body .bottom-troop-bar .troop-card-name,
html[data-theme] body .bottom-troop-bar .troop-card-item:not(.locked) .troop-card-name,
html[data-theme] body .bottom-troop-bar .troop-card-item.locked .troop-card-name,
html[data-theme] body .bottom-troop-bar .troop-card-count-badge {
  font-size: 11px !important;
}




