/* NOVA Facade — site styles */
:root {
  --ink: #14181d;
  --ink-2: #1c2128;
  --ink-3: #262c35;
  --paper: #f6f5f2;
  --paper-2: #ecebe6;
  --text: #1b1f24;
  --muted: #5d6670;
  --muted-dark: #9aa4af;
  --line: rgba(20, 24, 29, .1);
  --line-dark: rgba(255, 255, 255, .1);
  --gold: #c8a46a;
  --gold-2: #b38d50;
  --radius: 14px;
  --header: 72px;
  --shadow: 0 10px 30px rgba(20, 24, 29, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header) + 12px); -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.65 Manrope, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; color: var(--text); background: var(--paper); }
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.15; font-weight: 800; letter-spacing: -.01em; }
h2 { font-size: clamp(28px, 4vw, 42px); }
h3 { font-size: 19px; }
p { margin: 0 0 1em; }
.container { width: min(1200px, 100% - 32px); margin: 0 auto; }
.kicker { margin: 0 0 12px; color: var(--gold-2); font-size: 13px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; }
.muted { color: var(--muted); }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 26px;
  border: 1px solid transparent; border-radius: 999px; font-weight: 700; font-size: 15px; text-decoration: none; cursor: pointer;
  transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: #d6b67f; }
.btn-outline { border-color: rgba(255, 255, 255, .45); color: #fff; }
.btn-outline:hover { border-color: #fff; background: rgba(255, 255, 255, .08); }
.btn-outline-dark { border-color: var(--line); background: #fff; }
.btn-outline-dark:hover { border-color: var(--gold); }
.chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border-radius: 999px; border: 1px solid var(--line-dark);
  font-size: 14px; font-weight: 600; text-decoration: none; transition: border-color .2s, background .2s;
}
.chip:hover { border-color: var(--gold); background: rgba(200, 164, 106, .1); }

/* header */
.header { position: fixed; inset: 0 0 auto; z-index: 50; height: var(--header); color: #fff; background: rgba(20, 24, 29, .72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line-dark); }
.preview-bar ~ .header { top: 40px; }
.header-row { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; flex: none; }
.brand-logo { height: 32px; width: auto; }
canvas.brand-logo { display: block; aspect-ratio: 942 / 269; }
.brand-text { display: flex; padding-left: 12px; border-left: 1px solid var(--line-dark); line-height: 1.3; }
.brand-text small { max-width: 150px; font-size: 11px; color: var(--muted-dark); letter-spacing: .04em; }
.nav { display: flex; gap: 4px; margin-left: auto; }
.header .container { width: min(1320px, 100% - 32px); }
.nav a { padding: 8px 12px; border-radius: 8px; font-size: 15px; font-weight: 600; text-decoration: none; white-space: nowrap; color: rgba(255, 255, 255, .82); }
.nav a:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.header-actions { display: flex; align-items: center; gap: 14px; }
.langs { display: flex; gap: 2px; padding: 3px; border: 1px solid var(--line-dark); border-radius: 999px; }
.langs a { padding: 6px 10px; border-radius: 999px; font-size: 13px; font-weight: 700; text-decoration: none; color: var(--muted-dark); }
.langs a:hover { color: #fff; }
.langs a.active { background: var(--gold); color: var(--ink); }
.header-phone { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.header-phone i { color: var(--gold); }
.menu-toggle { display: none; width: 44px; height: 44px; padding: 12px 10px; border: 1px solid var(--line-dark); border-radius: 10px; background: none; cursor: pointer; flex-direction: column; justify-content: space-between; }
.menu-toggle span { display: block; height: 2px; background: #fff; border-radius: 2px; transition: transform .25s, opacity .25s; }
.nav-open .menu-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
.nav-open .menu-toggle span:nth-child(2) { opacity: 0; }
.nav-open .menu-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
.preview-bar { position: fixed; inset: 0 0 auto; z-index: 60; height: 40px; display: flex; align-items: center; justify-content: center; gap: 10px; background: var(--gold); color: var(--ink); font-size: 14px; font-weight: 600; }

/* hero */
.hero { position: relative; min-height: min(100svh, 920px); display: flex; align-items: flex-end; color: #fff; background: var(--ink); overflow: hidden; }
.hero-bg, .hero-bg img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-bg img { object-fit: cover; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(20, 24, 29, .55) 0%, rgba(20, 24, 29, .35) 40%, rgba(20, 24, 29, .92) 100%); }
.hero-inner { position: relative; z-index: 1; padding: calc(var(--header) + 80px) 0 56px; }
.hero .kicker { color: var(--gold); }
.hero h1 { max-width: 900px; font-size: clamp(36px, 6.2vw, 72px); }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero-text { max-width: 640px; margin: 22px 0 0; font-size: clamp(16px, 2vw, 19px); color: rgba(255, 255, 255, .82); }
.hero-buttons { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
/* hero with the animated logo: black stage, logo on the right, text on the left */
.hero-has-video { background: #000; }
.hero-has-video::after { display: none; }
.hero-video { position: absolute; z-index: 0; top: calc(var(--header) + 4vh); right: max(16px, calc((100% - 1320px) / 2)); width: min(720px, 54%); height: auto; }
.hero-has-video h1, .hero-has-video .hero-text { max-width: min(640px, 46vw); }
.hero-logo { aspect-ratio: 942 / 269; top: 46%; translate: 0 -50%; width: min(600px, 44%); }
.hero-logo canvas { display: block; width: 100%; height: 100%; }
.facts { list-style: none; margin: 48px 0 0; padding: 24px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; border-top: 1px solid var(--line-dark); }
.facts strong { display: block; font-size: 30px; font-weight: 800; color: var(--gold); line-height: 1.1; }
.facts span { font-size: 14px; color: rgba(255, 255, 255, .72); }

/* sections */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section-alt { background: var(--paper-2); }
.section-dark { background: var(--ink); color: #fff; }
.section-dark .kicker { color: var(--gold); }
.section-dark .muted, .section-dark .section-text { color: var(--muted-dark); }
.section-head { max-width: 760px; margin-bottom: 44px; }
.section-text { margin: 16px 0 0; color: var(--muted); font-size: 17px; }

/* about */
.about { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.about-text h2 { margin-bottom: 24px; }
.about-text p { color: var(--muted); font-size: 17px; }
.about-image { margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 4 / 5; }
.about-image img { width: 100%; height: 100%; object-fit: cover; }

/* services */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.service { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.service-icon { display: inline-grid; place-items: center; width: 52px; height: 52px; border-radius: 12px; background: var(--ink); color: var(--gold); font-size: 22px; margin-bottom: 18px; }
.service h3 { margin-bottom: 14px; }
.service ul { margin: 0; padding: 0; list-style: none; }
.service li { position: relative; padding-left: 18px; margin-bottom: 8px; color: var(--muted); font-size: 15px; line-height: 1.55; }
.service li::before { content: ""; position: absolute; left: 0; top: .62em; width: 7px; height: 7px; border-radius: 2px; background: var(--gold); }

/* systems */
.systems { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.system { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.system.is-extra { display: none; }
.systems.show-all .system.is-extra { display: flex; }
.zoom { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.system .zoom { aspect-ratio: 1; background: #fff; }
.system .zoom img { width: 100%; height: 100%; object-fit: contain; padding: 10px; transition: transform .35s; }
.system:hover .zoom img { transform: scale(1.04); }
.system figcaption { padding: 14px 16px 16px; border-top: 1px solid var(--line); font-size: 14px; font-weight: 600; line-height: 1.4; flex: 1; }
.system .num { display: block; margin-bottom: 4px; color: var(--gold-2); font-size: 12px; font-weight: 800; letter-spacing: .1em; }
.more { margin-top: 32px; text-align: center; }

/* nodes */
.nodes { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.node { aspect-ratio: 3 / 4; background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.node img { width: 100%; height: 100%; object-fit: contain; padding: 8px; }

/* projects */
.projects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.project { position: relative; aspect-ratio: 4 / 3; border-radius: var(--radius); overflow: hidden; background: var(--ink-2); text-align: left; }
.project-wide { grid-column: span 2; grid-row: span 2; aspect-ratio: auto; }
.project img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.project:hover img { transform: scale(1.05); }
.project::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(20, 24, 29, .88)); }
.project-caption { position: absolute; left: 18px; right: 18px; bottom: 16px; z-index: 1; color: #fff; }
.project-caption strong { display: block; font-size: 17px; }
.project-caption small { color: var(--muted-dark); font-size: 13px; }
.project-count { position: absolute; top: 12px; right: 12px; z-index: 1; display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; background: rgba(20, 24, 29, .72); color: #fff; font-size: 13px; font-weight: 600; line-height: 1; }
.outro { max-width: 820px; margin: 40px 0 0; color: var(--muted-dark); font-size: 17px; }

/* training */
.training { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.training-image { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.training-image img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.training-text h2 { margin-bottom: 22px; }
.training-text p { color: var(--muted); font-size: 17px; }
.training-text .btn { margin-top: 8px; }
.play { position: absolute; left: 50%; top: 50%; translate: -50% -50%; display: grid; place-items: center; width: 74px; height: 74px; border: 0; border-radius: 50%; background: var(--gold); color: var(--ink); font-size: 24px; cursor: pointer; box-shadow: 0 0 0 10px rgba(200, 164, 106, .25); transition: scale .2s; }
.play:hover { scale: 1.06; }
.play i { margin-left: 4px; }

/* videos */
.videos { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.video { padding: 0; border: 0; background: none; text-align: left; cursor: pointer; }
.video-thumb { position: relative; display: block; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: var(--ink); }
.video-thumb img { width: 100%; height: 100%; object-fit: cover; opacity: .9; transition: opacity .2s; }
.video:hover .video-thumb img { opacity: 1; }
.video .play { width: 60px; height: 60px; font-size: 20px; box-shadow: 0 0 0 8px rgba(200, 164, 106, .25); }
.video-title { display: block; margin-top: 12px; font-weight: 700; line-height: 1.4; }

/* partners */
.partners { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px; }
.partners li { display: grid; place-items: center; height: 104px; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.partners a { display: grid; place-items: center; width: 100%; height: 100%; }
.partners img { max-height: 70px; width: auto; object-fit: contain; }
.partners span { font-weight: 700; text-align: center; }

/* contacts */
.contacts { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 6vw, 72px); }
.contacts-intro h2 { margin-bottom: 8px; }
.socials { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.socials a { display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1px solid var(--line-dark); border-radius: 999px; text-decoration: none; font-size: 14px; font-weight: 600; transition: border-color .2s; }
.socials a:hover { border-color: var(--gold); }
.socials i { color: var(--gold); font-size: 17px; }
.contact-cards { display: grid; gap: 14px; }
.contact-card { padding: 24px; background: var(--ink-2); border: 1px solid var(--line-dark); border-radius: var(--radius); }
.contact-card p { margin: 0 0 6px; }
.contact-card .muted { margin-bottom: 14px; }
.contact-phone { display: inline-block; font-size: clamp(22px, 3vw, 28px); font-weight: 800; text-decoration: none; margin-bottom: 4px; }
.contact-phone:hover { color: var(--gold); }
.contact-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.contact-address > i { color: var(--gold); font-size: 22px; margin-bottom: 12px; display: block; }
.contact-address .chip { margin-top: 10px; }
.contact-address a:not(.chip) { color: var(--gold); }

/* footer */
.footer { background: #0f1216; color: var(--muted-dark); font-size: 14px; padding: 24px 0; }
.footer-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.footer-brand { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; }
.footer-brand img { height: 22px; width: auto; opacity: .85; }
.footer-logo { display: block; width: 78px; height: auto; aspect-ratio: 942 / 269; opacity: .9; }
.to-top { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--line-dark); border-radius: 50%; text-decoration: none; color: #fff; flex: none; }
.to-top:hover { border-color: var(--gold); }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 100; display: grid; grid-template-columns: 64px 1fr 64px; grid-template-rows: 1fr auto; align-items: center; background: rgba(10, 12, 15, .94); color: #fff; touch-action: pan-y pinch-zoom; }
.lightbox[hidden] { display: none; }
.lb-stage { grid-column: 2; margin: 0; height: calc(100svh - 120px); display: grid; grid-template: minmax(0, 100%) / minmax(0, 100%); place-items: center; }
.lb-stage img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; background: #fff; }
.lb-stage iframe { width: min(100%, calc((100svh - 140px) * 16 / 9)); aspect-ratio: 16 / 9; border: 0; border-radius: 8px; background: #000; }
.lb-caption { grid-column: 1 / -1; margin: 0; padding: 0 16px 20px; text-align: center; font-weight: 600; min-height: 1.6em; }
.lightbox button { display: grid; place-items: center; width: 48px; height: 48px; border: 1px solid rgba(255, 255, 255, .2); border-radius: 50%; background: rgba(255, 255, 255, .06); color: #fff; font-size: 18px; cursor: pointer; justify-self: center; }
.lightbox button:hover { border-color: var(--gold); color: var(--gold); }
.lb-close { position: absolute; top: 16px; right: 16px; z-index: 2; }
.lightbox.single .lb-prev, .lightbox.single .lb-next { visibility: hidden; }
.lb-count { margin-left: 10px; color: var(--muted-dark); font-weight: 400; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* responsive */
@media (max-width: 1340px) {
  .header-phone span { display: none; }
  .header-phone { width: 44px; height: 44px; justify-content: center; border: 1px solid var(--line-dark); border-radius: 10px; }
}
@media (max-width: 1200px) {
  .nav a { padding: 8px 9px; }
  .systems { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 1140px) {
  .menu-toggle { display: flex; }
  .nav { position: fixed; top: var(--header); left: 0; right: 0; flex-direction: column; gap: 0; padding: 8px 16px 20px; background: var(--ink); border-bottom: 1px solid var(--line-dark); transform: translateY(-110%); visibility: hidden; transition: transform .3s, visibility .3s; }
  .preview-bar ~ .header .nav { top: calc(var(--header) + 40px); }
  .nav-open .nav { transform: none; visibility: visible; }
  .nav a { padding: 14px 4px; font-size: 17px; border-bottom: 1px solid var(--line-dark); border-radius: 0; }
  .header-actions { margin-left: auto; }
  .hero-has-video { display: block; min-height: 0; }
  .hero-video { position: static; display: block; width: 100%; max-width: 640px; margin: var(--header) auto 0; }
  .hero-logo { translate: none; width: calc(100% - 48px); max-width: 520px; margin: calc(var(--header) + 56px) auto 40px; }
  .hero-has-video .hero-inner { padding-top: 8px; }
  .hero-has-video h1, .hero-has-video .hero-text { max-width: none; }
  .about, .training, .contacts { grid-template-columns: 1fr; }
  .about-image { aspect-ratio: 16 / 10; }
  .services { grid-template-columns: repeat(2, 1fr); }
  .projects { grid-template-columns: repeat(2, 1fr); }
  .project-wide { grid-row: auto; aspect-ratio: 16 / 9; }
  .facts { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  :root { --header: 64px; }
  .brand-text { display: none; }
  .brand-logo { height: 26px; }
  .header-row { gap: 10px; }
  .header-actions { gap: 8px; }
  .langs a { padding: 6px 7px; font-size: 12px; }
  .services { grid-template-columns: 1fr; }
  .systems { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .system figcaption { padding: 10px 12px 12px; font-size: 13px; }
  .projects { grid-template-columns: 1fr; }
  .project-wide { grid-column: auto; grid-row: auto; aspect-ratio: 4 / 3; }
  .nodes { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .hero-buttons .btn { flex: 1 1 100%; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .facts strong { font-size: 24px; }
  .lightbox { grid-template-columns: 1fr; grid-template-rows: 1fr auto auto; }
  .lb-stage { grid-column: 1; height: calc(100svh - 150px); padding: 0 8px; }
  .lb-prev, .lb-next { grid-row: 3; position: absolute; bottom: 16px; }
  .lb-prev { left: 16px; }
  .lb-next { right: 16px; }
  .lb-caption { padding: 0 72px 28px; }
}
@media (max-width: 380px) {
  .brand-logo { height: 22px; }
  .header-phone { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
