/* ==========================================================================
   Thalion Software Fan Page — css/style.css
   Visual identity: epic fantasy codex — Cinzel headings, copper-gold accent
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;700&family=Source+Sans+3:wght@400;500;600&display=swap');

[hidden] { display: none !important; }

/* --------------------------------------------------------------------------
   Custom Properties
   -------------------------------------------------------------------------- */
:root {
  --bg:            #1a1f2e;
  --bg-card:       #252a3a;
  --bg-card-alt:   #2c3145;
  --bg-nav:        rgba(26,31,46,0.97);
  --border:        #343a50;

  --text:          #e0ddd6;
  --text-muted:    #8a8fa8;
  --text-dim:      #5a6080;

  --accent:        #c8833a;
  --accent-light:  #e09a52;
  --accent-dark:   #a06828;

  --font-display:  'Cinzel', Georgia, serif;
  --font-body:     'Source Sans 3', system-ui, sans-serif;

  --nav-height:     64px;
  --container-max:  1200px;
  --radius:         4px;
}

/* --------------------------------------------------------------------------
   Reset & Base
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.8;
  overflow-x: hidden;
}

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

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s;
}

a:hover,
a:focus {
  color: var(--accent-light);
  outline: none;
}

ul, ol {
  list-style: none;
}

/* --------------------------------------------------------------------------
   Typography
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.04em;
  color: var(--text);
}

h1 { font-size: clamp(2rem, 6vw, 3.5rem); }
h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); }
h3 { font-size: clamp(1.2rem, 3vw, 1.8rem); }
h4 { font-size: clamp(1rem, 2vw, 1.3rem); }
h5 { font-size: 1rem; }

p {
  font-family: var(--font-body);
  font-size: clamp(0.95rem, 1.5vw, 1.05rem);
  margin-bottom: 1.2rem;
  line-height: 1.8;
}

/* --------------------------------------------------------------------------
   Container
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* --------------------------------------------------------------------------
   Skip link
   -------------------------------------------------------------------------- */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--accent);
  color: #fff;
  padding: 0.5rem 1rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  z-index: 999;
  transition: top 0.2s;
}

.skip-link:focus {
  top: 0;
}

/* --------------------------------------------------------------------------
   Navigation
   -------------------------------------------------------------------------- */
#site-nav {
  visibility: hidden;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-height);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  background: var(--bg-nav);
  backdrop-filter: blur(8px);
}

#site-nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.nav-logo {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.08em;
  color: var(--accent);
  text-transform: uppercase;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  gap: 0.1rem;
  flex-wrap: wrap;
}

.nav-links a {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 0.4rem 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  transition: color 0.2s;
  border-radius: var(--radius);
}

.nav-links a:hover,
.nav-links a:focus,
.nav-links a.active {
  color: var(--accent);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  transition: background 0.2s;
}

@media (max-width: 900px) {
  .nav-toggle {
    display: flex;
  }
  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--bg-nav);
    border-top: 1px solid var(--border);
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 0;
  }
  .nav-links.open {
    display: flex;
  }
  .nav-links a {
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--border);
  }
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--nav-height) + 2rem) 1.5rem 4rem;
  background:
    linear-gradient(180deg, rgba(26,31,46,0.4) 0%, rgba(26,31,46,0.95) 100%),
    var(--bg);
  position: relative;
  overflow: hidden;
}

#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 50% at 50% 40%, rgba(200,131,58,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center top;
  opacity: 0.25;
  filter: sepia(0.4) brightness(0.7);
}

.hero-content {
  max-width: 760px;
  position: relative;
}

.hero-eyebrow {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.8rem, 8vw, 5rem);
  letter-spacing: 0.12em;
  color: var(--text);
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1rem, 2.5vw, 1.4rem);
  color: var(--accent-light);
  letter-spacing: 0.08em;
  margin-bottom: 1.5rem;
}

.hero-tagline {
  color: var(--text-muted);
  font-size: clamp(0.95rem, 1.8vw, 1.1rem);
  margin-bottom: 2.5rem;
}

.hero-stats {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}

.hero-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-stat .num {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  color: var(--accent);
  line-height: 1;
}

.hero-stat .label {
  font-family: var(--font-body);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.4rem;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */
.btn {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.7rem 1.8rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  display: inline-block;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-primary:hover,
.btn-primary:focus {
  background: var(--accent-light);
  border-color: var(--accent-light);
  color: #fff;
}

.btn-secondary {
  background: transparent;
  color: var(--accent);
  border-color: var(--accent);
}

.btn-secondary:hover,
.btn-secondary:focus {
  background: rgba(200,131,58,0.1);
  color: var(--accent-light);
}

/* --------------------------------------------------------------------------
   Page header (for inner pages)
   -------------------------------------------------------------------------- */
.page-header {
  padding: calc(var(--nav-height) + 3rem) 1.5rem 3rem;
  text-align: center;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4rem;
}

.page-header .eyebrow {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
  display: block;
}

.page-header h1 {
  margin-bottom: 1rem;
}

.page-header .lead {
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
  font-size: clamp(1rem, 2vw, 1.15rem);
}

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */
.site-section {
  padding: 4rem 0;
}

.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-label {
  display: block;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.section-title {
  margin-bottom: 1rem;
}

.section-subtitle {
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   Cards
   -------------------------------------------------------------------------- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1.5rem;
  overflow: hidden;
  transition: border-color 0.2s;
}

.card:hover {
  border-top-color: var(--accent-light);
}

.card-img {
  display: block;
  width: calc(100% + 3rem);
  margin: -1.5rem -1.5rem 1.25rem;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: var(--bg-card-alt);
}

.card-img-contain {
  object-fit: contain;
}

.card-title {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.card-meta {
  font-family: var(--font-body);
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 0.75rem;
}

.card-body {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* --------------------------------------------------------------------------
   Grids
   -------------------------------------------------------------------------- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

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

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .grid-3, .grid-2, .grid-4 { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   Platform badges
   -------------------------------------------------------------------------- */
.badge {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 2px;
  border: 1px solid currentColor;
  line-height: 1;
}

.badge-amiga  { color: #e8a44a; border-color: rgba(232,164,74,0.4); }
.badge-st     { color: #7ab8e8; border-color: rgba(122,184,232,0.4); }
.badge-dos    { color: #90c878; border-color: rgba(144,200,120,0.4); }

/* --------------------------------------------------------------------------
   Platform filter
   -------------------------------------------------------------------------- */
.filter-bar {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2rem;
}

.filter-btn {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.4rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.filter-btn:hover,
.filter-btn.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(200,131,58,0.08);
}

/* --------------------------------------------------------------------------
   Gallery
   -------------------------------------------------------------------------- */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}

.gallery-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s;
}

.gallery-card:hover {
  transform: translateY(-2px);
}

.gallery-card img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  background: var(--bg-card-alt);
}

.gallery-card-body {
  padding: 1rem;
}

.gallery-card-title {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text);
  margin-bottom: 0.4rem;
}

.gallery-card-caption {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   Table
   -------------------------------------------------------------------------- */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.data-table th {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 2px solid var(--accent);
  background: var(--bg-card);
}

.data-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  vertical-align: top;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background: rgba(255,255,255,0.02);
  color: var(--text);
}

.data-table .td-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text);
  letter-spacing: 0.03em;
}

/* --------------------------------------------------------------------------
   People profiles
   -------------------------------------------------------------------------- */
.person-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 2rem;
}

.person-name {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 0.35rem;
}

.person-role {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.person-bio {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.8;
}

/* --------------------------------------------------------------------------
   Editorial / flagship-style long-form
   -------------------------------------------------------------------------- */
.editorial {
  max-width: 760px;
  margin: 0 auto;
}

.editorial h2:not(.timeline-heading) {
  margin-top: 3rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.editorial h3 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  color: var(--accent);
}

.editorial p {
  color: var(--text-muted);
}

.editorial a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* --------------------------------------------------------------------------
   Review quotes
   -------------------------------------------------------------------------- */
.review-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 1.5rem 1.75rem;
  margin-bottom: 1.5rem;
}

.review-quote {
  font-family: var(--font-body);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--text);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.review-meta {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.review-score {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  float: right;
}

/* --------------------------------------------------------------------------
   Resources / links list
   -------------------------------------------------------------------------- */
.resource-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.resource-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.resource-item a {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
}

.resource-item a:hover {
  color: var(--accent);
}

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

/* --------------------------------------------------------------------------
   Music page
   -------------------------------------------------------------------------- */
.music-entry {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1rem;
}

.music-title {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text);
  margin-bottom: 0.3rem;
}

.music-meta {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 0.75rem;
}

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

.video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: var(--radius);
  margin: 1.5rem 0;
  background: #000;
}

.video-embed iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: none;
}

/* --------------------------------------------------------------------------
   Scroll reveal
   -------------------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------------------------
   Easter egg modal
   -------------------------------------------------------------------------- */
#easter-egg-modal {
  position: fixed;
  inset: 0;
  background: rgba(26,31,46,0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 500;
  backdrop-filter: blur(4px);
}

.easter-egg-box {
  background: var(--bg-card);
  border: 2px solid var(--accent);
  border-radius: var(--radius);
  padding: 3rem 2.5rem;
  max-width: 480px;
  text-align: center;
}

.easter-egg-box h2 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--accent);
  margin-bottom: 1rem;
  letter-spacing: 0.1em;
}

.easter-egg-box p {
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.easter-egg-close {
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.5rem 1.5rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
}

/* --------------------------------------------------------------------------
   History timeline
   -------------------------------------------------------------------------- */
.timeline {
  position: relative;
  padding-left: 2rem;
  border-left: 2px solid var(--border);
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0; left: -1px;
  width: 2px;
  height: 100%;
}

.timeline-entry {
  position: relative;
  margin-bottom: 2.5rem;
}

.timeline-entry::before {
  content: '';
  position: absolute;
  left: -2.6rem;
  top: 0.35rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
}

.timeline-year {
  font-family: var(--font-display);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 0.3rem;
}

.timeline-heading {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.timeline-body {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.8;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
#site-footer {
  border-top: 1px solid var(--border);
  padding: 3rem 0;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  font-family: var(--font-body);
}

#site-footer a {
  color: var(--text-muted);
}

#site-footer a:hover {
  color: var(--accent);
}

.footer-note {
  margin-top: 0.5rem;
  font-size: 0.75rem;
}
