/*
Theme Name: Технореплика
Theme URI: https://example.com
Author: Технореплика
Description: Промышленный тёмный дизайн в стиле HUD/техно для инженерного бюро — проектирование механизмов и производство деталей-реплик. Одностраничный сайт с калькулятором стоимости, WhatsApp-кнопками и видео о деятельности.
Version: 1.2
Requires at least: 5.9
Requires PHP: 7.4
Text Domain: tehnoreplika
*/

:root{
    --void:#0a0a0b;
    --panel:#17181b;
    --panel-2:#1f2124;
    --line:#2b2e32;
    --steel:#9aa0a8;
    --steel-light:#d7dade;
    --red:#ff2020;
    --red-dim:#7a0808;
    --amber:#ffb020;
    --radius:2px;
    --font-display:'Rajdhani',sans-serif;
    --font-body:'Inter',sans-serif;
    --font-mono:'Share Tech Mono',monospace;
  }

  *{box-sizing:border-box;}
  html{scroll-behavior:smooth;}
  body{
    margin:0;
    background:var(--void);
    color:var(--steel-light);
    font-family:var(--font-body);
    line-height:1.6;
    -webkit-font-smoothing:antialiased;
  }
  img,svg{max-width:100%;display:block;}

  a{color:inherit;}
  h1,h2,h3{
    font-family:var(--font-display);
    font-weight:700;
    letter-spacing:.02em;
    margin:0;
    color:#fff;
  }

  .wrap{max-width:1180px;margin:0 auto;padding:0 24px;}

  ::selection{background:var(--red-dim);color:#fff;}

  :focus-visible{
    outline:2px solid var(--red);
    outline-offset:3px;
  }

  body.nav-open{
    overflow:hidden;
    height:100dvh;
  }

  /* ---------- background metal texture ---------- */
  .metal-bg{
    background-image:
      repeating-linear-gradient(0deg, rgba(255,255,255,.015) 0 1px, transparent 1px 3px),
      linear-gradient(180deg, var(--void), #0d0e10);
  }

  /* ---------- header ---------- */
  header{
    position:sticky; top:0; z-index:50;
    background:rgba(10,10,11,.97);
    border-bottom:1px solid var(--line);
  }
  .header-inner{
    display:flex; align-items:center; justify-content:space-between;
    height:76px;
  }
  .brand{display:flex; align-items:center; gap:12px; text-decoration:none;}
  .brand svg{width:38px;height:38px;flex-shrink:0;}
  .brand-word{
    font-family:var(--font-display);
    font-weight:700;
    font-size:1.28rem;
    color:#fff;
    letter-spacing:.03em;
    line-height:1;
  }
  .brand-word span{color:var(--red);}
  .brand-sub{
    display:block;
    font-family:var(--font-mono);
    font-size:.6rem;
    color:var(--steel);
    letter-spacing:.12em;
    margin-top:3px;
  }

  nav.main-nav{display:flex; gap:32px;}
  nav.main-nav a{
    text-decoration:none;
    color:var(--steel);
    font-size:.95rem;
    font-weight:500;
    transition:color .15s;
  }
  nav.main-nav a:hover{color:#fff;}

  .btn{
    display:inline-flex; align-items:center; gap:10px;
    font-family:var(--font-display);
    font-weight:600;
    font-size:1rem;
    letter-spacing:.02em;
    padding:12px 22px;
    border-radius:var(--radius);
    text-decoration:none;
    border:1px solid transparent;
    cursor:pointer;
    transition:transform .12s ease, background .15s, border-color .15s;
  }
  .btn:active{transform:scale(.97);}
  .btn-red{
    background:var(--red);
    color:#0a0a0a;
  }
  .btn-red:hover{background:#ff4040;}
  .btn-ghost{
    background:transparent;
    color:var(--steel-light);
    border-color:var(--line);
  }
  .btn-ghost:hover{border-color:var(--steel);}
  .header-cta{display:flex; align-items:center; gap:18px;}
  .header-cta .btn{padding:10px 18px; font-size:.9rem;}
  .nav-toggle{display:none;}

  /* ---------- hero ---------- */
  .hero{
    position:relative;
    padding:96px 0 110px;
    overflow:hidden;
    border-bottom:1px solid var(--line);
  }
  .hero-grid{
    position:absolute; inset:0;
    background-image:
      linear-gradient(rgba(255,32,32,.06) 1px, transparent 1px),
      linear-gradient(90deg, rgba(255,32,32,.06) 1px, transparent 1px);
    background-size:44px 44px;
    mask-image:radial-gradient(ellipse 70% 60% at 70% 30%, #000 40%, transparent 85%);
    pointer-events:none;
  }
  .scan-line{
    position:absolute; left:0; right:0; height:2px;
    background:linear-gradient(90deg, transparent, var(--red), transparent);
    box-shadow:0 0 14px 2px rgba(255,32,32,.6);
    animation:scan 6s linear infinite;
    opacity:.7;
  }
  @keyframes scan{
    0%{top:-5%;}
    100%{top:105%;}
  }
  @media (prefers-reduced-motion: reduce){
    .scan-line{animation:none; display:none;}
  }

  .hero-inner{position:relative; display:grid; grid-template-columns:1.15fr .85fr; gap:56px; align-items:center;}
  .hero-tag{
    font-family:var(--font-mono);
    font-size:.72rem;
    letter-spacing:.15em;
    color:var(--red);
    display:flex; align-items:center; gap:10px;
    margin-bottom:22px;
  }
  .hero-tag::before{
    content:"";
    width:8px;height:8px;border-radius:50%;
    background:var(--red);
    box-shadow:0 0 8px 2px rgba(255,32,32,.8);
  }
  .hero h1{
    font-size:clamp(2.4rem, 4.6vw, 3.6rem);
    line-height:1.06;
    max-width:14ch;
  }
  .hero p.lead{
    margin-top:22px;
    font-size:1.08rem;
    color:var(--steel);
    max-width:46ch;
  }
  .hero-actions{display:flex; gap:16px; margin-top:34px; flex-wrap:wrap;}

  .hero-visual{
    position:relative;
    aspect-ratio:1/1;
    display:flex; align-items:center; justify-content:center;
  }
  .reticle{
    position:relative;
    width:100%; max-width:360px; aspect-ratio:1/1;
  }
  .reticle svg{width:100%; height:100%;}
  .reticle-ring{
    transform-origin:center;
    animation:spin 26s linear infinite;
  }
  .reticle-ring.rev{animation-direction:reverse; animation-duration:34s;}
  @keyframes spin{ to{ transform:rotate(360deg);} }
  @media (prefers-reduced-motion: reduce){
    .reticle-ring{animation:none;}
  }

  /* ---------- hazard divider ---------- */
  .hazard{
    height:14px;
    background:repeating-linear-gradient(135deg, var(--amber) 0 18px, #16171a 18px 36px);
    opacity:.9;
  }

  /* ---------- section shell ---------- */
  section{padding:96px 0;}
  .section-head{
    display:flex; justify-content:space-between; align-items:flex-end;
    gap:24px; margin-bottom:52px; flex-wrap:wrap;
    border-bottom:1px solid var(--line);
    padding-bottom:26px;
  }
  .section-index{
    font-family:var(--font-mono);
    color:var(--red);
    font-size:.78rem;
    letter-spacing:.1em;
    margin-bottom:10px;
    display:block;
  }
  .section-head h2{font-size:clamp(1.7rem, 3vw, 2.3rem); max-width:16ch;}
  .section-head p{color:var(--steel); max-width:40ch; margin:0;}

  /* ---------- services ---------- */
  .services-grid{
    display:grid;
    grid-template-columns:repeat(3, 1fr);
    gap:1px;
    background:var(--line);
    border:1px solid var(--line);
  }
  .service-card{
    background:var(--panel);
    padding:34px 30px;
    position:relative;
  }
  .service-card svg{width:34px;height:34px; color:var(--red); margin-bottom:20px;}
  .service-card h3{font-size:1.28rem; margin-bottom:12px;}
  .service-card p{color:var(--steel); font-size:.96rem; margin:0;}
  .service-card::after{
    content:"";
    position:absolute; top:0; left:0; width:3px; height:0;
    background:var(--red);
    transition:height .25s ease;
  }
  .service-card:hover::after{height:100%;}

  /* ---------- process ---------- */
  .process-list{
    display:flex; flex-direction:column;
  }
  .process-row{
    display:grid;
    grid-template-columns:90px 1fr;
    gap:28px;
    padding:26px 0;
    border-top:1px solid var(--line);
    align-items:baseline;
  }
  .process-row:last-child{border-bottom:1px solid var(--line);}
  .process-num{
    font-family:var(--font-mono);
    color:var(--red);
    font-size:1.6rem;
  }
  .process-row h3{font-size:1.12rem; margin-bottom:6px; color:#fff;}
  .process-row p{margin:0; color:var(--steel); font-size:.95rem; max-width:56ch;}

  /* ---------- calculator ---------- */
  .calc-panel{
    border:1px solid var(--line);
    background:var(--panel);
    padding:44px;
    display:grid;
    gap:30px;
  }
  .calc-input-row{display:flex; flex-direction:column; gap:14px; max-width:460px;}
  .calc-input-row label{
    font-family:var(--font-mono);
    font-size:.76rem;
    letter-spacing:.08em;
    color:var(--steel);
  }
  .calc-input-wrap{display:flex; align-items:center; gap:14px; flex-wrap:wrap;}
  #calcQty{
    background:var(--void);
    border:1px solid var(--line);
    color:#fff;
    font-family:var(--font-display);
    font-size:1.6rem;
    font-weight:700;
    padding:12px 16px;
    width:140px;
    border-radius:var(--radius);
  }
  #calcQty:focus{border-color:var(--red);}
  .calc-presets{display:flex; gap:8px;}
  .calc-presets button{
    background:transparent;
    border:1px solid var(--line);
    color:var(--steel);
    font-family:var(--font-mono);
    font-size:.82rem;
    padding:9px 16px;
    cursor:pointer;
    border-radius:var(--radius);
    transition:border-color .15s, color .15s;
  }
  .calc-presets button:hover{border-color:var(--red); color:#fff;}

  .calc-result{
    display:flex;
    gap:1px;
    background:var(--line);
    border:1px solid var(--line);
    flex-wrap:wrap;
  }
  .calc-result-item{
    flex:1; min-width:160px;
    background:var(--void);
    padding:22px 26px;
    display:flex; flex-direction:column; gap:6px;
  }
  .calc-label{font-family:var(--font-mono); font-size:.72rem; color:var(--steel); letter-spacing:.08em;}
  .calc-value{font-family:var(--font-display); font-size:2.1rem; font-weight:700; color:#fff;}
  .calc-total .calc-value{color:var(--red); text-shadow:0 0 16px rgba(255,32,32,.5);}

  .calc-tiers{display:flex; gap:1px; background:var(--line); border:1px solid var(--line); flex-wrap:wrap;}
  .calc-tier{
    flex:1; min-width:150px;
    background:var(--panel-2);
    padding:16px 18px;
    display:flex; justify-content:space-between; align-items:center; gap:10px;
    font-family:var(--font-mono); font-size:.8rem; color:var(--steel);
    transition:background .2s, color .2s;
  }
  .calc-tier.active{background:var(--red-dim); color:#fff;}
  .calc-tier-price{color:var(--steel-light);}
  .calc-tier.active .calc-tier-price{color:#fff;}

  .calc-note{color:var(--steel); font-size:.86rem; max-width:64ch; margin:0;}

  @media (max-width:520px){
    .calc-panel{padding:26px 20px;}
    .calc-result{flex-direction:column;}
    .calc-tiers{flex-direction:column;}
  }

  /* ---------- video ---------- */
  .video-shell{
    border:1px solid var(--line);
    background:var(--panel);
    padding:10px;
  }
  .video-frame{
    position:relative;
    width:100%;
    padding-top:56.25%;
    background:#000;
  }
  .video-frame iframe{
    position:absolute; inset:0; width:100%; height:100%; border:0;
  }
  .video-caption{
    display:flex; justify-content:space-between; gap:16px;
    padding:16px 6px 4px;
    font-family:var(--font-mono);
    font-size:.72rem;
    color:var(--steel);
    letter-spacing:.06em;
    flex-wrap:wrap;
  }

  /* ---------- stats strip ---------- */
  .stats{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    border-top:1px solid var(--line);
    border-bottom:1px solid var(--line);
  }
  .stat{
    padding:36px 24px;
    border-left:1px solid var(--line);
    text-align:left;
  }
  .stat:first-child{border-left:none;}
  .stat .num{
    font-family:var(--font-display);
    font-size:2.2rem;
    color:#fff;
    font-weight:700;
  }
  .stat .num span{color:var(--red);}
  .stat .label{
    color:var(--steel);
    font-size:.86rem;
    margin-top:6px;
  }

  /* ---------- contact / CTA ---------- */
  .contact{
    position:relative;
    background:var(--panel);
    border:1px solid var(--line);
    padding:72px 56px;
    overflow:hidden;
    text-align:center;
  }
  .contact::before{
    content:"";
    position:absolute; inset:0;
    background:radial-gradient(circle at 50% 0%, rgba(255,32,32,.12), transparent 60%);
    pointer-events:none;
  }
  .contact h2{font-size:clamp(1.8rem,3.6vw,2.6rem); max-width:22ch; margin:0 auto;}
  .contact p{color:var(--steel); max-width:48ch; margin:18px auto 34px;}
  .contact .btn{font-size:1.1rem; padding:16px 34px;}
  .contact .phone-line{
    margin-top:22px;
    font-family:var(--font-mono);
    color:var(--steel);
    font-size:.9rem;
    letter-spacing:.04em;
  }

  /* ---------- footer ---------- */
  footer{
    border-top:1px solid var(--line);
    padding:44px 0 34px;
  }
  .footer-inner{
    display:flex; justify-content:space-between; align-items:flex-start;
    gap:24px; flex-wrap:wrap;
  }
  .footer-brand{display:flex; align-items:center; gap:10px;}
  .footer-brand svg{width:24px;height:24px;}
  .footer-brand span{font-family:var(--font-display); font-weight:700; color:var(--steel-light); font-size:1rem;}
  .footer-meta{
    text-align:right;
    color:#5c6066;
    font-size:.76rem;
    line-height:1.8;
  }
  .footer-meta a{color:#5c6066; text-decoration:none;}
  .footer-meta a:hover{color:var(--steel);}

  /* ---------- whatsapp float ---------- */
  .wa-float{
    position:fixed; right:20px; bottom:20px; z-index:60;
    width:58px; height:58px; border-radius:50%;
    background:var(--red);
    display:flex; align-items:center; justify-content:center;
    box-shadow:0 4px 18px rgba(255,32,32,.45);
    text-decoration:none;
    animation:pulse 2.6s ease-in-out infinite;
  }
  .wa-float svg{width:28px;height:28px;color:#0a0a0a;}
  @keyframes pulse{
    0%,100%{box-shadow:0 4px 18px rgba(255,32,32,.45);}
    50%{box-shadow:0 4px 26px rgba(255,32,32,.75);}
  }
  @media (prefers-reduced-motion: reduce){ .wa-float{animation:none;} }

  /* ---------- responsive ---------- */
  @media (max-width:920px){
    .hero-inner{grid-template-columns:1fr; gap:44px;}
    .hero-visual{order:-1; max-width:280px; margin:0 auto;}
    .services-grid{grid-template-columns:1fr;}
    .stats{grid-template-columns:repeat(2,1fr);}
    .stat:nth-child(3){border-left:none;}
    .contact{padding:52px 26px;}
  }
  @media (max-width:720px){
    nav.main-nav{
      position:fixed; inset:76px 0 0 0;
      background:var(--void);
      flex-direction:column;
      padding:32px 24px;
      gap:26px;
      transform:translateY(-110%);
      transition:transform .25s ease;
      border-top:1px solid var(--line);
    }
    nav.main-nav.open{transform:translateY(0);}
    nav.main-nav a{font-size:1.3rem;}
    .header-cta .btn-ghost-label{display:none;}
    .nav-toggle{
      display:flex; align-items:center; justify-content:center;
      width:40px; height:40px; background:transparent; border:1px solid var(--line);
      color:#fff; cursor:pointer;
    }
    .nav-toggle svg{width:20px;height:20px;}
    .process-row{grid-template-columns:52px 1fr; gap:16px;}
    .process-num{font-size:1.2rem;}
  }
  @media (max-width:520px){
    .wrap{padding:0 18px;}
    section{padding:64px 0;}
    .hero{padding:56px 0 64px;}
    .stats{grid-template-columns:1fr 1fr;}
    .stat{padding:26px 18px;}
    .footer-inner{flex-direction:column;}
    .footer-meta{text-align:left;}
  }