/* ===== CSS Variables ===== */
:root {
  /* Warm Tallinn palette – stone, pastels, navy & soft gold */
  --primary: #1e3a5f; /* Deep navy (trust) */
  --primary-dark: #152a45;
  --primary-light: #2d4a6f;
  --secondary: #8b7355; /* Warm sandstone */
  --accent: #c9a227; /* Soft gold */
  --accent-hover: #b8921f;
  --text: #2c2c2c;
  --text-light: #5c5c5c;
  --bg: #fdfbf7; /* Warm off-white */
  --bg-alt: #f5f0e8; /* Soft cream */
  --bg-dark: #1a2332;
  --border: #e8e0d5;
  --shadow: 0 4px 6px -1px rgba(30, 58, 95, 0.08), 0 2px 4px -1px rgba(30, 58, 95, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(30, 58, 95, 0.1), 0 4px 6px -2px rgba(30, 58, 95, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(30, 58, 95, 0.12), 0 10px 10px -5px rgba(30, 58, 95, 0.04);
  --radius: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  height: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}

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

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  transition: var(--transition);
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.logo {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-decoration: none;
  line-height: 1.15;
  gap: 1px;
}

.logo-name {
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.03em;
}

.logo-tag {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--secondary);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: 32px;
}

.nav a {
  text-decoration: none;
  color: var(--text-light);
  font-weight: 500;
  font-size: 0.95rem;
  transition: var(--transition);
  position: relative;
}

.nav a:hover {
  color: var(--primary);
}

.nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: var(--transition);
}

.nav a:hover::after {
  width: 100%;
}

.lang-switcher {
  display: flex;
  gap: 4px;
  background: var(--bg-alt);
  padding: 4px;
  border-radius: 8px;
}

.lang-btn {
  padding: 6px 12px;
  border: none;
  background: transparent;
  color: var(--text-light);
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  border-radius: 6px;
  transition: var(--transition);
}

.lang-btn:hover {
  color: var(--text);
}

.lang-btn.active {
  background: var(--primary);
  color: white;
}

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.mobile-menu-btn span {
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: var(--transition);
}

/* ===== Hero Section ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 72px;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(26, 35, 50, 0.75) 0%, rgba(30, 58, 95, 0.82) 100%),
  url('/img/hero.jpg') center/cover no-repeat;
  z-index: -1;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to right, rgba(26, 35, 50, 0.55) 0%, rgba(26, 35, 50, 0.25) 60%, transparent 100%);
  z-index: -1;
}

.hero-content {
  max-width: 700px;
  color: white;
  text-align: center;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-subtitle {
  font-size: 1.5rem;
  opacity: 0.9;
  margin-bottom: 40px;
  line-height: 1.7;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-dark);
}

.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: transparent;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
}

/* ===== Benefits Section ===== */
.benefits {
  padding: 100px 0;
  background: var(--bg);
  margin-top: -60px;
  position: relative;
  z-index: 10;
}

.benefits-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.benefit-card {
  background: var(--bg);
  padding: 40px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  text-align: center;
  transition: var(--transition);
  border: 1px solid var(--border);
}

.benefit-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

.benefit-icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}

.benefit-icon svg {
  width: 32px;
  height: 32px;
  stroke: white;
}

.benefit-card h3 {
  font-size: 1.25rem;
  margin-bottom: 12px;
  color: var(--text);
}

.benefit-card p {
  color: var(--text-light);
  line-height: 1.7;
}

/* ===== About Section ===== */
.about {
  padding: 100px 0;
  background: var(--bg-alt);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.about-image-placeholder {
  background: linear-gradient(to top, rgba(26, 35, 50, 0.65) 0%, transparent 45%),
  url('/img/about.jpg') center/cover;
  height: 420px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: flex-end;
  padding: 24px;
  color: white;
  font-weight: 600;
  font-size: 1.1rem;
  box-shadow: var(--shadow-lg);
}

.about-content h2 {
  font-size: 2.5rem;
  margin-bottom: 24px;
  color: var(--text);
}

.about-content p {
  color: var(--text-light);
  margin-bottom: 20px;
  line-height: 1.8;
}

.about-stats {
  display: flex;
  gap: 40px;
  margin-top: 40px;
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
}

.stat-label {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-top: 8px;
  display: block;
}

/* ===== Services Section ===== */
.services {
  padding: 100px 0;
  background: var(--bg);
}

.section-title {
  text-align: center;
  font-size: 2.5rem;
  margin-bottom: 60px;
  color: var(--text);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.service-card {
  background: var(--bg);
  padding: 32px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: var(--transition);
  text-align: center;
}

.service-card:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.service-icon {
  width: 56px;
  height: 56px;
  background: var(--bg-alt);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  transition: var(--transition);
}

.service-card:hover .service-icon {
  background: var(--primary);
}

.service-icon svg {
  width: 28px;
  height: 28px;
  stroke: var(--primary);
  transition: var(--transition);
}

.service-card:hover .service-icon svg {
  stroke: white;
}

.service-card h3 {
  font-size: 1.1rem;
  margin-bottom: 12px;
  color: var(--text);
}

.service-card p {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ===== Pricing Section ===== */
.pricing {
  padding: 100px 0;
  background: var(--bg-alt);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
}

.pricing-card {
  background: var(--bg);
  padding: 32px 24px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  text-align: center;
  transition: var(--transition);
  position: relative;
}

.pricing-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.pricing-icon {
  width: 48px;
  height: 48px;
  background: var(--bg-alt);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

.pricing-icon svg {
  width: 24px;
  height: 24px;
  stroke: var(--primary);
}

.pricing-card h3 {
  font-size: 0.95rem;
  margin-bottom: 12px;
  color: var(--text);
}

.price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--primary);
}

.price span {
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--text-light);
}

.pricing-desc {
  font-size: 0.85rem;
  color: var(--text-light);
  margin-top: 12px;
  line-height: 1.5;
}

/* ===== Contact Section ===== */
.contact {
  padding: 100px 0;
  background: var(--bg);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.contact-info h2 {
  font-size: 2.5rem;
  margin-bottom: 20px;
  color: var(--text);
}

.contact-info > p {
  color: var(--text-light);
  margin-bottom: 32px;
  line-height: 1.8;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: var(--bg-alt);
  border-radius: var(--radius);
}

.contact-item svg {
  width: 24px;
  height: 24px;
  stroke: var(--primary);
  flex-shrink: 0;
}

.contact-item span {
  color: var(--text);
}

.cta-card {
  background: linear-gradient(135deg, var(--primary) 0%, #2d4a6f 50%, #3d5a80 100%);
  margin-top: 100px;
  padding: 48px;
  border-radius: var(--radius-lg);
  color: white;
  text-align: center;
  box-shadow: var(--shadow-xl);
}

.cta-card h3 {
  font-size: 1.75rem;
  margin-bottom: 12px;
}

.cta-card p {
  opacity: 0.9;
  margin-bottom: 24px;
}

.cta-card .btn {
  background: white;
  color: var(--primary);
}

.cta-card .btn:hover {
  background: var(--bg-alt);
}

/* ===== Footer ===== */
.footer {
  background: var(--bg-dark);
  color: white;
  padding: 40px 0;
  margin-top: auto; /* sticky footer – stays at bottom when page is short */
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.footer-brand {
  display: flex;
  align-items: center;
  font-weight: 500;
}

.footer-company {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.footer-name {
  font-weight: 600;
}

.footer-reg {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.65);
}

.footer-details {
  text-align: center;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
}

.footer-details a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  transition: var(--transition);
}

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

.footer-copy {
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.85rem;
  width: 100%;
  text-align: center;
  margin-top: 8px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Contact links */
.contact-item a {
  color: var(--text);
  text-decoration: none;
  transition: var(--transition);
}

.contact-item a:hover {
  color: var(--primary);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .pricing-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Header scrolled state */
.header.scrolled {
  background: rgba(253, 251, 247, 0.97);
  box-shadow: var(--shadow);
}

@media (max-width: 768px) {
  .nav {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: var(--bg);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
  }

  .nav.mobile-open {
    display: flex;
  }

  .nav a {
    font-size: 1.1rem;
    padding: 8px 0;
  }

  .mobile-menu-btn {
    display: flex;
  }

  .mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
  }

  .mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
  }

  .benefits-grid {
    grid-template-columns: 1fr;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-image {
    order: -1;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 360px;
    margin: 0 auto;
  }

  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-stats {
    justify-content: center;
    flex-wrap: wrap;
  }

  .footer-content {
    flex-direction: column;
    gap: 20px;
    text-align: center;
  }

  .footer-brand {
    justify-content: center;
  }

  .footer-details {
    text-align: center;
  }

  .lang-switcher {
    margin-right: 8px;
  }
}

/* ===== Animations ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.benefit-card,
.service-card,
.pricing-card {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.benefit-card.visible,
.service-card.visible,
.pricing-card.visible {
  opacity: 1;
  transform: translateY(0);
}

.benefit-card:nth-child(1) {
  transition-delay: 0.05s;
}

.benefit-card:nth-child(2) {
  transition-delay: 0.1s;
}

.benefit-card:nth-child(3) {
  transition-delay: 0.15s;
}

.service-card:nth-child(1) {
  transition-delay: 0.05s;
}

.service-card:nth-child(2) {
  transition-delay: 0.1s;
}

.service-card:nth-child(3) {
  transition-delay: 0.15s;
}

.service-card:nth-child(4) {
  transition-delay: 0.2s;
}

.pricing-card:nth-child(1) {
  transition-delay: 0.05s;
}

.pricing-card:nth-child(2) {
  transition-delay: 0.1s;
}

.pricing-card:nth-child(3) {
  transition-delay: 0.15s;
}

.pricing-card:nth-child(4) {
  transition-delay: 0.2s;
}

.pricing-card:nth-child(5) {
  transition-delay: 0.25s;
}