/* ============================================
   AquaMediaStation — Main Stylesheet
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #060d1f;
  color: #e0e6f0;
  overflow-x: hidden;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* --- Utility --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}
.text-gradient {
  background: linear-gradient(135deg, #00a3e0 0%, #00d4aa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Topbar --- */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2.5rem;
  background: transparent;
  transition: background .4s ease, box-shadow .4s ease, padding .4s ease;
}
.topbar.scrolled {
  background: rgba(6, 13, 31, .92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 rgba(255,255,255,.06);
  padding: 0.8rem 2.5rem;
}
.topbar__logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: .6rem;
}
.topbar__logo-img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  transition: transform .3s ease;
}
.topbar.scrolled .topbar__logo-img {
  width: 34px;
  height: 34px;
}
.topbar__logo:hover .topbar__logo-img {
  transform: scale(1.08);
}
.logo-text {
  display: flex;
}
.logo-aqua { color: #00a3e0; }
.logo-media { color: #fff; }
.logo-station { color: #00d4aa; }

.topbar__nav {
  display: flex;
  gap: 2rem;
}
.topbar__nav a {
  font-size: .875rem;
  font-weight: 500;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: rgba(255,255,255,.7);
  transition: color .3s ease;
  position: relative;
}
.topbar__nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #00a3e0, #00d4aa);
  transition: width .3s ease;
}
.topbar__nav a:hover { color: #fff; }
.topbar__nav a:hover::after { width: 100%; }

/* Burger */
.topbar__burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 110;
}
.topbar__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform .3s ease, opacity .3s ease;
}
.topbar__burger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.topbar__burger.active span:nth-child(2) { opacity: 0; }
.topbar__burger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* Mobile nav */
.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 99;
  background: rgba(6, 13, 31, .97);
  backdrop-filter: blur(20px);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s ease;
}
.mobile-nav.open {
  opacity: 1;
  pointer-events: auto;
}
.mobile-nav nav {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  text-align: center;
}
.mobile-nav a {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.75rem;
  font-weight: 600;
  color: rgba(255,255,255,.8);
  transition: color .3s ease, transform .3s ease;
}
.mobile-nav a:hover {
  color: #00a3e0;
  transform: translateX(8px);
}

/* --- Hero Split Panels --- */
.hero-split {
  display: flex;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  position: relative;
}

.panel {
  position: relative;
  width: 50%;
  height: 100%;
  overflow: hidden;
  cursor: pointer;
  transition: width .8s cubic-bezier(.77, 0, .18, 1);
}

.panel__bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform .6s cubic-bezier(.33, 0, .2, 1), filter .6s ease;
}
/* Panel backgrounds — replace with real photos when available
   Optimal image size: 1200×1600px WebP, portrait orientation */
.panel--advertiseri .panel__bg {
  background-image: url('/images/panel-advertiseri.webp');
  background-size: cover;
  background-position: center;
}
.panel--autoritati .panel__bg {
  background-image: url('/images/panel-autoritati.webp');
  background-size: cover;
  background-position: center;
}
/* When real images arrive, add:
   .panel--advertiseri .panel__bg { background-image: url('/images/panel-advertiseri.webp'); }
   .panel--autoritati .panel__bg { background-image: url('/images/panel-autoritati.webp'); }
   The overlay will still tint them. */

.panel__overlay {
  position: absolute;
  inset: 0;
  transition: opacity .6s ease;
}
.panel--advertiseri .panel__overlay {
  background: linear-gradient(160deg, rgba(10, 22, 64, .93) 0%, rgba(0, 80, 160, .78) 100%);
}
.panel--autoritati .panel__overlay {
  background: linear-gradient(200deg, rgba(10, 50, 40, .93) 0%, rgba(0, 130, 110, .78) 100%);
}

.panel__content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100%;
  padding: 2rem;
  text-align: center;
  opacity: 1;
  transition: opacity .4s ease;
}

.panel__label {
  font-family: 'Inter', sans-serif;
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: rgba(255,255,255,.5);
  margin-bottom: .5rem;
}

.panel__title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 1rem;
}
.panel--advertiseri .panel__title { color: #4db8ff; }
.panel--autoritati .panel__title { color: #4de8c8; }

.panel__subtitle {
  font-size: clamp(.95rem, 1.5vw, 1.15rem);
  font-weight: 300;
  color: rgba(255,255,255,.7);
  line-height: 1.6;
  margin-bottom: 2rem;
  max-width: 360px;
}

.panel__cta {
  margin-bottom: 2rem;
}
.panel__hint {
  opacity: .4;
  transition: opacity .3s ease, transform .3s ease;
}
.panel:hover .panel__hint {
  opacity: .8;
  transform: translateX(4px);
}

/* Hover effect */
.panel:hover .panel__bg {
  transform: scale(1.05);
  filter: brightness(1.2);
}

/* Divider */
.panel__divider {
  position: absolute;
  top: 0;
  left: 50%;
  width: 1px;
  height: 100%;
  background: linear-gradient(180deg, transparent 5%, rgba(255,255,255,.15) 30%, rgba(255,255,255,.15) 70%, transparent 95%);
  z-index: 3;
  pointer-events: none;
  transition: opacity .6s ease;
}

/* --- Curtain animation states --- */
.panel.expanding {
  width: 100%;
}
.panel.collapsing {
  width: 0;
}
.panel.collapsing .panel__content {
  opacity: 0;
}
.panel__divider.hidden {
  opacity: 0;
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  font-size: .875rem;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: .9rem 2rem;
  border-radius: 50px;
  cursor: pointer;
  transition: all .35s cubic-bezier(.33, 0, .2, 1);
  border: none;
}
.btn--outline {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255,255,255,.35);
}
.btn--outline:hover {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.6);
  transform: translateY(-2px);
}
.btn--primary {
  background: linear-gradient(135deg, #0077cc 0%, #00a3e0 100%);
  color: #fff;
  box-shadow: 0 4px 20px rgba(0, 120, 200, .3);
}
.btn--primary:hover {
  box-shadow: 0 6px 30px rgba(0, 120, 200, .5);
  transform: translateY(-2px);
}
.btn--secondary {
  background: linear-gradient(135deg, #00896a 0%, #00d4aa 100%);
  color: #fff;
  box-shadow: 0 4px 20px rgba(0, 180, 140, .3);
}
.btn--secondary:hover {
  box-shadow: 0 6px 30px rgba(0, 180, 140, .5);
  transform: translateY(-2px);
}

/* --- Sections --- */
.section {
  padding: 6rem 0;
}
.section__title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 1.5rem;
}
.section__lead {
  font-size: clamp(1rem, 1.5vw, 1.2rem);
  font-weight: 300;
  color: rgba(255,255,255,.65);
  text-align: center;
  max-width: 700px;
  margin: 0 auto 4rem;
  line-height: 1.7;
}

/* What is AMS */
.section--what {
  background: linear-gradient(180deg, #060d1f 0%, #0a1430 100%);
}

/* Features grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}
.feature {
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 16px;
  padding: 2rem 1.5rem;
  text-align: center;
  transition: transform .4s ease, border-color .4s ease, background .4s ease;
}
.feature:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 163, 224, .25);
  background: rgba(0, 163, 224, .04);
}
.feature__icon {
  margin-bottom: 1.25rem;
  color: #00a3e0;
}
.feature__title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: .75rem;
  color: #fff;
}
.feature__text {
  font-size: .9rem;
  color: rgba(255,255,255,.55);
  line-height: 1.6;
}

/* Stats */
.section--stats {
  background: #060d1f;
  padding: 5rem 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  text-align: center;
}
.stat__number {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  font-weight: 700;
  color: #fff;
}
.stat__suffix {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  color: #00a3e0;
}
.stat__label {
  display: block;
  margin-top: .5rem;
  font-size: .85rem;
  font-weight: 400;
  color: rgba(255,255,255,.45);
  text-transform: uppercase;
  letter-spacing: .08em;
}

/* CTA */
.section--cta {
  background: linear-gradient(180deg, #060d1f 0%, #0a1430 50%, #060d1f 100%);
  padding: 8rem 0;
  text-align: center;
}
.cta-buttons {
  display: flex;
  gap: 1.25rem;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 2.5rem;
}

/* --- Footer --- */
.footer {
  border-top: 1px solid rgba(255,255,255,.06);
  padding: 3rem 0;
  background: #050b18;
}
.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}
.footer__brand {
  display: flex;
  flex-direction: column;
  gap: .35rem;
}
.footer__brand .logo-aqua,
.footer__brand .logo-media,
.footer__brand .logo-station {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
}
.footer__tagline {
  font-size: .8rem;
  color: rgba(255,255,255,.35);
}
.footer__links {
  display: flex;
  gap: 1.5rem;
}
.footer__links a {
  font-size: .85rem;
  color: rgba(255,255,255,.5);
  transition: color .3s ease;
}
.footer__links a:hover { color: #00a3e0; }
.footer__copy p {
  font-size: .75rem;
  color: rgba(255,255,255,.25);
}

/* --- Reveal animation --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .7s cubic-bezier(.33, 0, .2, 1), transform .7s cubic-bezier(.33, 0, .2, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 3rem; }
}

@media (max-width: 768px) {
  .topbar__nav { display: none; }
  .topbar__burger { display: flex; }
  .topbar { padding: 1rem 1.5rem; }

  .hero-split {
    flex-direction: column;
  }
  .panel {
    width: 100%;
    height: 50%;
    transition: height .8s cubic-bezier(.77, 0, .18, 1);
  }
  .panel.expanding {
    width: 100%;
    height: 100%;
  }
  .panel.collapsing {
    width: 100%;
    height: 0;
  }
  .panel__divider {
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent 5%, rgba(255,255,255,.15) 30%, rgba(255,255,255,.15) 70%, transparent 95%);
  }

  .panel__title { font-size: 2.2rem; }

  .features-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }

  .section { padding: 4rem 0; }
  .section--cta { padding: 5rem 0; }

  .footer__inner {
    flex-direction: column;
    text-align: center;
  }
  .footer__links {
    flex-direction: column;
    gap: .75rem;
  }
}

@media (max-width: 480px) {
  .container { padding: 0 1.25rem; }
  .panel__subtitle { font-size: .9rem; }
  .btn { padding: .75rem 1.5rem; font-size: .8rem; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 2rem; }
}
