/* ═══════════════════════════════════════════════════════════
   Birou Notarial — Stylesheet
   Paleta: Navy profund + Crem cald + Auriu
   Typography: Cormorant Garamond (titluri) + DM Sans (corp)
   ═══════════════════════════════════════════════════════════ */

/* ── Custom Properties ───────────────────────────────────── */
:root {
  /* Culori */
  --c-dark:        #0B1623;
  --c-dark-mid:    #172234;
  --c-dark-card:   rgba(23, 34, 52, 0.6);
  --c-dark-hover:  rgba(23, 34, 52, 0.95);
  --c-cream:       #F6F1E9;
  --c-cream-dark:  #EDE6D9;
  --c-gold:        #C8A456;
  --c-gold-light:  #DEB96A;
  --c-gold-faint:  rgba(200, 164, 86, 0.12);
  --c-gold-dim:    rgba(200, 164, 86, 0.25);
  --c-white:       #FFFFFF;
  --c-text:        #1A1F2C;
  --c-text-mid:    #4B5568;
  --c-text-muted:  #8896A6;

  /* Tipografie */
  --f-display: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --f-body:    'DM Sans', system-ui, -apple-system, sans-serif;

  /* Scală de font */
  --fs-xs:  0.75rem;
  --fs-sm:  0.875rem;
  --fs-md:  1rem;
  --fs-lg:  1.125rem;
  --fs-xl:  1.25rem;
  --fs-2xl: 1.5rem;
  --fs-3xl: 2rem;
  --fs-4xl: 2.75rem;
  --fs-5xl: 3.75rem;

  /* Spațiere */
  --sp-1:  0.25rem;
  --sp-2:  0.5rem;
  --sp-3:  0.75rem;
  --sp-4:  1rem;
  --sp-5:  1.25rem;
  --sp-6:  1.5rem;
  --sp-8:  2rem;
  --sp-10: 2.5rem;
  --sp-12: 3rem;
  --sp-16: 4rem;
  --sp-20: 5rem;
  --sp-24: 6rem;
  --sp-32: 8rem;

  /* Mișcare */
  --ease-out:    cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --dur-fast:    160ms;
  --dur-base:    280ms;
  --dur-slow:    560ms;

  /* Layout */
  --max-w:   1200px;
  --header-h: 70px;
}

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

html {
  font-size: 16px;
  scroll-padding-top: var(--header-h);
}

body {
  font-family: var(--f-body);
  font-size: var(--fs-md);
  line-height: 1.7;
  color: var(--c-text);
  background-color: var(--c-cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }

/* ── Focus ───────────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--c-gold);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ════════════════════════════════════════════════════════════
   HEADER
   ════════════════════════════════════════════════════════════ */
#header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  transition:
    background var(--dur-base) var(--ease-out),
    box-shadow  var(--dur-base) var(--ease-out);
}

#header.is-scrolled {
  background: rgba(11, 22, 35, 0.96);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 rgba(200, 164, 86, 0.18);
}

.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-8);
  height: 100%;
  display: flex;
  align-items: center;
  gap: var(--sp-8);
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  flex-shrink: 0;
}

.logo-mark {
  color: var(--c-gold);
  font-size: var(--fs-xl);
  line-height: 1;
  transition: transform var(--dur-base) var(--ease-out);
}

.logo:hover .logo-mark {
  transform: rotate(45deg);
}

.logo-text {
  font-family: var(--f-display);
  font-size: var(--fs-lg);
  font-weight: 500;
  color: var(--c-white);
  letter-spacing: 0.01em;
}

/* Nav */
nav { flex: 1; }

.nav-list {
  display: flex;
  gap: var(--sp-8);
}

.nav-link {
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.65);
  position: relative;
  padding-bottom: 2px;
  transition: color var(--dur-fast) var(--ease-out);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--c-gold);
  transition: width var(--dur-base) var(--ease-out);
}

.nav-link:hover {
  color: var(--c-white);
}

.nav-link:hover::after {
  width: 100%;
}

/* Header CTA */
.header-cta {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  background: var(--c-gold);
  color: var(--c-dark);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: var(--sp-2) var(--sp-5);
  border-radius: 2px;
  white-space: nowrap;
  flex-shrink: 0;
  transition:
    background  var(--dur-fast) var(--ease-out),
    transform   var(--dur-fast) var(--ease-out),
    box-shadow  var(--dur-fast) var(--ease-out);
}

.header-cta:hover {
  background: var(--c-gold-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(200, 164, 86, 0.35);
}

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--sp-2);
  flex-shrink: 0;
  margin-left: auto;
}

.hamburger-line {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--c-white);
  transform-origin: center;
  transition:
    transform var(--dur-base) var(--ease-out),
    opacity   var(--dur-base) var(--ease-out);
}

#header.nav-open .hamburger-line:nth-child(1) {
  transform: translateY(6.5px) rotate(45deg);
}
#header.nav-open .hamburger-line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
#header.nav-open .hamburger-line:nth-child(3) {
  transform: translateY(-6.5px) rotate(-45deg);
}

/* ════════════════════════════════════════════════════════════
   HERO
   ════════════════════════════════════════════════════════════ */
#hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  background: var(--c-dark);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(11, 22, 35, 0.75) 0%, transparent 18%),
    radial-gradient(ellipse 90% 70% at 40% 50%, rgba(23, 34, 52, 0.9) 0%, transparent 65%),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 59px,
      rgba(200, 164, 86, 0.035) 59px,
      rgba(200, 164, 86, 0.035) 60px
    ),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 59px,
      rgba(200, 164, 86, 0.035) 59px,
      rgba(200, 164, 86, 0.035) 60px
    );
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: calc(var(--header-h) + var(--sp-20)) var(--sp-8) var(--sp-24);
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--c-gold);
  margin-bottom: var(--sp-6);
}

.hero-eyebrow::before {
  content: '';
  display: block;
  width: 28px;
  height: 1px;
  background: var(--c-gold);
}

#hero h1 {
  font-family: var(--f-display);
  font-size: clamp(3.2rem, 9vw, 6.5rem);
  font-weight: 300;
  line-height: 1.05;
  color: var(--c-white);
  margin-bottom: var(--sp-8);
  letter-spacing: -0.01em;
  max-width: 820px;
}

#hero h1 em {
  font-style: italic;
  color: var(--c-gold);
}

.hero-subtitle {
  font-size: var(--fs-lg);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.58);
  line-height: 1.75;
  max-width: 520px;
  margin-bottom: var(--sp-10);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
}

/* Scroll hint */
.hero-scroll-hint {
  position: absolute;
  bottom: var(--sp-10);
  left: 50%;
  transform: translateX(-50%);
}

.scroll-line {
  display: block;
  width: 1px;
  height: 52px;
  background: linear-gradient(to bottom, var(--c-gold), transparent);
  animation: scrollPulse 2.4s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.25; transform: scaleY(0.8) translateY(-4px); }
  50%       { opacity: 0.9;  transform: scaleY(1)   translateY(0); }
}

/* ════════════════════════════════════════════════════════════
   BUTTONS
   ════════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-8);
  font-family: var(--f-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 2px;
  cursor: pointer;
  transition:
    background  var(--dur-base) var(--ease-out),
    border-color var(--dur-base) var(--ease-out),
    color       var(--dur-base) var(--ease-out),
    transform   var(--dur-base) var(--ease-out),
    box-shadow  var(--dur-base) var(--ease-out);
}

.btn-primary {
  background: var(--c-gold);
  color: var(--c-dark);
  border: 1px solid var(--c-gold);
}

.btn-primary:hover {
  background: var(--c-gold-light);
  border-color: var(--c-gold-light);
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(200, 164, 86, 0.35);
}

.btn-outline {
  background: transparent;
  color: var(--c-white);
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.btn-outline:hover {
  border-color: var(--c-gold);
  color: var(--c-gold);
  transform: translateY(-2px);
}

/* ════════════════════════════════════════════════════════════
   SECTIONS — COMMON
   ════════════════════════════════════════════════════════════ */
.section {
  padding: var(--sp-24) 0;
}

.section-dark {
  background: var(--c-dark);
}

.section-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-8);
  position: relative;
}

/* Număr decorativ de fundal */
.section-num {
  position: absolute;
  top: -1.5rem;
  right: var(--sp-8);
  font-family: var(--f-display);
  font-size: clamp(4rem, 10vw, 8rem);
  font-weight: 300;
  line-height: 1;
  color: rgba(200, 164, 86, 0.08);
  user-select: none;
  pointer-events: none;
}

.section-dark .section-num {
  color: rgba(200, 164, 86, 0.07);
}

/* Titlu de secțiune */
.section-heading {
  font-family: var(--f-display);
  font-size: clamp(var(--fs-3xl), 4vw, var(--fs-5xl));
  font-weight: 400;
  line-height: 1.15;
  color: var(--c-text);
  margin-bottom: var(--sp-12);
  position: relative;
  display: inline-block;
}

.section-heading::after {
  content: '';
  position: absolute;
  bottom: calc(-1 * var(--sp-4));
  left: 0;
  width: 44px;
  height: 2px;
  background: var(--c-gold);
}

.section-dark .section-heading {
  color: var(--c-white);
}

/* Fade-in la scroll */
.observe-section {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity   var(--dur-slow) var(--ease-out),
    transform var(--dur-slow) var(--ease-out);
}

.observe-section.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ════════════════════════════════════════════════════════════
   DESPRE
   ════════════════════════════════════════════════════════════ */
.despre-body {
  max-width: 700px;
}

.despre-body p {
  font-family: var(--f-display);
  font-size: clamp(var(--fs-lg), 2.2vw, var(--fs-2xl));
  font-weight: 300;
  line-height: 1.85;
  color: var(--c-text-mid);
}

/* ════════════════════════════════════════════════════════════
   SERVICII
   ════════════════════════════════════════════════════════════ */
.servicii-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: rgba(200, 164, 86, 0.1);
  border: 1px solid rgba(200, 164, 86, 0.1);
}

.service-card {
  background: rgba(17, 28, 43, 0.7);
  padding: var(--sp-8);
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
  position: relative;
  overflow: hidden;
  transition: background var(--dur-base) var(--ease-out);
}

.service-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--c-gold);
  transition: width var(--dur-slow) var(--ease-out);
}

.service-card:hover {
  background: rgba(23, 34, 52, 0.98);
}

.service-card:hover::after {
  width: 100%;
}

.service-icon {
  color: var(--c-gold);
  flex-shrink: 0;
}

.service-name {
  font-family: var(--f-display);
  font-size: var(--fs-xl);
  font-weight: 500;
  color: var(--c-white);
  line-height: 1.25;
}

.service-desc {
  font-size: var(--fs-sm);
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.65;
}

/* ════════════════════════════════════════════════════════════
   PROGRAM
   ════════════════════════════════════════════════════════════ */
.program-wrapper {
  max-width: 500px;
}

.program-table {
  width: 100%;
  border-collapse: collapse;
}

.program-table thead th {
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  text-align: left;
  padding: 0 var(--sp-4) var(--sp-4);
  border-bottom: 1px solid rgba(200, 164, 86, 0.2);
}

.program-table tbody td {
  padding: var(--sp-4);
  border-bottom: 1px solid rgba(200, 164, 86, 0.07);
  color: var(--c-text-mid);
  font-size: var(--fs-md);
  transition: background var(--dur-fast) var(--ease-out);
}

.program-table tbody td:first-child {
  font-weight: 500;
  color: var(--c-text);
  width: 160px;
}

.program-table tbody td:last-child {
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.03em;
}

.program-table tr.is-closed td {
  color: var(--c-text-muted);
  font-style: italic;
}

.program-table tr.is-today td {
  background: var(--c-gold-faint);
}

.program-table tr.is-today td:first-child {
  color: var(--c-gold);
  font-weight: 600;
}

.program-table tr.is-today td:first-child::before {
  content: '▸ ';
  font-size: 0.65em;
  vertical-align: middle;
}

.program-table tr.is-today td:last-child {
  color: var(--c-gold);
  font-weight: 500;
}

/* ════════════════════════════════════════════════════════════
   CONTACT
   ════════════════════════════════════════════════════════════ */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: var(--sp-16);
  align-items: start;
}

.contact-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-10);
}

.contact-item {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.contact-label {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-gold);
}

.contact-value {
  font-family: var(--f-display);
  font-size: var(--fs-xl);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.78);
  padding-left: calc(16px + var(--sp-2));
  line-height: 1.6;
}

.contact-link {
  position: relative;
  color: var(--c-white);
  transition: color var(--dur-fast) var(--ease-out);
}

.contact-link::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 0;
  height: 1px;
  background: var(--c-gold);
  transition: width var(--dur-base) var(--ease-out);
}

.contact-link:hover {
  color: var(--c-gold);
}

.contact-link:hover::after {
  width: 100%;
}

/* Harta */
.map-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(200, 164, 86, 0.18);
}

.map-frame iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.btn-maps {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  margin-top: var(--sp-4);
  padding: var(--sp-3) var(--sp-6);
  border: 1px solid rgba(200, 164, 86, 0.3);
  border-radius: 2px;
  font-size: var(--fs-xs);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--c-gold);
  transition:
    background    var(--dur-base) var(--ease-out),
    border-color  var(--dur-base) var(--ease-out),
    transform     var(--dur-base) var(--ease-out);
}

.btn-maps:hover {
  background: var(--c-gold-faint);
  border-color: var(--c-gold);
  transform: translateY(-1px);
}

/* ════════════════════════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════════════════════════ */
#footer {
  background: #060D15;
  padding: var(--sp-12) 0;
  border-top: 1px solid rgba(200, 164, 86, 0.12);
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-8);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-4);
  text-align: center;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-family: var(--f-display);
  font-size: var(--fs-xl);
  font-weight: 400;
  color: rgba(255, 255, 255, 0.65);
}

.footer-brand .logo-mark {
  font-size: var(--fs-lg);
}

.footer-copy {
  font-size: var(--fs-sm);
  color: rgba(255, 255, 255, 0.28);
}

.footer-location {
  font-size: var(--fs-xs);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.18);
}

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

  .contact-layout {
    grid-template-columns: 1fr;
    gap: var(--sp-12);
  }
}

@media (max-width: 768px) {
  :root {
    --header-h: 60px;
  }

  #header {
    background: rgba(11, 22, 35, 0.96);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
  }

  .header-inner {
    padding: 0 var(--sp-5);
    gap: var(--sp-4);
  }

  /* Nav dropdown mobil */
  nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: rgba(11, 22, 35, 0.98);
    padding: var(--sp-6);
    border-top: 1px solid rgba(200, 164, 86, 0.12);
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition:
      transform var(--dur-base) var(--ease-out),
      opacity   var(--dur-base) var(--ease-out);
    z-index: 99;
  }

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

  .nav-list {
    flex-direction: column;
    gap: var(--sp-5);
  }

  .nav-link {
    font-size: var(--fs-sm);
  }

  .hamburger {
    display: flex;
  }

  .cta-text {
    display: none;
  }

  .header-cta {
    padding: var(--sp-2) var(--sp-3);
  }

  /* Secțiuni */
  .section {
    padding: var(--sp-16) 0;
  }

  .section-inner {
    padding: 0 var(--sp-5);
  }

  .section-num {
    font-size: var(--fs-4xl);
    right: var(--sp-5);
    top: -1rem;
  }

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

  .service-card {
    padding: var(--sp-6);
  }

  .hero-inner {
    padding-left: var(--sp-5);
    padding-right: var(--sp-5);
  }

  .program-wrapper {
    max-width: 100%;
  }
}

@media (max-width: 480px) {
  .hero-actions {
    flex-direction: column;
  }

  .btn {
    justify-content: center;
    width: 100%;
    max-width: 280px;
  }
}

/* ════════════════════════════════════════════════════════════
   REDUCED MOTION
   ════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  .scroll-line {
    animation: none;
    opacity: 0.5;
  }

  .observe-section {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .btn,
  .nav-link,
  .header-cta,
  .service-card,
  .contact-link,
  .btn-maps,
  .logo-mark {
    transition: none;
  }
}
