/* ============================================================
   Realm Foundry — Shared Styles
   ============================================================ */

/* --- Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@500;700&family=Inter:wght@300;400;600&display=swap');

/* --- Theme Variables (Gold / Bronze default) --- */
:root {
  --bg:       #0c0a08;
  --bg2:      #100e0a;
  --panel:    rgba(20, 16, 10, 0.75);
  --panel2:   rgba(14, 12, 8, 0.72);
  --text:     #ede8df;
  --muted:    #c4b99a;
  --accent:   #d4a020;
  --accent2:  #f0d060;
  --bronze:   #a67c2e;
  --stroke:   rgba(255, 255, 255, 0.08);
  --shadow:   rgba(0, 0, 0, 0.55);
  --max:      1120px;
  --radius:   18px;
}

/* --- Reset --- */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; height: auto; }

/* --- Layout --- */
.wrap {
  width: min(var(--max), calc(100% - 40px));
  margin: 0 auto;
}

/* --- Header / Nav --- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(12, 10, 8, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--stroke);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  font-family: Cinzel, serif;
  font-size: 15px;
}

.brand img {
  height: 32px;
  width: auto;
}

.site-nav {
  display: flex;
  gap: 4px;
  align-items: center;
  font-size: 14px;
  color: var(--muted);
}

.site-nav > a,
.site-nav .nav-dropdown > .nav-trigger {
  padding: 8px 12px;
  border-radius: 10px;
  transition: all 0.15s ease;
  cursor: pointer;
  background: none;
  border: none;
  color: var(--muted);
  font: inherit;
  font-size: 14px;
}

.site-nav > a:hover,
.site-nav .nav-dropdown:hover > .nav-trigger {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
}

.site-nav > a.active {
  color: var(--accent);
}

/* Dropdown */
.nav-dropdown {
  position: relative;
}

.nav-trigger {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.nav-trigger .chevron {
  font-size: 10px;
  transition: transform 0.2s ease;
}

.nav-dropdown:hover .chevron {
  transform: rotate(180deg);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  min-width: 200px;
  background: rgba(16, 14, 10, 0.96);
  backdrop-filter: blur(14px);
  border: 1px solid var(--stroke);
  border-radius: 14px;
  padding: 8px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(6px);
  transition: all 0.2s ease;
}

.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.dropdown-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 14px;
  color: var(--muted);
  transition: all 0.15s ease;
  white-space: nowrap;
}

.dropdown-menu a:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
}

.dropdown-menu a .class-pip {
  width: 8px;
  height: 8px;
  border-radius: 99px;
  flex-shrink: 0;
}

.dropdown-menu a .coming-soon {
  margin-left: auto;
  font-size: 11px;
  color: rgba(196, 185, 154, 0.5);
  font-style: italic;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: rgba(255, 255, 255, 0.04);
  transition: all 0.2s ease;
  font-weight: 600;
  color: var(--text);
  font-size: 14px;
  cursor: pointer;
  text-decoration: none;
}

.btn:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.07);
}

.btn.primary {
  border-color: rgba(212, 160, 32, 0.5);
  background: linear-gradient(180deg, rgba(212, 160, 32, 0.30), rgba(212, 160, 32, 0.12));
  box-shadow: 0 16px 40px rgba(212, 160, 32, 0.15);
}

.btn.primary:hover {
  box-shadow: 0 20px 50px rgba(212, 160, 32, 0.25);
}

/* --- Section Layout --- */
section {
  padding: 80px 0;
}

.section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 22px;
}

.section-title h2 {
  margin: 0;
  font-family: Cinzel, serif;
  letter-spacing: 0.06em;
  font-size: 28px;
}

.section-title span {
  color: var(--muted);
  font-size: 14px;
}

/* --- Cards & Tiles --- */
.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.tile {
  background: linear-gradient(180deg, var(--panel2), rgba(14, 12, 8, 0.55));
  border: 1px solid var(--stroke);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
}

.tile h3 {
  margin: 0 0 8px;
  font-family: Cinzel, serif;
  letter-spacing: 0.06em;
  font-size: 17px;
}

.tile p {
  margin: 0;
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}

.badge {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--accent2);
  background: rgba(212, 160, 32, 0.10);
  border: 1px solid rgba(212, 160, 32, 0.25);
  padding: 5px 10px;
  border-radius: 999px;
  margin-bottom: 12px;
}

/* --- Footer --- */
.site-footer {
  padding: 32px 0 40px;
  color: rgba(237, 232, 223, 0.5);
  font-size: 13px;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.2);
}

.site-footer a {
  color: var(--accent);
  transition: color 0.15s ease;
}

.site-footer a:hover {
  color: var(--accent2);
}

/* --- Responsive --- */
@media (max-width: 920px) {
  .grid3 { grid-template-columns: 1fr; }
  .site-nav { display: none; }
  section { padding: 50px 0; }
}
