/* ==========================================================================
   Andoria revamp layer — loaded AFTER styles.css on every page.
   Only overrides / additions; the original layout rules keep working.
   ========================================================================== */
:root {
  --font-display: 'Syne', 'Manrope', -apple-system, 'Segoe UI', sans-serif;
  --rv-ease: cubic-bezier(.2, .8, .2, 1);
  --rv-amber: #f2b632;
  --rv-green-0: #04100b;
  --rv-green-1: #071a12;
  --rv-line: rgba(232, 228, 220, .12);
  --header-h: 84px;
}
html { scroll-behavior: auto; background: var(--rv-green-1); }
body { background: var(--rv-green-1); overflow-x: clip; }
::selection { background: var(--rv-amber); color: #071a12; }
h1, h2, h3, h4 { font-weight: 700; letter-spacing: -.02em; }
html[dir="rtl"] h1, html[dir="rtl"] h2, html[dir="rtl"] h3, html[dir="rtl"] h4 { letter-spacing: 0; }

/* film grain over everything — one static tiled data-URI, no per-frame cost */
body::after { display: none; }

/* ---------- header ---------- */
.site-header { transition: transform .5s var(--rv-ease), background .3s ease, box-shadow .3s ease; }
.site-header.hide { transform: translateY(-110%); }
.site-header.scrolled { background: rgba(4, 16, 11, .82); box-shadow: 0 1px 0 var(--rv-line); }
.header-inner { min-height: var(--header-h); }
.brand-text small { color: rgba(232, 228, 220, .55); letter-spacing: .05em; }
.main-nav a { font-family: var(--font-display); font-weight: 600; font-size: .95rem; letter-spacing: .01em; }

/* ---------- buttons: cut-corner, amber sweep ---------- */
.btn { border-radius: 4px; text-transform: uppercase; letter-spacing: .09em; font-size: .78rem; font-weight: 800; padding: 16px 30px; position: relative; overflow: hidden; isolation: isolate; font-family: var(--font-display);
  clip-path: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px)); border: 0; }
html[dir="rtl"] .btn { letter-spacing: 0; font-size: .92rem; }
.btn-primary { background: var(--rv-amber); color: #071a12; box-shadow: none; }
.btn-primary::before { content: ""; position: absolute; inset: 0; z-index: -1; background: #fff; transform: translateX(-101%); transition: transform .45s var(--rv-ease); }
.btn-primary:hover { background: var(--rv-amber); box-shadow: none; transform: none; }
.btn-primary:hover::before { transform: none; }
.btn-hero-glow { box-shadow: none; padding: 18px 34px; font-size: .82rem; }
.btn-hero-glow::after { display: none; }
.btn-outline { background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1.5px rgba(232, 228, 220, .4); color: var(--color-ink); }
.btn-outline:hover { background: rgba(255, 255, 255, .14); }
.btn-ghost { background: transparent; box-shadow: inset 0 0 0 1.5px rgba(232, 228, 220, .35); color: #fff; }
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--rv-amber); color: var(--rv-amber); }
.btn.mag { will-change: transform; }

/* ---------- section language ---------- */
.section-kicker { display: inline-flex; align-items: center; gap: 12px; font-family: var(--font-display); font-size: .72rem; letter-spacing: .22em; color: var(--rv-amber); }
.section-kicker::before { content: ""; width: 34px; height: 1.5px; background: currentColor; }
html[dir="rtl"] .section-kicker { letter-spacing: 0; }
.section-title, section h2 { font-size: clamp(2rem, 4.4vw, 3.6rem); line-height: 1.02; max-width: 16ch; }
.section-title { max-width: 18ch; }
section.section { padding: clamp(72px, 10vw, 140px) 0; }
.section-alt { background: var(--rv-green-0); }
.section-dark { background: var(--rv-green-0); }
.section-store { background: linear-gradient(180deg, #071a12, #0a2216); border: 0; }
.section-store::before, .section-store::after { display: none; }

/* fading borders — technique 1 (static) */
.fade-in-top, .fade-out-bottom { position: absolute; inset-inline: 0; height: 18vh; pointer-events: none; z-index: 1; }
.fade-in-top { top: 0; background: linear-gradient(to bottom, var(--fade-from, #04100b), transparent); }
.fade-out-bottom { bottom: 0; background: linear-gradient(to top, var(--fade-to, #04100b), transparent); }

/* ---------- reveal (upgrade of the old fade-up) ---------- */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity .9s var(--rv-ease), transform .9s var(--rv-ease); }
.reveal.in-view { opacity: 1; transform: none; }
.reveal:nth-child(2) { transition-delay: .08s; } .reveal:nth-child(3) { transition-delay: .16s; } .reveal:nth-child(4) { transition-delay: .24s; }

/* split-text letters / words */
.split .wd { display: inline-block; white-space: nowrap; }
.split .sp { display: inline-block; opacity: 0; transform: translateY(.55em) rotate(3deg); transition: opacity .7s var(--rv-ease), transform .9s var(--rv-ease); transition-delay: calc(var(--i) * 22ms); }
.split.in .sp { opacity: 1; transform: none; }
html[dir="rtl"] .split .sp { transition-delay: calc(var(--i) * 70ms); margin-inline: 0 .18em; }

/* ---------- cards ---------- */
.why-card, .branch-card, .product-card, .about-stat { background: rgba(255, 255, 255, .03); border: 1px solid var(--rv-line); border-radius: 6px; transition: border-color .4s ease, background .4s ease, transform .5s var(--rv-ease); }
.why-card:hover, .branch-card:hover, .product-card:hover { border-color: rgba(242, 182, 50, .55); background: rgba(242, 182, 50, .05); transform: translateY(-4px); }

/* ---------- footer ---------- */
.site-footer { background: var(--rv-green-0); border-top: 1px solid var(--rv-line); }

/* ---------- custom cursor ---------- */
html.rv-cursor, html.rv-cursor * { cursor: none !important; }
.rv-cur-dot, .rv-cur-ring { position: fixed; left: 0; top: 0; z-index: 99999; pointer-events: none; will-change: transform; }
.rv-cur-dot::before { content: ""; display: block; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; background: var(--rv-amber); }
.rv-cur-ring::before { content: ""; display: block; width: 38px; height: 38px; margin: -19px 0 0 -19px; border-radius: 50%; border: 1.5px solid rgba(242, 182, 50, .6); transition: transform .3s var(--rv-ease), background .3s ease, border-color .3s ease; }
.rv-cur-ring.hot::before { transform: scale(1.7); background: rgba(242, 182, 50, .12); border-color: var(--rv-amber); }
.rv-cur-ring.down::before { transform: scale(.7); }
@media (hover: none), (pointer: coarse) { .rv-cur-dot, .rv-cur-ring { display: none; } }

/* ---------- misc ---------- */
.social-fab { z-index: 90; }
.back-to-top { border-radius: 4px; }
:focus-visible { outline: 2px solid var(--rv-amber); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) {
  .reveal, .split .sp { transition: none !important; opacity: 1 !important; transform: none !important; }
  body::after { display: none; }
}

/* ---------- inner-page banner: contour canvas + split title ---------- */
.page-banner { position: relative; overflow: hidden; background: #04100b; }
.page-banner .hero-bg { opacity: .35; }
.page-banner .rv-contours { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; }
.page-banner-inner { z-index: 2; }
.page-banner h1 { font-size: clamp(2.4rem, 6vw, 4.8rem); line-height: 1; letter-spacing: -.03em; }
.page-banner::after { content: ""; position: absolute; inset-inline: 0; bottom: 0; height: 22%; background: linear-gradient(to bottom, transparent, var(--rv-green-1)); pointer-events: none; }

/* ---------- generator 3D viewer (machinery page) ---------- */
.gen-viewer-sec { background: radial-gradient(80% 60% at 50% 40%, #0b2a1c, #04100b); }
.gv-head { max-width: 38rem; margin-bottom: 2rem; }
.gv { position: relative; height: clamp(360px, 62vh, 640px); border: 1px solid var(--rv-line); border-radius: 6px; overflow: hidden; touch-action: pan-y; cursor: grab;
  background: radial-gradient(70% 70% at 50% 45%, rgba(31, 107, 71, .35), rgba(4, 16, 11, .9)); }
.gv.drag { cursor: grabbing; }
.gv canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.gv-status { position: absolute; inset: 0; display: grid; place-items: center; color: var(--rv-amber); font: 700 .74rem var(--font-display); letter-spacing: .3em; text-transform: uppercase; }
.gv-btns { position: absolute; inset-inline-start: 16px; bottom: 16px; display: flex; gap: 6px; flex-wrap: wrap; }
.gv-btns button { padding: 9px 14px; font: 700 .7rem var(--font-display); letter-spacing: .12em; text-transform: uppercase; color: #fff; background: rgba(4, 16, 11, .7); border: 1px solid var(--rv-line); border-radius: 3px; cursor: pointer; transition: border-color .25s, color .25s; }
.gv-btns button:hover { border-color: var(--rv-amber); color: var(--rv-amber); }
.gv-hint { position: absolute; inset-inline-end: 16px; bottom: 20px; font: 600 .68rem var(--font-display); letter-spacing: .2em; text-transform: uppercase; color: rgba(232, 228, 220, .5); pointer-events: none; }
.gv.no-webgl::after { content: ""; position: absolute; inset: 0; background: url(img/poster.jpg) center / cover; }

/* revamp fixes */
.brand-logo-img { width: 56px !important; height: 56px !important; border-radius: 50%; object-fit: cover; }
.btn-ghost { clip-path: none; border-radius: 4px; box-shadow: none; border: 1.5px solid rgba(232, 228, 220, .4); }
.btn-ghost:hover { box-shadow: none; border-color: var(--rv-amber); }
.page-banner-inner { max-width: var(--container-w); margin-inline: auto; }

/* ---------- catalog search bar ---------- */
.catalog-toolbar { background: rgba(4, 16, 11, .82); border-bottom: 1px solid var(--rv-line); }
.catalog-search { position: relative; gap: 14px; padding: 0 18px; min-height: 58px; border-radius: 4px; overflow: hidden; color: var(--rv-amber);
  background: linear-gradient(90deg, rgba(242, 182, 50, .07), rgba(255, 255, 255, .03) 40%); border: 1px solid var(--rv-line); box-shadow: none;
  transition: border-color .35s, background .35s; }
.catalog-search:hover { border-color: rgba(242, 182, 50, .45); }
.catalog-search::before { content: ""; position: absolute; inset-inline: 0; bottom: 0; height: 2px; background: var(--rv-amber); transform: scaleX(0); transform-origin: 0 50%; transition: transform .55s var(--rv-ease); }
html[dir="rtl"] .catalog-search::before { transform-origin: 100% 50%; }
.catalog-search:focus-within { border-color: rgba(242, 182, 50, .6); background: linear-gradient(90deg, rgba(242, 182, 50, .12), rgba(255, 255, 255, .05) 50%); box-shadow: none; }
.catalog-search:focus-within::before { transform: scaleX(1); }
/* replace the old pulsing glow with a "/" shortcut hint */
.catalog-search::after { content: "/"; position: static; inset: auto; z-index: auto; animation: none; opacity: 1; box-shadow: none; border-radius: 3px;
  margin-inline-start: auto; order: 3; padding: 2px 9px; font: 700 .78rem var(--font-display); color: rgba(232, 228, 220, .55); border: 1px solid var(--rv-line); background: rgba(255, 255, 255, .04); transition: opacity .3s; }
.catalog-search:focus-within::after { opacity: 0; }
.catalog-search svg { width: 20px; height: 20px; flex: none; }
.catalog-search input { color: var(--color-ink); font-family: var(--font-display); font-weight: 600; font-size: 1rem; letter-spacing: .01em; padding: 18px 0; }
html[dir="rtl"] .catalog-search input { font-family: var(--font-arabic); }
.catalog-search input::placeholder { color: rgba(232, 228, 220, .45); opacity: 1; }
.catalog-search input::-webkit-search-cancel-button { -webkit-appearance: none; height: 16px; width: 16px; cursor: pointer; opacity: .7;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f2b632' stroke-width='2.4' stroke-linecap='round'><path d='M6 6l12 12M18 6L6 18'/></svg>") center / contain no-repeat; }
@media (hover: none) { .catalog-search::after { display: none; } }

/* search bar: always in view, follows the page (sticks under the header, or to the top while the header is hidden) */
.catalog-toolbar { top: calc(var(--header-h) - 1px); z-index: 60; transition: top .5s var(--rv-ease), box-shadow .3s; background: rgba(4, 16, 11, .96); box-shadow: 0 12px 28px -12px rgba(0, 0, 0, .7); padding: 12px 24px; }
body.hdr-hidden .catalog-toolbar { top: 0; }
.catalog-search { min-height: 64px; border: 1.5px solid rgba(242, 182, 50, .55); background: linear-gradient(90deg, rgba(242, 182, 50, .16), rgba(255, 255, 255, .06) 55%); box-shadow: 0 0 0 1px rgba(242, 182, 50, .08), 0 8px 24px -10px rgba(242, 182, 50, .35); }
.catalog-search svg { width: 22px; height: 22px; color: var(--rv-amber); }
.catalog-search input { font-size: 1.08rem; color: #fff; }
.catalog-search input::placeholder { color: rgba(232, 228, 220, .7); }
.catalog-search:focus-within { border-color: var(--rv-amber); box-shadow: 0 0 0 3px rgba(242, 182, 50, .22), 0 10px 30px -8px rgba(242, 182, 50, .5); }
@media (max-width: 720px) { .catalog-toolbar { padding: 8px 16px; } .catalog-search { min-height: 54px; } }

/* perf: no backdrop blur over live/animated content (re-blurs every frame) */
.site-header.scrolled, .catalog-toolbar { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
.site-header.scrolled { background: rgba(4, 16, 11, .94); }
