/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0e0e0e;
  --bg2:       #161616;
  --bg3:       #1e1e1e;
  --border:    #2a2a2a;
  --accent:    #c8102e;
  --accent2:   #e8303e;
  --text:      #f0f0f0;
  --text-muted:#9a9a9a;
  --gold:      #d4a017;
  --radius:    6px;
  --font:      'Segoe UI', system-ui, sans-serif;
}

html { scroll-behavior: smooth; overflow-x: hidden; }

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

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

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

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 13px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 2px solid transparent;
}
.btn--primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn--primary:hover { background: var(--accent2); border-color: var(--accent2); transform: translateY(-1px); }
.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: #444;
}
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn--sm { padding: 9px 18px; font-size: 0.85rem; }

/* ===== NAV ===== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 36px;
  background: rgba(14,14,14,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: padding 0.3s;
}
.nav.scrolled { padding: 12px 36px; }
.nav__logo {
  display: flex;
  align-items: center;
  line-height: 1;
}
.nav__logo-img {
  height: 38px;
  width: auto;
  display: block;
  /* logo is white on transparent — looks fine on dark nav */
}
.nav__links {
  display: flex;
  list-style: none;
  gap: 32px;
  align-items: center;
}
.nav__links a {
  font-size: 0.9rem;
  font-weight: 500;
  letter-spacing: 0.5px;
  color: var(--text-muted);
  transition: color 0.2s;
}
.nav__links a:hover { color: var(--text); }
.nav__cta {
  background: var(--accent) !important;
  color: #fff !important;
  padding: 8px 20px;
  border-radius: var(--radius);
  font-weight: 600 !important;
}
.nav__cta:hover { background: var(--accent2) !important; }
.nav__burger { display: none; background: none; border: none; color: var(--text); font-size: 1.4rem; cursor: pointer; }

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background:
    linear-gradient(135deg, rgba(14,14,14,0.96) 0%, rgba(14,14,14,0.75) 60%, rgba(200,16,46,0.15) 100%),
    url('https://images.unsplash.com/photo-1595590424283-b8f17842773f?w=1600&q=80') center/cover no-repeat;
  padding: 0 36px;
}
.hero__overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at top right, rgba(200,16,46,0.08) 0%, transparent 70%);
  pointer-events: none;
}
/* Hero inner layout — content left, emblem right */
.hero__inner {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 48px;
  max-width: 1100px;
  padding-top: 80px;
}
.hero__content {
  position: relative;
  max-width: 620px;
  flex: 1;
}
.hero__tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 5px 14px;
  border-radius: 99px;
  margin-bottom: 24px;
}
.hero__title {
  font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -1px;
  margin-bottom: 20px;
}
.hero__title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: var(--accent);
  margin-top: 16px;
}
.hero__sub {
  color: var(--text-muted);
  font-size: 1.1rem;
  max-width: 520px;
  margin-bottom: 36px;
}
.hero__actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* ===== SECTION COMMON ===== */
.section { padding: 96px 0; }
.section__header { text-align: center; margin-bottom: 56px; }
.section__tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}
.section__title {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.5px;
}

/* ===== ABOUT ===== */
.about { background: var(--bg2); }
.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}
.about__text p {
  color: var(--text-muted);
  margin-bottom: 16px;
  font-size: 1rem;
}
.about__features {
  list-style: none;
  margin-top: 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.about__features li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-muted);
}
.icon { color: var(--accent); font-weight: 700; }
.about__emblem {
  grid-column: 1 / -1;
  text-align: center;
  margin-bottom: 8px;
}
.about__emblem img {
  width: 130px;
  height: auto;
  opacity: 0.9;
  filter: drop-shadow(0 0 24px rgba(200,16,46,0.25));
  margin: 0 auto;
}
.about__stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.stat {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  padding: 24px 20px;
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stat__num {
  font-size: 2.2rem;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
}
.stat__label {
  font-size: 0.8rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* ===== NEWS ===== */
.news { background: var(--bg); }
.news__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.news__card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s, transform 0.2s;
}
.news__card:hover { border-color: var(--accent); transform: translateY(-2px); }
.news__card--featured {
  grid-column: span 2;
  border-left: 4px solid var(--accent);
  background: linear-gradient(135deg, var(--bg2), var(--bg3));
}
.news__badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 99px;
  background: var(--accent);
  color: #fff;
  width: fit-content;
}
.news__badge--comp { background: #1a5276; }
.news__badge--train { background: #1e8449; }
.news__badge--news { background: var(--gold); color: #111; }
.news__meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}
.news__date, .news__time {
  font-size: 0.82rem;
  color: var(--text-muted);
}
.news__title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.3;
}
.news__desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  flex: 1;
}

/* ===== CONTACT ===== */
.contact { background: var(--bg2); }
.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 56px;
  align-items: start;
}
.contact__info { display: flex; flex-direction: column; gap: 28px; }
.contact__block h3 {
  font-size: 0.75rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 6px;
}
.contact__block p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}
.contact__form {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.contact__form h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 4px;
}
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact__form input,
.contact__form textarea {
  background: var(--bg2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius);
  padding: 12px 16px;
  font-size: 0.9rem;
  font-family: var(--font);
  width: 100%;
  transition: border-color 0.2s;
}
.contact__form input:focus,
.contact__form textarea:focus {
  outline: none;
  border-color: var(--accent);
}
.contact__form textarea { resize: vertical; }
.form__success {
  display: none;
  color: #2ecc71;
  font-size: 0.9rem;
}
.form__error {
  display: none;
  color: var(--accent);
  font-size: 0.9rem;
}

/* ===== CONTACT LINKS ===== */
.contact__link {
  color: var(--text);
  text-decoration: none;
  transition: color 0.2s;
}
.contact__link:hover { color: var(--accent); }

/* ===== SOCIAL ICONS ===== */
.social-icons {
  display: flex;
  gap: 14px;
  margin-top: 8px;
}
.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--bg3);
  color: var(--text-muted);
  transition: background 0.2s, color 0.2s, transform 0.2s;
}
.social-icon:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-2px);
}

/* ===== FOOTER ===== */
.footer {
  background: #080808;
  border-top: 1px solid var(--border);
  padding: 32px 0;
}
.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.footer__logo {
  display: flex;
  align-items: center;
}
.footer__logo-img {
  height: 28px;
  width: auto;
  opacity: 0.85;
}
.footer__copy {
  color: var(--text-muted);
  font-size: 0.8rem;
}
.footer__links {
  display: flex;
  gap: 24px;
}
.footer__links a {
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer__links a:hover { color: var(--text); }
.footer__social {
  display: flex;
  gap: 10px;
}
.footer__social .social-icon {
  width: 34px;
  height: 34px;
  background: var(--bg2);
}

/* ===== RESPONSIVE ===== */
/* Hide contact social on desktop (already in footer) */
@media (min-width: 769px) {
  .contact__social { display: none !important; }
}

@media (max-width: 768px) {
  .nav { padding: 16px 20px; }
  .nav__links { display: none; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0; background: var(--bg); padding: 20px; border-bottom: 1px solid var(--border); gap: 20px; }
  .nav__links.open { display: flex; }
  .nav__burger { display: block; }
  .hero { padding: 0 20px; }
  .hero__inner { flex-direction: column; text-align: center; padding-top: 100px; padding-bottom: 40px; }
  .hero__actions { justify-content: center; }
  .hero__title::after { margin: 16px auto 0; }
  .about__grid { grid-template-columns: 1fr; gap: 40px; }
  .about__features { grid-template-columns: 1fr; }
  .contact__grid { grid-template-columns: 1fr; gap: 40px; }
  .form__row { grid-template-columns: 1fr; }
  .news__card--featured { grid-column: span 1; }
  .footer__inner { flex-direction: column; text-align: center; }
  .footer__links { justify-content: center; }
}

@media (max-width: 500px) {
  .about__stats { grid-template-columns: 1fr 1fr; }
  .contact__form { padding: 24px; }
}

/* ===== ADMIN NAV LINK ===== */
.nav__admin {
  font-size: 0.82rem !important;
  color: var(--text-muted) !important;
  border: 1px solid var(--border);
  padding: 5px 14px;
  border-radius: var(--radius);
  transition: border-color 0.2s, color 0.2s !important;
}
.nav__admin:hover { border-color: var(--accent) !important; color: var(--accent) !important; }

/* ===== NEWS EMPTY STATE ===== */
.news__empty {
  text-align: center;
  color: var(--text-muted);
  padding: 48px 0;
  font-size: 0.95rem;
}

/* ===== NEWS THUMB (attachment preview on card) ===== */
.news__thumb {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.news__pdf-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px 12px;
  width: fit-content;
}

/* ===== NEWS MODAL ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.8);
  z-index: 300;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 48px 20px;
  overflow-y: auto;
}
.modal__box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 10px;
  width: 100%;
  max-width: 660px;
  position: relative;
  margin: auto;
}
.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--bg3);
  border: 1px solid var(--border);
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  line-height: 1;
}
.modal__close:hover { color: var(--text); border-color: #555; }
.modal__content { padding: 36px; }
.modal__title {
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 12px;
}
.modal__meta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 20px;
}
.modal__img {
  width: 100%;
  max-height: 340px;
  object-fit: cover;
  border-radius: var(--radius);
  margin-bottom: 20px;
  border: 1px solid var(--border);
}
.modal__pdf-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 18px;
  font-size: 0.88rem;
  margin-bottom: 20px;
  transition: border-color 0.2s;
}
.modal__pdf-link:hover { border-color: var(--accent); }
.modal__text {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ===== NEWS READ MORE BUTTON ===== */
.news__read-btn { margin-top: auto; }

/* ===== MAP ===== */
.map-wrap {
  margin-top: 56px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}
.map-embed {
  width: 100%;
  height: 420px;
  display: block;
  border: none;
  filter: grayscale(30%) invert(92%) hue-rotate(180deg);
}
@media (max-width: 768px) {
  .map-embed { height: 280px; }
}

/* ===== GALLERY SECTION ===== */
.gallery { background: var(--bg2); }
.gallery__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.gallery__item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  cursor: pointer;
  background: var(--bg3);
  aspect-ratio: 4 / 3;
  border: 1px solid var(--border);
}
.gallery__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}
.gallery__item:hover img { transform: scale(1.05); }
.gallery__caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 28px 12px 10px;
  background: linear-gradient(transparent, rgba(0,0,0,0.75));
  font-size: 0.78rem;
  color: #fff;
  opacity: 0;
  transition: opacity 0.25s;
}
.gallery__item:hover .gallery__caption { opacity: 1; }
.gallery__empty {
  text-align: center;
  color: var(--text-muted);
  padding: 48px 0;
  font-size: 0.95rem;
}
.gallery__footer {
  display: flex;
  justify-content: center;
  margin-top: 32px;
}

/* ===== LIGHTBOX ===== */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.93);
  z-index: 400;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}
.lightbox__content {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: min(90vw, 1000px);
  max-height: 90vh;
}
.lightbox__img {
  max-width: 100%;
  max-height: 78vh;
  object-fit: contain;
  border-radius: 6px;
  display: block;
}
.lightbox__caption {
  color: rgba(255,255,255,0.7);
  font-size: 0.88rem;
  margin-top: 12px;
  text-align: center;
}
.lightbox__counter {
  color: rgba(255,255,255,0.4);
  font-size: 0.78rem;
  margin-top: 6px;
}
.lightbox__close {
  position: fixed;
  top: 20px;
  right: 24px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s;
  line-height: 1;
}
.lightbox__close:hover { background: rgba(255,255,255,0.18); }
.lightbox__prev,
.lightbox__next {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  color: #fff;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s;
  line-height: 1;
  z-index: 401;
}
.lightbox__prev { left: 20px; }
.lightbox__next { right: 20px; }
.lightbox__prev:hover,
.lightbox__next:hover { background: rgba(255,255,255,0.18); }

@media (max-width: 768px) {
  .gallery__grid { grid-template-columns: repeat(2, 1fr); }
  .lightbox__prev { left: 8px; }
  .lightbox__next { right: 8px; }
}
@media (max-width: 480px) {
  .gallery__grid { grid-template-columns: 1fr 1fr; gap: 8px; }
}
