/* ============================================================================
   HASKAR — SHARED STYLES
   Used by: index.html · city.html · about.html · partner.html · news.html
   ========================================================================= */

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

/* --- Design tokens -------------------------------------------------------- */
:root {
  --bg:         #08060d;
  --bg-2:       #0d0a14;
  --panel:      #13101c;
  --panel-2:    #1a1424;

  --red:        #ff0033;
  --red-lite:   #ff3366;
  --red-deep:   #cc0022;
  --red-dim:    rgba(255, 0, 51, 0.25);

  --violet:     #a855f7;
  --violet-lite:#c084fc;
  --violet-dim: rgba(168, 85, 247, 0.15);

  --border:     rgba(255, 0, 51, 0.28);
  --border-2:   rgba(255, 255, 255, 0.06);

  --text:       #f0e8f0;
  --text-2:     #a898a8;
  --text-3:     #5a4a5a;
  --white:      #ffffff;

  --sans:       'Inter', system-ui, -apple-system, sans-serif;
  --display:    'Space Grotesk', system-ui, sans-serif;

  --gutter:     6vw;
}

/* --- Base ----------------------------------------------------------------- */
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}
::selection { background: var(--red); color: var(--white); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* --- Shared keyframes ----------------------------------------------------- */
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.6; transform: scale(0.9); }
}
@keyframes spin { to { transform: rotate(360deg); } }

/* --- Scroll progress bar -------------------------------------------------- */
#progress {
  position: fixed;
  top: 0; left: 0;
  height: 2px; width: 0%;
  background: linear-gradient(90deg, var(--red-deep), var(--red), var(--red-lite));
  z-index: 1000;
  transition: width 0.1s linear;
  box-shadow: 0 0 8px var(--red), 0 0 20px var(--red), 0 0 40px rgba(255, 0, 51, 0.6);
}

/* --- Header (scoped to #header, so city.html is untouched) ---------------- */
#header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 900;
  padding: 20px 40px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  background: rgba(8, 6, 13, 0.75);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
#header.scrolled {
  border-bottom-color: var(--border);
  background: rgba(8, 6, 13, 0.92);
}

.logo {
  font-family: var(--display);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -0.01em;
  color: var(--white);
  display: flex;
  align-items: center;
  gap: 12px;
  justify-self: start;
  position: relative;
  z-index: 890;
}
.logo::before {
  content: '';
  width: 38px;
  height: 38px;
  background-image: url('../images/haskar_logo.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 8px rgba(255, 0, 51, 0.55));
  flex-shrink: 0;
  transition: filter 0.3s, transform 0.3s;
}
.logo:hover::before {
  filter: drop-shadow(0 0 14px rgba(255, 0, 51, 0.85));
  transform: scale(1.05);
}

/* --- Nav ------------------------------------------------------------------ */
nav { justify-self: center; }
nav ul {
  list-style: none;
  display: flex;
  gap: 32px;
  font-size: 13px;
  color: var(--text-2);
}
nav a {
  transition: color 0.2s;
  position: relative;
  padding: 4px 0;
  font-weight: 500;
  white-space: nowrap;
}
nav a::after {
  content: '';
  position: absolute;
  left: 0; bottom: -3px;
  width: 0; height: 1px;
  background: var(--red);
  box-shadow: 0 0 8px var(--red);
  transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
nav a:hover { color: var(--white); }
nav a:hover::after { width: 100%; }
nav a.active { color: var(--white); }
nav a.active::after { width: 100%; }

.header-spacer { justify-self: end; }

/* --- Mobile nav toggle ---------------------------------------------------- */
.nav-toggle {
  display: none;
  position: relative;
  z-index: 890;
  width: 44px;
  height: 44px;
  padding: 0;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  justify-self: end;
  transition: background 0.2s, border-color 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.nav-toggle:active {
  background: rgba(255, 0, 51, 0.08);
  border-color: var(--red-dim);
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --- Nav: tighter gaps at mid-widths so 7 items fit nicely --------------- */
@media (max-width: 1200px) {
  nav ul { gap: 24px; font-size: 12.5px; }
}
@media (max-width: 1080px) {
  #header { padding: 16px 24px; gap: 16px; }
  nav ul { gap: 16px; font-size: 12px; }
}

@media (max-width: 780px) {
  #header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    gap: 0;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    background: rgba(8, 6, 13, 0.94);
  }
  #header.scrolled { background: rgba(8, 6, 13, 0.98); }
  .header-spacer { display: none; }
  .nav-toggle { display: flex; }

  nav {
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    background: #08060d;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 880;
    justify-self: auto;
    padding: 80px 24px 40px;
  }
  nav.open { opacity: 1; pointer-events: auto; }

  nav ul {
    display: flex;
    flex-direction: column;
    gap: 22px;
    text-align: center;
    padding: 0;
    margin: 0;
    list-style: none;
  }
  nav a {
    font-family: var(--display);
    font-size: 24px;
    font-weight: 500;
    letter-spacing: -0.015em;
    padding: 8px 16px;
    color: var(--text-2);
    display: block;
  }
  nav a::after { display: none; }
  nav a:hover,
  nav a:active { color: var(--red-lite); }
}

/* --- Section primitives --------------------------------------------------- */
main { position: relative; z-index: 2; }
section { padding: 140px var(--gutter); position: relative; }
.container-wide { max-width: 1200px; margin: 0 auto; }

/* --- Reveal on scroll ----------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1),
              transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.in { opacity: 1; transform: translateY(0); }
.d-1 { transition-delay: 0.08s; }
.d-2 { transition-delay: 0.16s; }
.d-3 { transition-delay: 0.24s; }
.d-4 { transition-delay: 0.32s; }

/* --- Section headers ------------------------------------------------------ */
.section-head { max-width: 720px; margin-bottom: 72px; }
.section-label {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--red-lite);
  font-weight: 600;
  margin-bottom: 20px;
}
.section-title {
  font-family: var(--display);
  font-size: clamp(36px, 5.5vw, 64px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--white);
  margin-bottom: 20px;
}
.section-sub {
  font-size: 18px;
  color: var(--text-2);
  line-height: 1.6;
  max-width: 620px;
}

/* --- Eyebrow badge -------------------------------------------------------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border: 1px solid var(--red-dim);
  background: rgba(255, 0, 51, 0.08);
  border-radius: 100px;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--red-lite);
  font-weight: 600;
  margin-bottom: 32px;
  box-shadow: 0 0 20px rgba(255, 0, 51, 0.2);
}
.eyebrow::before {
  content: '';
  width: 6px; height: 6px;
  background: var(--red);
  border-radius: 50%;
  box-shadow: 0 0 8px var(--red), 0 0 16px var(--red);
  animation: pulse 2s ease-in-out infinite;
}

/* --- Buttons -------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  font-family: var(--sans);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  border: none;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.btn-primary {
  background: var(--red);
  color: var(--white);
  box-shadow: 0 0 20px rgba(255, 0, 51, 0.35),
              0 0 40px rgba(255, 0, 51, 0.15);
}
.btn-primary:hover {
  background: var(--red-lite);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(255, 0, 51, 0.6),
              0 0 40px rgba(255, 0, 51, 0.4);
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border-2);
}
.btn-ghost:hover {
  border-color: var(--red);
  background: rgba(255, 0, 51, 0.08);
  transform: translateY(-2px);
  box-shadow: 0 0 20px rgba(255, 0, 51, 0.25);
}
.btn:active { transform: scale(0.98); }

/* --- Footer --------------------------------------------------------------- */
footer {
  padding: 80px var(--gutter) 40px;
  background: var(--bg-2);
  border-top: 1px solid var(--border-2);
}
.footer-inner { max-width: 1200px; margin: 0 auto; }

.footer-cols {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr auto;
  gap: 48px;
  margin-bottom: 64px;
  align-items: start;
}

.footer-brand {
  font-family: var(--display);
  font-weight: 700;
  font-size: 22px;
  color: var(--white);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer-brand::before {
  content: '';
  width: 34px;
  height: 34px;
  background-image: url('../images/haskar_logo.png');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 8px rgba(255, 0, 51, 0.5));
  flex-shrink: 0;
}
.footer-tagline {
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.6;
  max-width: 280px;
  margin-bottom: 28px;
}

.socials {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  max-width: 320px;
}
.social-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--panel);
  border: 1px solid var(--border-2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  color: var(--text-2);
  -webkit-tap-highlight-color: transparent;
}
.social-icon svg { width: 18px; height: 18px; fill: currentColor; }
.social-icon:hover {
  transform: translateY(-3px);
  background: rgba(255, 0, 51, 0.12);
  border-color: var(--red-dim);
  color: var(--white);
  box-shadow: 0 6px 20px rgba(255, 0, 51, 0.4),
              0 0 30px rgba(255, 0, 51, 0.2);
}

.footer-col h4 {
  font-family: var(--display);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 600;
  margin-bottom: 20px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.footer-col a { font-size: 14px; color: var(--text-2); transition: color 0.2s; }
.footer-col a:hover { color: var(--red-lite); }

.footer-qr { text-align: center; justify-self: end; }
.footer-qr a {
  display: inline-block;
  border-radius: 12px;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-tap-highlight-color: transparent;
}
.footer-qr a:hover { transform: translateY(-4px); }
.footer-qr img {
  width: 140px;
  height: 140px;
  display: block;
  border-radius: 12px;
  box-shadow: 0 0 30px rgba(255, 0, 51, 0.35),
              0 0 60px rgba(255, 0, 51, 0.15);
  transition: box-shadow 0.3s;
}
.footer-qr a:hover img {
  box-shadow: 0 0 40px rgba(255, 0, 51, 0.6),
              0 0 80px rgba(255, 0, 51, 0.25);
}
.footer-qr-label {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-3);
  font-weight: 600;
  margin-top: 14px;
}

.footer-bottom {
  padding-top: 40px;
  border-top: 1px solid var(--border-2);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-legal { font-size: 12px; color: var(--text-3); line-height: 1.7; max-width: 700px; }
.footer-copy { font-size: 12px; color: var(--text-3); }

/* --- Cookie banner -------------------------------------------------------- */
#cookie-banner {
  position: fixed;
  bottom: 24px; left: 50%;
  transform: translateX(-50%) translateY(120%);
  z-index: 9999;
  width: calc(100% - 48px);
  max-width: 520px;
  padding: 24px;
  background: rgba(13, 10, 20, 0.96);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 0, 51, 0.3);
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5),
              0 0 40px rgba(255, 0, 51, 0.15);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: #f0e8f0;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
#cookie-banner.show { transform: translateX(-50%) translateY(0); }
#cookie-banner h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}
#cookie-banner p { color: #a898a8; font-size: 13px; margin-bottom: 20px; }
#cookie-banner p a { color: #ff3366; text-decoration: underline; }
#cookie-banner .cookie-actions { display: flex; gap: 8px; flex-wrap: wrap; }
#cookie-banner button {
  flex: 1;
  min-width: 120px;
  padding: 12px 18px;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.25s;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
#cookie-banner .btn-reject {
  background: transparent;
  color: #a898a8;
  border: 1px solid rgba(255, 255, 255, 0.1);
}
#cookie-banner .btn-reject:hover {
  color: #fff;
  border-color: rgba(255, 0, 51, 0.4);
  background: rgba(255, 0, 51, 0.06);
}
#cookie-banner .btn-accept {
  background: #ff0033;
  color: #fff;
  box-shadow: 0 0 20px rgba(255, 0, 51, 0.4);
}
#cookie-banner .btn-accept:hover {
  background: #ff3366;
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(255, 0, 51, 0.6);
}

/* --- Newsletter form ------------------------------------------------------ */
.newsletter-form {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 520px;
  margin: 0 auto;
}
.newsletter-form input[type="email"] {
  flex: 1;
  min-width: 220px;
  padding: 14px 18px;
  border-radius: 10px;
  border: 1px solid var(--border-2);
  background: var(--panel);
  color: var(--text);
  font-size: 15px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.newsletter-form input[type="email"]:focus {
  border-color: var(--red-dim);
  box-shadow: 0 0 0 3px rgba(255, 0, 51, 0.12);
}
.newsletter-form button[type="submit"] {
  padding: 14px 26px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  background: var(--red);
  color: var(--white);
  font-weight: 600;
  font-size: 15px;
  font-family: inherit;
  transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.newsletter-form button[type="submit"]:hover {
  background: var(--red-lite);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(255, 0, 51, 0.4);
}
.newsletter-form button[type="submit"]:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}
.newsletter-msg {
  flex-basis: 100%;
  margin-top: 14px;
  font-size: 14px;
  min-height: 20px;
  color: var(--text-2);
  text-align: center;
}

/* --- Responsive: 900px ---------------------------------------------------- */
@media (max-width: 900px) {
  :root { --gutter: 20px; }
  section { padding: 90px var(--gutter); }

  .section-head {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: 48px;
  }
  .section-sub { margin: 0 auto; }

  .footer-cols { grid-template-columns: 1fr 1fr; gap: 40px; margin-bottom: 48px; }
}

@media (max-width: 620px) {
  .footer-cols { grid-template-columns: 1fr; }
  .footer-qr { justify-self: start; }
}

@media (max-width: 520px) {
  .newsletter-form { flex-direction: column; }
  .newsletter-form input[type="email"],
  .newsletter-form button[type="submit"] { width: 100%; }
}

@media (max-width: 500px) {
  #cookie-banner { padding: 20px; bottom: 12px; width: calc(100% - 24px); }
  #cookie-banner button { min-width: 0; padding: 12px 14px; font-size: 13px; }
}
@media (max-width: 380px) {
  #cookie-banner .cookie-actions { flex-direction: column; }
  #cookie-banner button { width: 100%; }
}

@media (max-width: 480px) {
  .section-title { font-size: clamp(30px, 9vw, 44px); }
  .logo::before { width: 34px; height: 34px; }
  .footer-brand::before { width: 30px; height: 30px; }
  .footer-qr img { width: 120px; height: 120px; }
  .social-icon { width: 44px; height: 44px; }
  .social-icon svg { width: 20px; height: 20px; }
}

/* --- Reduced motion ------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .eyebrow::before { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
}