:root {
  /* Dynamic Palette: Strictly NO Blue. Using Midnight Purple, Magenta, Neon Rose */
  --bg-canvas: #160f2e;
  --bg-surface: rgba(255, 255, 255, 0.05);
  --bg-surface-hover: rgba(255, 255, 255, 0.08);
  --text-primary: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.7);
  --accent-primary: #e0409b;
  --accent-secondary: #f43f5e;
  
  /* Advanced UI Micro-Interactions & Depth */
  --ease-kinetic: cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-elevation: 0 12px 32px -4px rgba(0, 0, 0, 0.4);
  --shadow-hover: 0 20px 48px -8px rgba(224, 64, 155, 0.3);
  --glass-backdrop: blur(16px) saturate(180%);
  --radius: 20px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: Charter, Cambria, Georgia, serif;
  background-color: var(--bg-canvas);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-wrap: anywhere;
  hyphens: auto;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius);
  object-fit: cover;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2rem); }

p {
  margin-bottom: 1.5rem;
}

.text-container {
  max-width: 72ch;
  margin: 0 auto;
}

.label {
  font-variant: small-caps;
  text-transform: lowercase;
  font-size: 1.1rem;
  letter-spacing: 0.05em;
  color: var(--accent-secondary);
  display: block;
  margin-bottom: 0.5rem;
}

/* Links & Buttons */
a {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.3s var(--ease-kinetic);
}

/* Inline text links - underline that grows on hover */
.link-hover {
  position: relative;
  display: inline-block;
  color: var(--accent-primary);
}

.link-hover::after {
  content: '';
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--accent-secondary);
  transform-origin: bottom right;
  transition: transform 0.4s var(--ease-kinetic);
}

.link-hover:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

/* One solid main button */
.btn-main {
  display: inline-block;
  background-color: var(--accent-primary);
  color: var(--text-primary);
  padding: 1rem 2rem;
  border-radius: var(--radius);
  border: none;
  font-family: inherit;
  font-size: 1.1rem;
  cursor: pointer;
  text-align: center;
  transition: transform 0.4s var(--ease-kinetic), box-shadow 0.4s var(--ease-kinetic), background-color 0.4s var(--ease-kinetic);
  box-shadow: var(--shadow-elevation);
}

.btn-main:hover {
  transform: translateY(-4px) scale(1.02);
  background-color: var(--accent-secondary);
  box-shadow: var(--shadow-hover);
  color: var(--text-primary);
}

/* Header & Nav */
header {
  padding: 1.5rem 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative; /* Scrolls out of view */
  z-index: 100;
}

.brand {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
}

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

.nav-links a {
  font-size: 1.1rem;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 100%;
  transform: scaleX(0);
  height: 1px;
  bottom: -4px;
  left: 0;
  background-color: var(--accent-primary);
  transform-origin: bottom right;
  transition: transform 0.4s var(--ease-kinetic);
}

.nav-links a:hover::after {
  transform: scaleX(1);
  transform-origin: bottom left;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 2rem;
  cursor: pointer;
}

/* Layout Wrappers */
main {
  padding: 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* Background Patterns */
.bg-dots {
  background-image: radial-gradient(rgba(255, 255, 255, 0.15) 1px, transparent 1px);
  background-size: 24px 24px;
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4rem;
  padding: 4rem 2rem;
  border-radius: var(--radius);
  margin-bottom: 4rem;
  overflow: hidden;
}

.hero-content {
  flex: 1;
  z-index: 2;
}

.hero-image-wrapper {
  flex: 1;
  position: relative;
  z-index: 2;
}

.hero-image {
  width: 100%;
  height: 600px;
  object-fit: cover;
  box-shadow: var(--shadow-elevation);
}

/* Floating Fact Card */
.floating-card {
  position: absolute;
  bottom: -2rem;
  left: -2rem;
  background: var(--bg-surface);
  backdrop-filter: var(--glass-backdrop);
  -webkit-backdrop-filter: var(--glass-backdrop);
  padding: 2rem;
  border-radius: var(--radius);
  box-shadow: var(--shadow-elevation);
  max-width: 320px;
  animation: float 6s ease-in-out infinite;
}

.floating-card ul {
  list-style: none;
}

.floating-card li {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  font-size: 0.95rem;
  color: var(--text-muted);
}
.floating-card li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-15px); }
  100% { transform: translateY(0px); }
}

/* Bento Grid */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.bento-card {
  background-color: var(--bg-surface);
  border-radius: var(--radius);
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-elevation);
  transition: transform 0.5s var(--ease-kinetic), box-shadow 0.5s var(--ease-kinetic), background-color 0.5s var(--ease-kinetic);
  overflow: hidden;
  position: relative;
  border: none;
}

.bento-card:hover {
  transform: translateY(-8px) scale(1.015);
  box-shadow: var(--shadow-hover);
  background-color: var(--bg-surface-hover);
}

.bento-card.span-2 {
  grid-column: span 2;
}

.bento-card.span-row-2 {
  grid-row: span 2;
}

.bento-card img {
  margin-bottom: 1.5rem;
  height: 240px;
  width: 100%;
}

.bento-card.image-bg {
  padding: 0;
  min-height: 400px;
}

.bento-card.image-bg img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  z-index: 1;
}

.bento-card.image-bg .content {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 2.5rem;
  background: linear-gradient(to top, rgba(22, 15, 46, 0.9), transparent);
  z-index: 2;
}

/* Interior Pages Specifics */
.page-header {
  text-align: center;
  padding: 6rem 2rem;
  background-color: var(--bg-surface);
  border-radius: var(--radius);
  margin-bottom: 4rem;
}

.article-content {
  max-width: 72ch;
  margin: 0 auto 4rem auto;
  font-size: 1.1rem;
}

.article-content img {
  margin: 2rem 0;
  box-shadow: var(--shadow-elevation);
}

.pull-quote {
  font-size: 1.5rem;
  font-style: italic;
  color: var(--accent-primary);
  border-left: 4px solid var(--accent-secondary);
  padding-left: 1.5rem;
  margin: 2.5rem 0;
  background: var(--bg-surface);
  padding: 2rem;
  border-radius: var(--radius);
}

/* Tables */
.table-wrapper {
  overflow-x: auto;
  margin: 2rem 0;
  background: var(--bg-surface);
  border-radius: var(--radius);
  padding: 1rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

th, td {
  padding: 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}

th {
  color: var(--accent-primary);
  font-variant: small-caps;
}

/* Contact Form */
.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-muted);
}

.form-control {
  width: 100%;
  padding: 1rem;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px; /* slightly smaller than --radius for inputs */
  color: var(--text-primary);
  font-family: inherit;
  font-size: 1rem;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-primary);
  background: rgba(255,255,255,0.1);
}

/* Footer */
footer {
  background-color: var(--bg-surface);
  padding: 4rem 2rem;
  margin-top: 4rem;
  border-top-left-radius: var(--radius);
  border-top-right-radius: var(--radius);
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
}

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

.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.footer-nav a {
  color: var(--text-muted);
}

.footer-nav a:hover {
  color: var(--accent-secondary);
}

.footer-bottom {
  max-width: 1200px;
  margin: 3rem auto 0;
  padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* Scroll Reveal Classes */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s var(--ease-kinetic);
}

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

/* Mobile Responsive */
@media (max-width: 768px) {
  .hero {
    flex-direction: column;
    padding: 3rem 1.5rem;
  }
  
  .floating-card {
    position: relative;
    bottom: auto;
    left: auto;
    margin-top: -3rem;
    max-width: 100%;
  }
  
  .bento-card.span-2 {
    grid-column: span 1;
  }
  
  h1 { font-size: 2.5rem; }
  
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: var(--bg-canvas);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    transform: translateY(-10px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s var(--ease-kinetic);
    box-shadow: var(--shadow-elevation);
    z-index: 99;
  }
  
  .nav-links.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
  
  .mobile-menu-btn {
    display: block;
  }
}

@media (prefers-reduced-motion: reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}
