/*
Theme Name: Fivem City Theme
Theme URI: https://example.com/
Author: Perplexity
Description: Dark urban fantasy WordPress theme for a FiveM/QBX server with fully editable homepage blocks.
Version: 1.2.0
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: fivem-city-theme
*/

:root {
  --bg: #090b11;
  --bg-2: #0f1320;
  --panel: rgba(15, 19, 32, 0.82);
  --panel-2: rgba(20, 25, 40, 0.92);
  --text: #eef2ff;
  --muted: #9aa3bd;
  --accent: #7c4dff;
  --accent-2: #3be0d0;
  --accent-3: #cf7bff;
  --border: rgba(151, 126, 255, 0.18);
  --shadow: 0 18px 60px rgba(0,0,0,.45);
  --radius: 22px;
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(124,77,255,.14), transparent 28%),
    radial-gradient(circle at top right, rgba(59,224,208,.10), transparent 24%),
    linear-gradient(180deg, #07090f 0%, #0b1020 100%);
  line-height: 1.6;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { width: min(var(--container), calc(100% - 32px)); margin: 0 auto; }
.site-header {
  position: sticky; top: 0; z-index: 30;
  background: rgba(8, 10, 18, .75);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.header-row {
  min-height: 78px; display: flex; justify-content: space-between; align-items: center; gap: 20px;
}
.brand { display: flex; align-items: center; gap: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 14px;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  color: #060812; display: grid; place-items: center; font-weight: 900;
  box-shadow: 0 0 20px rgba(124,77,255,.35);
}
.main-nav ul { list-style: none; display: flex; gap: 20px; margin: 0; padding: 0; flex-wrap: wrap; }
.main-nav a { color: var(--muted); }
.main-nav a:hover, .main-nav .current-menu-item > a { color: var(--text); }
.header-cta a,
.btn {
  display: inline-flex; align-items: center; justify-content: center; border-radius: 999px;
  font-weight: 700; transition: .2s ease; padding: 13px 20px;
}
.header-cta a, .btn-primary {
  background: linear-gradient(135deg, var(--accent-2), var(--accent));
  color: #071019;
  box-shadow: 0 10px 24px rgba(59,224,208,.18);
}
.btn-secondary {
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.04);
  color: var(--text);
}
.hero {
  position: relative;
  padding: 76px 0 56px;
}
.hero-shell {
  position: relative;
  border: 1px solid var(--border);
  border-radius: 34px;
  overflow: hidden;
  box-shadow: var(--shadow);
  min-height: 640px;
  background:
    linear-gradient(90deg, rgba(164,198,232,.22) 0%, rgba(164,198,232,.08) 46%, rgba(124,77,255,.05) 47%, rgba(124,77,255,.18) 100%),
    linear-gradient(180deg, rgba(5,7,12,.30), rgba(5,7,12,.72));
}
.hero-worlds {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg,
      rgba(151, 194, 232, .95) 0%,
      rgba(116, 162, 201, .80) 22%,
      rgba(18, 24, 38, .35) 46%,
      rgba(20, 18, 38, .78) 54%,
      rgba(15, 12, 28, .94) 100%),
    radial-gradient(circle at 75% 20%, rgba(59,224,208,.20), transparent 18%),
    radial-gradient(circle at 82% 32%, rgba(207,123,255,.18), transparent 16%),
    linear-gradient(180deg, rgba(8,9,15,0) 0%, rgba(8,9,15,.32) 58%, rgba(8,9,15,.92) 100%);
}
.hero-worlds::before {
  content: '';
  position: absolute; inset: 0 52% 0 0;
  background: linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,.02));
}
.hero-worlds::after {
  content: '';
  position: absolute; top: -4%; bottom: -4%; left: 50%; width: 8px;
  transform: translateX(-50%) rotate(4deg);
  background: linear-gradient(180deg, rgba(244,226,255,.95), rgba(141,92,255,.88));
  box-shadow: 0 0 28px rgba(171,112,255,.8), 0 0 56px rgba(90,60,255,.45);
  border-radius: 999px;
}
.hero-content {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: 1.1fr .9fr; gap: 28px;
  align-items: end;
  min-height: 640px;
  padding: 44px;
}
.hero-copy {
  align-self: center;
  max-width: 700px;
}
.hero-kicker {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 9px 14px; border-radius: 999px;
  background: rgba(8, 12, 22, .55); border: 1px solid rgba(255,255,255,.08);
  color: #ccd4ef; font-size: 13px; letter-spacing: .08em; text-transform: uppercase;
}
.hero-copy h1 {
  margin: 18px 0 16px;
  font-size: clamp(40px, 6vw, 78px);
  line-height: .98;
  max-width: 9.5ch;
}
.hero-copy p {
  margin: 0 0 28px;
  font-size: 18px;
  color: #d7def3;
  max-width: 62ch;
}
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-panel {
  align-self: end;
  background: linear-gradient(180deg, rgba(15,19,32,.82), rgba(9,11,18,.92));
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 28px;
  padding: 24px;
  backdrop-filter: blur(14px);
}
.hero-panel h3 { margin: 0 0 10px; font-size: 24px; }
.hero-panel p { margin: 0 0 16px; color: var(--muted); }
.ip-box, .feature-card, .news-card, .lore-card, .stat-card, .page-card {
  border: 1px solid rgba(255,255,255,.08);
  background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.02));
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.ip-box {
  padding: 16px 18px; margin-bottom: 14px;
  font-weight: 700; color: #eff5ff;
  background: rgba(7,10,18,.8);
}
.section { padding: 34px 0 72px; }
.section-heading { margin-bottom: 26px; }
.section-heading h2 { font-size: clamp(28px, 4vw, 46px); margin: 0 0 10px; }
.section-heading p { margin: 0; color: var(--muted); max-width: 760px; }
.stats-grid, .features-grid, .lore-grid, .news-grid {
  display: grid; gap: 18px;
}
.stats-grid { grid-template-columns: repeat(4, 1fr); }
.features-grid { grid-template-columns: repeat(3, 1fr); }
.lore-grid { grid-template-columns: repeat(2, 1fr); }
.news-grid { grid-template-columns: repeat(3, 1fr); }
.stat-card, .feature-card, .lore-card, .news-card, .page-card { padding: 24px; }
.stat-card strong {
  display: block; font-size: 34px; margin-bottom: 8px;
  background: linear-gradient(135deg, #f0f3ff 0%, #8fe5ff 42%, #d591ff 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.feature-card h3, .lore-card h3, .news-card h3 { margin-top: 0; }
.feature-card p, .lore-card p, .news-card p, .stat-card span { color: var(--muted); }
.news-card time { color: #8d98ba; font-size: 14px; }
.content-wrap { padding: 42px 0 72px; }
.footer {
  border-top: 1px solid rgba(255,255,255,.06);
  padding: 28px 0 40px; color: var(--muted);
}
.footer-row { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
@media (max-width: 980px) {
  .hero-content, .stats-grid, .features-grid, .news-grid, .lore-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .header-row { flex-direction: column; align-items: flex-start; padding: 16px 0; }
  .hero-shell, .hero-content { min-height: auto; }
  .hero-content, .stats-grid, .features-grid, .news-grid, .lore-grid { grid-template-columns: 1fr; }
  .hero-content { padding: 26px; }
  .hero-copy p { font-size: 16px; }
}

.hero-worlds.has-images {
  background-size: 50% 100%, 50% 100%;
  background-position: left center, right center;
  background-repeat: no-repeat, no-repeat;
}
.hero-worlds.has-images::before { background: linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.02)); }
.lore-card img {
  width: 100%;
  height: 240px;
  object-fit: cover;
  border-radius: 16px;
  margin-bottom: 18px;
  border: 1px solid rgba(255,255,255,.08);
}

.hero-shell::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 72% 24%, rgba(59, 224, 208, 0.14), transparent 20%),
    linear-gradient(180deg, rgba(98, 62, 158, 0.08), rgba(8, 10, 18, 0.34));
  opacity: 0;
  transition: opacity .8s ease;
  pointer-events: none;
  z-index: 1;
}
.hero-normal,
.hero-sumrak {
  position: absolute;
  inset: 0;
  transition: opacity .9s ease, filter .9s ease, transform .9s ease;
}
.hero-normal {
  z-index: 0;
  opacity: 1;
}
.hero-sumrak {
  z-index: 0;
  opacity: 0;
  filter: saturate(.6) brightness(.78) contrast(1.05) blur(1px);
  transform: scale(1.02);
}
.hero-shell.sumrak-active .hero-normal {
  opacity: .16;
  filter: saturate(.65) blur(.5px);
}
.hero-shell.sumrak-active .hero-sumrak {
  opacity: 1;
  filter: saturate(.85) brightness(.88) contrast(1.08) blur(.2px);
  transform: scale(1);
}
.hero-shell.sumrak-active::after {
  opacity: 1;
}
.sumrak-toggle-wrap {
  margin-top: 16px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.sumrak-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  color: var(--text);
  font-weight: 700;
  cursor: pointer;
}
.sumrak-toggle.is-active {
  background: linear-gradient(135deg, rgba(124,77,255,.92), rgba(59,224,208,.85));
  color: #091019;
}

.hero-copy [data-hero-normal],
.hero-copy [data-hero-sumrak],
.hero-panel [data-panel-normal],
.hero-panel [data-panel-sumrak] {
  transition: opacity .45s ease, transform .45s ease;
}
.hero-copy [data-hero-sumrak],
.hero-panel [data-panel-sumrak] {
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  position: absolute;
  inset: auto 0 auto 0;
}
.hero-copy { position: relative; }
.hero-panel { position: relative; min-height: 280px; }
.hero-shell.sumrak-active .hero-copy [data-hero-normal],
.hero-shell.sumrak-active .hero-panel [data-panel-normal] {
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
}
.hero-shell.sumrak-active .hero-copy [data-hero-sumrak],
.hero-shell.sumrak-active .hero-panel [data-panel-sumrak] {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}


.hero-copy [data-hero-normal],
.hero-copy [data-hero-sumrak] { display: block; }
.hero-copy [data-hero-sumrak] { position: absolute; top: 0; left: 0; right: 0; }
.hero-panel [data-panel-normal],
.hero-panel [data-panel-sumrak] { display: block; }
.hero-panel [data-panel-sumrak] { position: absolute; inset: 0; }
.hero-copy [data-hero-sumrak],
.hero-panel [data-panel-sumrak] {
  visibility: hidden;
}
.hero-shell.sumrak-active .hero-copy [data-hero-normal],
.hero-shell.sumrak-active .hero-panel [data-panel-normal] {
  visibility: hidden;
}
.hero-shell.sumrak-active .hero-copy [data-hero-sumrak],
.hero-shell.sumrak-active .hero-panel [data-panel-sumrak] {
  visibility: visible;
}


.hero-content { position: relative; z-index: 3; }
.hero-copy { position: relative; min-height: 270px; }
.hero-copy [data-hero-normal],
.hero-copy [data-hero-sumrak] {
  width: 100%;
}
.hero-copy [data-hero-normal] {
  position: relative;
  z-index: 2;
}
.hero-copy [data-hero-sumrak] {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 3;
  opacity: 0;
  visibility: hidden;
}
.hero-panel { position: relative; min-height: 320px; }
.hero-panel [data-panel-normal] {
  position: relative;
  z-index: 2;
}
.hero-panel [data-panel-sumrak] {
  position: absolute;
  inset: 0;
  z-index: 3;
  opacity: 0;
  visibility: hidden;
}
.hero-shell.sumrak-active .hero-copy [data-hero-normal],
.hero-shell.sumrak-active .hero-panel [data-panel-normal] {
  opacity: 0 !important;
  visibility: hidden !important;
}
.hero-shell.sumrak-active .hero-copy [data-hero-sumrak],
.hero-shell.sumrak-active .hero-panel [data-panel-sumrak] {
  opacity: 1 !important;
  visibility: visible !important;
}

.hero-shell.sumrak-active .hero-normal { opacity: .08 !important; }
.hero-shell.sumrak-active .hero-sumrak { opacity: 1 !important; }

.hero-shell { overflow: hidden; }
.hero-normal { z-index: 0; opacity: 1; }
.hero-sumrak { z-index: 0; opacity: 0; }
.hero-content { position: relative; z-index: 3; }
.hero-shell.sumrak-active .hero-normal { opacity: .08 !important; }
.hero-shell.sumrak-active .hero-sumrak { opacity: 1 !important; }

.hero-shell { position: relative; overflow: hidden; isolation: isolate; }
.hero-worlds { position: absolute; inset: 0; background-repeat: no-repeat; background-size: cover; background-position: center; }
.hero-normal { z-index: 0; opacity: 1; visibility: visible; }
.hero-sumrak { z-index: 1; opacity: 0 !important; visibility: hidden !important; pointer-events: none; }
.hero-content { position: relative; z-index: 3; }
.hero-shell.sumrak-active .hero-normal { opacity: 1 !important; visibility: visible !important; }
.hero-shell.sumrak-active .hero-sumrak { opacity: 1 !important; visibility: visible !important; }
