/* ==========================================================================
   ASTATINE SYSTEMS - Design System & Custom Styles
   Inspired by linear.app, vercel.com, and resend.com
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=Inter:wght@300;400;500;600&display=swap');

/* --- CSS Variables --- */
:root {
  --bg-color: #000000;
  --text-primary: #ffffff;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --accent-blue: #3b82f6;
  --accent-blue-glow: rgba(59, 130, 246, 0.4);
  --accent-blue-light: #60a5fa;
  --card-bg: rgba(10, 10, 10, 0.4);
  --card-border: rgba(255, 255, 255, 0.08);
  --card-border-hover: rgba(59, 130, 246, 0.3);
  --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --nav-height: 80px;
  --grid-dot-color: rgba(59, 130, 246, 0.12);
  --spotlight-color: rgba(59, 130, 246, 0.15);
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--bg-color);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--bg-color);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  position: relative;
}

/* --- Dot Grid Background --- */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: radial-gradient(var(--grid-dot-color) 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events: none;
  z-index: -2;
}

/* Linear-style Radial Glow for depth */
body::after {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: 1400px;
  height: 600px;
  background: radial-gradient(circle at 50% 0%, rgba(59, 130, 246, 0.15) 0%, transparent 60%);
  pointer-events: none;
  z-index: -1;
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--text-primary);
}

p {
  color: var(--text-secondary);
  line-height: 1.6;
  font-weight: 400;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.3s ease;
}

/* --- Layout Containers --- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: 8rem 0;
  position: relative;
}

/* --- Header / Navigation --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  z-index: 1000;
  display: flex;
  align-items: center;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.logo-link {
  display: flex;
  align-items: center;
}

.logo-img {
  width: 140px;
  height: auto;
  max-height: 56px;
  object-fit: contain;
  display: block;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
  align-items: center;
}

.nav-item a {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.nav-item a:hover,
.nav-item.active a {
  color: var(--text-primary);
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

/* Language Switcher */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  padding: 0.25rem 0.75rem;
  background: rgba(255, 255, 255, 0.03);
  cursor: pointer;
  user-select: none;
  transition: all 0.3s ease;
}

.lang-switcher:hover {
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--text-secondary);
}

.lang-btn {
  cursor: pointer;
  transition: color 0.3s;
}

.lang-btn.active {
  color: var(--accent-blue);
}

.lang-divider {
  color: rgba(255, 255, 255, 0.15);
}

/* Mobile Hamburger Menu */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  z-index: 1001;
}

.hamburger span {
  display: block;
  width: 25px;
  height: 2px;
  background-color: var(--text-primary);
  transition: all 0.3s ease;
}

/* --- Premium CTA Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 500;
  padding: 0.8rem 1.8rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, #1d4ed8, #3b82f6);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(59, 130, 246, 0.45);
  border-color: rgba(255, 255, 255, 0.2);
}

.btn-primary::after {
  content: "";
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
  transition: all 0.6s ease;
}

.btn-primary:hover::after {
  left: 100%;
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  border: 1px solid rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  transform: translateY(-2px);
}

/* --- Hero Section --- */
.hero {
  padding-top: calc(var(--nav-height) + 6rem);
  padding-bottom: 6rem;
  text-align: center;
  position: relative;
}

.hero-subtitle {
  font-family: var(--font-display);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent-blue);
  margin-bottom: 1.5rem;
  font-weight: 600;
  display: inline-block;
  background: rgba(59, 130, 246, 0.08);
  padding: 0.35rem 1rem;
  border-radius: 30px;
  border: 1px solid rgba(59, 130, 246, 0.15);
}

.hero-title {
  font-size: 4rem;
  font-weight: 700;
  max-width: 900px;
  margin: 0 auto 2rem;
  line-height: 1.05;
  background: linear-gradient(180deg, #ffffff 60%, rgba(255, 255, 255, 0.5) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 1.25rem;
  max-width: 650px;
  margin: 0 auto 3rem;
  color: var(--text-secondary);
}

.hero-desc span {
  display: block;
  margin-top: 0.5rem;
  font-size: 1.05rem;
  color: var(--text-muted);
}

.hero-cta-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.cta-note {
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 450px;
  line-height: 1.4;
}

/* --- Built for Grid (Logotypes/Subtext) --- */
.client-logo-bar {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 2.5rem 0;
  background: rgba(0, 0, 0, 0.3);
}

.client-logo-title {
  text-align: center;
  font-family: var(--font-display);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.client-logo-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 3rem;
  opacity: 0.8;
}

.client-logo-item {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--text-secondary);
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.client-logo-item::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  background-color: var(--accent-blue);
  border-radius: 50%;
}

/* --- Section Headers --- */
.section-header {
  text-align: center;
  margin-bottom: 5rem;
}

.section-tag {
  font-family: var(--font-display);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent-blue);
  margin-bottom: 1rem;
  font-weight: 600;
}

.section-title {
  font-size: 2.75rem;
  margin-bottom: 1.5rem;
}

.section-desc {
  max-width: 600px;
  margin: 0 auto;
  font-size: 1.1rem;
}

/* --- Glassmorphism Cards & Spotlight --- */
.glass-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
}

.glass-card {
  position: relative;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 3rem 2.5rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
  z-index: 1;
  transition: border-color 0.4s ease, box-shadow 0.4s ease, transform 0.4s ease;
  --mouse-x: 0px;
  --mouse-y: 0px;
}

.glass-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: inherit;
  background: radial-gradient(
    400px circle at var(--mouse-x) var(--mouse-y),
    var(--spotlight-color),
    transparent 80%
  );
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
  z-index: -1;
}

.glass-card:hover {
  border-color: var(--card-border-hover);
  box-shadow: 0 10px 30px rgba(59, 130, 246, 0.05);
  transform: translateY(-4px);
}

.glass-card:hover::before {
  opacity: 1;
}

.card-num {
  font-family: var(--font-display);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-blue);
  margin-bottom: 1.5rem;
}

.card-icon {
  width: 48px;
  height: 48px;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  color: var(--accent-blue);
  font-size: 1.25rem;
}

.card-title {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  font-weight: 600;
}

.card-content-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.card-list {
  list-style: none;
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.card-list-item {
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}

.card-list-item svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--accent-blue);
}

/* --- Quote Block --- */
.quote-section {
  background: linear-gradient(180deg, transparent, rgba(59, 130, 246, 0.03) 50%, transparent);
  position: relative;
  text-align: center;
}

.quote-container {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.quote-symbol {
  font-family: var(--font-display);
  font-size: 8rem;
  line-height: 0.5;
  color: rgba(59, 130, 246, 0.15);
  position: absolute;
  top: -2rem;
  left: 50%;
  transform: translateX(-50%);
  user-select: none;
}

.quote-text {
  font-family: var(--font-display);
  font-size: 2.25rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--text-primary);
  position: relative;
  z-index: 1;
  letter-spacing: -0.01em;
  margin-bottom: 1.5rem;
}

/* --- Timeline/Approach Steps --- */
.approach-timeline {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.approach-timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 2rem;
  width: 1px;
  background: linear-gradient(180deg, var(--accent-blue) 0%, rgba(255, 255, 255, 0.05) 100%);
}

.approach-step {
  display: flex;
  gap: 2.5rem;
  position: relative;
}

.step-number {
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background: #000;
  border: 1px solid var(--accent-blue);
  color: var(--text-primary);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.2);
  z-index: 2;
}

.step-details {
  padding-top: 0.8rem;
}

.step-title {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

/* --- Contact & Forms --- */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 4rem;
  align-items: start;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-info-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.contact-info-desc {
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.contact-meta {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-meta-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-family: var(--font-display);
}

.contact-meta-icon {
  width: 40px;
  height: 40px;
  background: rgba(59, 130, 246, 0.05);
  border: 1px solid rgba(59, 130, 246, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-blue);
}

.form-card {
  background: rgba(10, 10, 10, 0.4);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 3rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.form-group {
  margin-bottom: 2rem;
  position: relative;
}

.form-label {
  display: block;
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  transition: color 0.3s;
}

.form-control {
  width: 100%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 1rem 1.2rem;
  font-family: var(--font-body);
  color: var(--text-primary);
  font-size: 1rem;
  transition: all 0.3s ease;
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-blue);
  background: rgba(255, 255, 255, 0.05);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.1);
}

.form-control:focus + .form-label {
  color: var(--accent-blue);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* --- Telegram Panel --- */
.telegram-panel {
  margin-top: 2rem;
  padding: 1.5rem;
  border-radius: 12px;
  border: 1px solid rgba(0, 136, 204, 0.15);
  background: rgba(0, 136, 204, 0.03);
  display: flex;
  align-items: center;
  gap: 1rem;
}

.tg-icon {
  color: #0088cc;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.tg-text h4 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
  color: #0088cc;
}

.tg-text p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* --- Footer --- */
.footer {
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(0, 0, 0, 0.9);
  padding: 5rem 0 3rem;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.footer-logo {
  width: 120px;
  height: auto;
  max-height: 48px;
  object-fit: contain;
  display: block;
}

.footer-tagline {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.footer-col-title {
  font-family: var(--font-display);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  font-weight: 600;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.footer-links a:hover {
  color: var(--text-primary);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
}

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

.footer-legal {
  display: flex;
  gap: 2rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-legal a:hover {
  color: var(--text-primary);
}

/* --- Thank You Page Styles --- */
.thank-you-layout {
  min-height: calc(100vh - var(--nav-height) - 300px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 4rem 1.5rem;
}

.thank-you-icon {
  width: 80px;
  height: 80px;
  background: rgba(59, 130, 246, 0.1);
  border: 1px solid rgba(59, 130, 246, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-blue);
  font-size: 2.5rem;
  margin-bottom: 2rem;
  box-shadow: 0 0 30px rgba(59, 130, 246, 0.15);
}

/* --- Privacy Policy Page Styles --- */
.legal-layout {
  max-width: 800px;
  margin: 0 auto;
  padding-top: calc(var(--nav-height) + 4rem);
  padding-bottom: 8rem;
}

.legal-title {
  font-size: 3rem;
  margin-bottom: 3rem;
  text-align: center;
}

.legal-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 4rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.legal-section {
  margin-bottom: 2.5rem;
}

.legal-section h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 0.5rem;
}

.legal-section p {
  font-size: 1rem;
  line-height: 1.7;
}

/* --- Mobile Menu Styles & Overlays --- */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 3rem 1.5rem;
    gap: 2rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 999;
  }

  .nav-menu.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .hamburger.open span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .hamburger.open span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.open span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .section {
    padding: 5rem 0;
  }

  .contact-layout {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }

  .legal-card {
    padding: 2rem;
  }
}
