/* ── VARIABLES ── */
:root {
  --bg:      #f4f6f9;
  --bg2:     #ebeef4;
  --bg3:     #ffffff;
  --line:    rgba(0,0,0,0.09);
  --accent:  #0a9e6e;
  --accent-bright: #2ee8a5;
  --text:    #0d1117;
  --muted:   #374151;
  --subtle:  #6b7280;
  --white:   #ffffff;
  --card:    #ffffff;
  --nav-bg:  #0d1117;
}

/* ── RESET ── */
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Lato', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 1.75;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Subtle grid overlay */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,0,0,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.035) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
  z-index: 0;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 48px;
  height: 64px;
  background: var(--nav-bg);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.nav-logo {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.08em;
  color: #ffffff;
  text-transform: uppercase;
  text-decoration: none;
}

.nav-logo span { color: var(--accent-bright); }

.nav-right {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
}

.nav-links a {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--accent-bright); }

.lang-toggle {
  display: flex;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 4px;
  overflow: hidden;
}

.lang-btn {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  padding: 5px 12px;
  cursor: pointer;
  border: none;
  background: transparent;
  color: rgba(255,255,255,0.5);
  transition: all 0.2s;
}

.lang-btn.active {
  background: var(--accent-bright);
  color: var(--nav-bg);
}

/* ── SECTIONS ── */
section {
  position: relative;
  z-index: 1;
}

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

/* ── HERO — keeps dark for impact ── */
#hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 64px;
  background: var(--nav-bg);
  border-bottom: 3px solid var(--accent);
  position: relative;
}

#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 100px 48px;
  max-width: 800px;
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 1;
}

.hero-inner h1 { max-width: 680px; }
.hero-inner .hero-sub { max-width: 560px; }

.hero-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-bright);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.hero-label::before {
  content: '';
  width: 32px;
  height: 1px;
  background: var(--accent-bright);
  display: inline-block;
}

h1 {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: clamp(42px, 5vw, 72px);
  line-height: 1.2;
  letter-spacing: -0.03em;
  color: #ffffff;
  margin-bottom: 28px;
  padding-bottom: 0.15em;
}

h1 .highlight { color: var(--accent-bright); }

.hero-sub {
  font-size: 18px;
  line-height: 1.75;
  color: rgba(255,255,255,0.72);
  max-width: 480px;
  margin-bottom: 48px;
  font-weight: 400;
}

.hero-cta {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* ── BUTTONS ── */
.btn-primary {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 14px 28px;
  background: var(--accent-bright);
  color: var(--nav-bg);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  font-weight: 500;
  display: inline-block;
}

.btn-primary:hover { background: #ffffff; color: var(--nav-bg); }

.btn-secondary {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 14px 28px;
  background: transparent;
  color: rgba(255,255,255,0.7);
  border: 1px solid rgba(255,255,255,0.2);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  display: inline-block;
}

.btn-secondary:hover {
  border-color: var(--accent-bright);
  color: var(--accent-bright);
}

/* ── HERO PANEL ── */
.hero-panel {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.12);
  padding: 32px;
  position: relative;
}

.panel-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.panel-row:last-child { border-bottom: none; }

.panel-key {
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: 0.16em;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
}

.panel-val {
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  color: rgba(255,255,255,0.88);
  line-height: 1.5;
  word-break: break-word;
}

.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-bright);
  margin-right: 8px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

/* ── SHARED SECTION STYLES ── */
.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

h2 {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: clamp(28px, 3.5vw, 48px);
  line-height: 1.2;
  letter-spacing: -0.03em;
  color: var(--text);
  margin-bottom: 32px;
  padding-bottom: 0.15em;
}

/* ── ABOUT ── */
#about {
  padding: 120px 0;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}

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

.about-text p {
  font-size: 16px;
  line-height: 1.85;
  color: var(--muted);
  margin-bottom: 20px;
}

.about-text p strong {
  color: var(--text);
  font-weight: 700;
}

/* ── STRATEGIC TRIANGLE ── */
.triangle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 2px;
}

.tri-node {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 24px;
  position: relative;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.tri-node.full { grid-column: 1 / -1; }

.tri-flag {
  font-size: 24px;
  margin-bottom: 8px;
  display: block;
}

.tri-name {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  margin-bottom: 6px;
}

.tri-desc {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: var(--subtle);
  line-height: 1.6;
  letter-spacing: 0.05em;
}

.tri-node::after {
  content: attr(data-num);
  position: absolute;
  top: 12px;
  right: 14px;
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  color: var(--accent);
  letter-spacing: 0.1em;
}

/* ── PRODUCTS ── */
#products {
  padding: 120px 0;
  border-bottom: 1px solid var(--line);
  background: var(--bg2);
}

.products-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: 56px;
}

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

.product-card {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.3s;
  text-decoration: none;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.product-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 16px rgba(10,158,110,0.1);
}

.product-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.product-card:hover::before { transform: scaleX(1); }

.product-num {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.15em;
  color: var(--accent);
}

.product-name {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 24px;
  color: var(--text);
  letter-spacing: -0.01em;
}

.product-tagline {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--accent);
  text-transform: uppercase;
}

.product-desc {
  font-size: 15px;
  line-height: 1.75;
  color: var(--muted);
  flex-grow: 1;
}

.product-link {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--subtle);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  transition: color 0.2s;
}

.product-card:hover .product-link { color: var(--accent); }

.product-link::after {
  content: '→';
  transition: transform 0.2s;
}

.product-card:hover .product-link::after { transform: translateX(4px); }

/* ── BLOG PREVIEW ── */
#blog-preview {
  padding: 120px 0;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  margin-top: 56px;
}

.blog-card {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: border-color 0.3s, box-shadow 0.3s;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.blog-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 16px rgba(10,158,110,0.08);
}

.blog-tag {
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 4px 10px;
  border: 1px solid rgba(10,158,110,0.3);
  width: fit-content;
  background: rgba(10,158,110,0.05);
}

.blog-title {
  font-family: 'Manrope', sans-serif;
  font-weight: 600;
  font-size: 17px;
  line-height: 1.35;
  color: var(--text);
}

.blog-excerpt {
  font-size: 14px;
  line-height: 1.75;
  color: var(--muted);
  flex-grow: 1;
}

.blog-meta {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--subtle);
  letter-spacing: 0.08em;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

/* ── CONTACT ── */
#contact {
  padding: 120px 0;
  background: var(--bg2);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  margin-top: 56px;
}

.legal-panel {
  background: var(--white);
  border: 1px solid var(--line);
  padding: 40px;
  position: relative;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.legal-panel::before {
  content: 'LEGAL_ENTITY';
  font-family: 'DM Mono', monospace;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: var(--accent);
  position: absolute;
  top: -1px;
  left: 20px;
  background: var(--white);
  padding: 0 8px;
  transform: translateY(-50%);
}

.legal-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}

.legal-row:last-child { border-bottom: none; }

.legal-key {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--subtle);
}

.legal-val {
  font-family: 'DM Mono', monospace;
  font-size: 14px;
  color: var(--text);
  line-height: 1.6;
}

.legal-val a {
  color: var(--accent);
  text-decoration: none;
}

/* ── CONTACT FORM ── */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
}

input, textarea, select {
  background: var(--white);
  border: 1px solid rgba(0,0,0,0.15);
  color: var(--text);
  padding: 13px 16px;
  font-family: 'Lato', sans-serif;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  width: 100%;
}

input::placeholder, textarea::placeholder { color: #aab0bc; }

input:focus, textarea:focus, select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(10,158,110,0.1);
}

select option { background: var(--white); color: var(--text); }
textarea { min-height: 130px; resize: vertical; }

button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.form-status {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.08em;
  padding: 12px 16px;
  border-left: 3px solid;
}

.form-status.sending { border-color: var(--accent); color: var(--subtle); background: rgba(10,158,110,0.04); }
.form-status.success { border-color: var(--accent); color: var(--accent); background: rgba(10,158,110,0.06); }
.form-status.error   { border-color: #dc2626; color: #dc2626; background: rgba(220,38,38,0.05); }

.form-privacy {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--subtle);
  letter-spacing: 0.06em;
  line-height: 1.6;
  margin-top: 4px;
}

/* ── FOOTER ── */
footer {
  background: var(--nav-bg);
  border-top: 3px solid var(--accent);
  padding: 40px 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 1;
}

.footer-brand {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
}

.footer-brand span { color: var(--accent-bright); }

.footer-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-links a {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  text-decoration: none;
  transition: color 0.2s;
}

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

.footer-copy {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.08em;
}

/* ── REVEAL ANIMATION ── */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ── HAMBURGER ── */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: rgba(255,255,255,0.7);
  transition: all 0.3s ease;
  border-radius: 1px;
}

.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav drawer */
.mobile-nav {
  display: none;
  position: fixed;
  top: 64px; left: 0; right: 0;
  background: var(--nav-bg);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  z-index: 99;
  padding: 24px;
  flex-direction: column;
  gap: 0;
}

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

.mobile-nav a {
  font-family: 'DM Mono', monospace;
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  padding: 16px 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
  transition: color 0.2s;
}

.mobile-nav a:last-of-type { border-bottom: none; }
.mobile-nav a:hover { color: var(--accent-bright); }

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  nav { padding: 0 20px; }
  .nav-links { display: none; }
  .hamburger { display: flex; }

  .container { padding: 0 20px; }

  /* Hero */
  .hero-inner { padding: 60px 20px 80px; max-width: 100%; }

  h1 { font-size: clamp(28px, 7vw, 48px); }
  h2 { font-size: clamp(22px, 5.5vw, 34px); }

  .hero-sub { font-size: 16px; max-width: 100%; }

  /* About */
  #about { padding: 80px 0; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }

  /* Triangle */
  .triangle { grid-template-columns: 1fr; }
  .tri-node.full { grid-column: auto; }

  /* Products */
  #products { padding: 80px 0; }
  .products-grid { grid-template-columns: 1fr; }

  /* Blog */
  #blog-preview { padding: 80px 0; }
  .blog-grid { grid-template-columns: 1fr; }

  /* Contact */
  #contact { padding: 80px 0; }
  .contact-grid { grid-template-columns: 1fr; gap: 40px; }

  /* Footer */
  footer {
    flex-direction: column;
    gap: 20px;
    text-align: center;
    padding: 32px 20px;
  }
  .footer-links { flex-wrap: wrap; justify-content: center; }
}

@media (max-width: 480px) {
  .hero-cta { flex-direction: column; }
  .hero-cta a { text-align: center; width: 100%; }
  .legal-panel { padding: 24px 16px; }
  .product-card { padding: 24px 16px; }
  .blog-card { padding: 20px 16px; }
  .contact-form { gap: 12px; }

  /* Prevent any child from overflowing the viewport */
  * { max-width: 100%; }
  img, table, pre, code { overflow-x: auto; }
}
