/* ============================================
   TRILLY GOLF · TRILLY TEE — DESIGN SYSTEM
   Alcatraz Flagship Authority Course
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;500;600;700;800;900&family=Cinzel+Decorative:wght@400;700;900&family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400&family=Rajdhani:wght@300;400;500;600;700&display=swap');

/* ── CSS Custom Properties ── */
:root {
  /* Core Colors */
  --bg-primary: #060a14;
  --bg-secondary: #0a0e1a;
  --bg-tertiary: #0d1220;
  --bg-panel: rgba(12, 17, 30, 0.85);
  --bg-panel-solid: #0c111e;
  --bg-card: rgba(15, 21, 38, 0.9);
  --bg-card-hover: rgba(20, 28, 48, 0.95);

  /* Gold Palette */
  --gold-primary: #c9a84c;
  --gold-light: #e4cc7a;
  --gold-bright: #d4af37;
  --gold-dim: #8b7632;
  --gold-dark: #5a4e24;
  --gold-muted: rgba(201, 168, 76, 0.3);
  --gold-glow: rgba(201, 168, 76, 0.15);
  --gold-border: rgba(201, 168, 76, 0.25);
  --gold-border-bright: rgba(201, 168, 76, 0.5);

  /* Text Colors */
  --text-primary: #e8e0d0;
  --text-secondary: rgba(232, 224, 208, 0.7);
  --text-tertiary: rgba(232, 224, 208, 0.45);
  --text-gold: #c9a84c;
  --text-gold-bright: #e4cc7a;

  /* Status Colors */
  --status-active: #4ade80;
  --status-warning: #fbbf24;
  --status-optimal: #34d399;

  /* Borders */
  --border-subtle: rgba(201, 168, 76, 0.12);
  --border-medium: rgba(201, 168, 76, 0.25);
  --border-bright: rgba(201, 168, 76, 0.45);

  /* Shadows & Glows */
  --shadow-gold: 0 0 30px rgba(201, 168, 76, 0.1);
  --shadow-gold-intense: 0 0 60px rgba(201, 168, 76, 0.2);
  --glow-gold: 0 0 20px rgba(201, 168, 76, 0.3), 0 0 40px rgba(201, 168, 76, 0.1);
  --glow-text: 0 0 10px rgba(201, 168, 76, 0.3);

  /* Typography */
  --font-display: 'Cinzel', serif;
  --font-display-decorative: 'Cinzel Decorative', serif;
  --font-body: 'Rajdhani', sans-serif;
  --font-serif: 'Cormorant Garamond', serif;

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;
  --space-5xl: 8rem;

  /* Layout */
  --max-width: 1440px;
  --nav-height: 64px;
  --section-padding: clamp(3rem, 6vw, 6rem);

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 300ms ease;
  --transition-slow: 600ms ease;
  --transition-dramatic: 1000ms cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 20% 0%, rgba(201, 168, 76, 0.03) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 100%, rgba(201, 168, 76, 0.02) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

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

a {
  color: var(--gold-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--gold-light);
}

/* ── Typography System ── */
.t-display-xl {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1.1;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-primary);
}

.t-display-lg {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.15;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-primary);
}

.t-display-md {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.5rem, 2.5vw, 2.25rem);
  line-height: 1.2;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gold-primary);
}

.t-display-sm {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1rem, 1.5vw, 1.5rem);
  line-height: 1.3;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gold-primary);
}

.t-heading {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(0.85rem, 1.2vw, 1.1rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-primary);
}

.t-label {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.t-body {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--text-secondary);
}

.t-body-sm {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--text-tertiary);
}

.t-stat-number {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 3vw, 3rem);
  color: var(--gold-primary);
  line-height: 1;
}

.t-stat-label {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.6rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-top: 0.25rem;
}

.t-small-caps {
  font-variant: small-caps;
  letter-spacing: 0.15em;
}

.t-tagline {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(0.7rem, 1vw, 0.85rem);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

/* ── Navigation ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1rem, 3vw, 2.5rem);
  z-index: 1000;
  background: linear-gradient(180deg, rgba(6, 10, 20, 0.95) 0%, rgba(6, 10, 20, 0.8) 70%, transparent 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-subtle);
  transition: background var(--transition-base);
}

.nav--scrolled {
  background: rgba(6, 10, 20, 0.97);
  border-bottom-color: var(--border-medium);
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.nav__logo {
  width: 36px;
  height: 36px;
  border: 1.5px solid var(--gold-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display-decorative);
  font-size: 0.9rem;
  color: var(--gold-primary);
  position: relative;
}

.nav__logo::before {
  content: '';
  position: absolute;
  inset: -3px;
  border: 1px solid var(--gold-muted);
  border-radius: 50%;
}

.nav__brand-text {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-primary);
}

.nav__brand-sub {
  display: block;
  font-family: var(--font-body);
  font-size: 0.5rem;
  letter-spacing: 0.25em;
  color: var(--text-tertiary);
  margin-top: 1px;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.5vw, 2rem);
  list-style: none;
}

.nav__link {
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-secondary);
  text-decoration: none;
  position: relative;
  padding: 0.25rem 0;
  transition: color var(--transition-fast);
}

.nav__link:hover,
.nav__link--active {
  color: var(--gold-primary);
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--gold-primary);
  transition: width var(--transition-base);
}

.nav__link:hover::after,
.nav__link--active::after {
  width: 100%;
}

.nav__cta {
  font-family: var(--font-body);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold-primary);
  border: 1px solid var(--gold-primary);
  padding: 0.5rem 1.25rem;
  text-decoration: none;
  transition: all var(--transition-base);
}

.nav__cta:hover {
  background: var(--gold-primary);
  color: var(--bg-primary);
}

/* Mobile Nav Toggle */
.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 0.5rem;
  background: none;
  border: none;
}

.nav__toggle span {
  width: 22px;
  height: 1.5px;
  background: var(--gold-primary);
  transition: all var(--transition-base);
}

@media (max-width: 1024px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    width: 100%;
    flex-direction: column;
    background: rgba(6, 10, 20, 0.98);
    backdrop-filter: blur(20px);
    padding: 2rem;
    gap: 1.25rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all var(--transition-base);
    border-bottom: 1px solid var(--border-medium);
  }
  .nav__links--open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--gold-primary);
  color: var(--gold-primary);
  background: transparent;
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(201, 168, 76, 0.1), transparent);
  transition: left var(--transition-slow);
}

.btn:hover::before {
  left: 100%;
}

.btn:hover {
  background: rgba(201, 168, 76, 0.08);
  box-shadow: var(--shadow-gold);
  color: var(--gold-light);
}

.btn--filled {
  background: var(--gold-primary);
  color: var(--bg-primary);
}

.btn--filled:hover {
  background: var(--gold-light);
  color: var(--bg-primary);
}

.btn__arrow {
  transition: transform var(--transition-fast);
}

.btn:hover .btn__arrow {
  transform: translateX(4px);
}

/* ── Panels & Cards ── */
.panel {
  background: var(--bg-panel);
  border: 1px solid var(--border-subtle);
  padding: clamp(1.25rem, 2vw, 2rem);
  position: relative;
  backdrop-filter: blur(8px);
}

.panel--bordered {
  border-color: var(--border-medium);
}

.panel--glow {
  box-shadow: var(--shadow-gold);
}

.panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-muted), transparent);
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 1.5rem;
  transition: all var(--transition-base);
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-medium);
  transform: translateY(-2px);
  box-shadow: var(--shadow-gold);
}

.card__image {
  width: 100%;
  aspect-ratio: 16/10;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-subtle);
  margin-bottom: 1rem;
  overflow: hidden;
  position: relative;
}

.card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.card:hover .card__image img {
  transform: scale(1.05);
}

.card__icon {
  width: 36px;
  height: 36px;
  border: 1px solid var(--gold-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: -1.25rem auto 0.75rem;
  background: var(--bg-secondary);
  position: relative;
  z-index: 1;
  color: var(--gold-primary);
  font-size: 0.8rem;
}

.card__title {
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold-primary);
  text-align: center;
  margin-bottom: 0.35rem;
}

.card__desc {
  font-family: var(--font-body);
  font-size: 0.6rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  text-align: center;
  line-height: 1.6;
}

/* ── Status Indicators ── */
.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 0.5rem;
}

.status-dot--active {
  background: var(--status-active);
  box-shadow: 0 0 6px var(--status-active);
  animation: pulse-dot 2s ease-in-out infinite;
}

.status-dot--warning {
  background: var(--status-warning);
}

.status-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border-subtle);
  font-family: var(--font-body);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.status-row__label {
  color: var(--text-secondary);
}

.status-row__value {
  color: var(--status-active);
  font-weight: 600;
  display: flex;
  align-items: center;
}

/* ── Stats Bar ── */
.stats-bar {
  display: flex;
  justify-content: center;
  gap: clamp(1.5rem, 3vw, 3rem);
  padding: 1.5rem 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.stat-item {
  text-align: center;
}

.stat-item__icon {
  width: 32px;
  height: 32px;
  margin: 0 auto 0.5rem;
  border: 1px solid var(--gold-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-primary);
  font-size: 0.75rem;
}

/* ── Section Layout ── */
.section {
  position: relative;
  padding: var(--section-padding) clamp(1rem, 4vw, 3rem);
  z-index: 1;
}

.section__inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.section__header {
  margin-bottom: clamp(2rem, 4vw, 3.5rem);
}

.section__divider {
  width: 60px;
  height: 1px;
  background: var(--gold-primary);
  margin: 1rem 0;
}

/* ── Hero Section ── */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--nav-height) + 2rem) clamp(1.5rem, 4vw, 3rem) 3rem;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(6, 10, 20, 0.7) 0%, rgba(6, 10, 20, 0.3) 40%, rgba(6, 10, 20, 0.5) 70%, rgba(6, 10, 20, 0.95) 100%),
    linear-gradient(90deg, rgba(6, 10, 20, 0.6) 0%, transparent 50%);
}

.hero__content {
  max-width: 700px;
  position: relative;
  z-index: 1;
}

/* ── Grid System ── */
.grid {
  display: grid;
  gap: clamp(0.75rem, 1.5vw, 1.25rem);
}

.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--5 { grid-template-columns: repeat(5, 1fr); }

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

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

/* ── Footer ── */
.footer {
  position: relative;
  padding: 3rem clamp(1rem, 4vw, 3rem) 1.5rem;
  border-top: 1px solid var(--border-medium);
  background: var(--bg-secondary);
}

.footer__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 2rem;
  align-items: start;
}

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

.footer__center {
  text-align: center;
}

.footer__tagline {
  font-family: var(--font-display);
  font-size: 0.6rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin-bottom: 0.75rem;
}

.footer__coords {
  font-family: var(--font-body);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  color: var(--text-tertiary);
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.footer__link {
  font-family: var(--font-body);
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer__link:hover {
  color: var(--gold-primary);
}

.footer__right {
  text-align: right;
}

.footer__bottom {
  max-width: var(--max-width);
  margin: 2rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
  text-align: center;
  font-family: var(--font-body);
  font-size: 0.5rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

@media (max-width: 768px) {
  .footer__inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .footer__right { text-align: center; }
}

/* ── Decorative Elements ── */
.corner-bracket {
  position: absolute;
  width: 12px;
  height: 12px;
  border-color: var(--gold-border);
  border-style: solid;
}

.corner-bracket--tl { top: -1px; left: -1px; border-width: 1px 0 0 1px; }
.corner-bracket--tr { top: -1px; right: -1px; border-width: 1px 1px 0 0; }
.corner-bracket--bl { bottom: -1px; left: -1px; border-width: 0 0 1px 1px; }
.corner-bracket--br { bottom: -1px; right: -1px; border-width: 0 1px 1px 0; }

.gold-line {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-primary), transparent);
}

.gold-line--left {
  background: linear-gradient(90deg, var(--gold-primary), transparent);
}

/* ── Animations ── */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

@keyframes glow-pulse {
  0%, 100% { box-shadow: 0 0 20px rgba(201, 168, 76, 0.1); }
  50% { box-shadow: 0 0 40px rgba(201, 168, 76, 0.25); }
}

@keyframes scan-line {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

.animate-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-delay-1 { transition-delay: 0.1s; }
.animate-delay-2 { transition-delay: 0.2s; }
.animate-delay-3 { transition-delay: 0.3s; }
.animate-delay-4 { transition-delay: 0.4s; }
.animate-delay-5 { transition-delay: 0.5s; }

/* ── Noise/Grain Overlay ── */
.grain-overlay {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

/* ── Utility Classes ── */
.text-center { text-align: center; }
.text-gold { color: var(--gold-primary); }
.text-muted { color: var(--text-tertiary); }
.mt-1 { margin-top: var(--space-md); }
.mt-2 { margin-top: var(--space-xl); }
.mt-3 { margin-top: var(--space-3xl); }
.mb-1 { margin-top: var(--space-md); }
.mb-2 { margin-bottom: var(--space-xl); }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-1 { gap: var(--space-md); }
.gap-2 { gap: var(--space-xl); }

/* ── Scrollbar ── */
::-webkit-scrollbar {
  width: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--gold-dark);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gold-dim);
}

/* ── Selection ── */
::selection {
  background: rgba(201, 168, 76, 0.3);
  color: var(--gold-light);
}
