/*
Theme Name: Japandom
Description: Адаптивная тема JAPANDOM на основе предоставленной реконструкции.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: japandom
*/

:root{
  --bg:#f4f4f4;
  --surface:#ffffff;
  --surface-soft:#f8f8f8;
  --border:#d9d9d9;
  --text:#353535;
  --muted:#6d6d6d;
  --accent:#d93f36;
  --dark:#2f3136;
  --green:#95b31c;
  --shadow:0 10px 30px rgba(0,0,0,.05);
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:Inter, Arial, sans-serif;
  color:var(--text);
  background:var(--bg);
}
a{color:inherit;text-decoration:none}
img{max-width:100%;display:block}
.container{width:min(1180px, calc(100% - 32px)); margin:0 auto}

.topbar{background:#fff;border-bottom:1px solid var(--border); position:sticky; top:0; z-index:20}
.topbar__inner{display:flex; align-items:center; justify-content:space-between; gap:16px; padding:12px 0}
.brand img{height:60px; width:auto}
.menu-toggle{
  display:none; border:1px solid var(--border); background:#fff; color:var(--text);
  padding:10px 14px; border-radius:10px; font-weight:600; cursor:pointer;
}
.hero-strip{
  height:86px;
  background:linear-gradient(115deg,#e5eadb,#f7f7f0 50%,#d6dfca);
  border-top:1px solid #ececec;
  border-bottom:1px solid #2a2a2a;
}
.main-nav{background:var(--dark); border-top:1px solid #4e4f53; border-bottom:1px solid #202226}
.nav-scroll{display:flex; overflow:auto; scrollbar-width:thin}
.nav-scroll a{
  flex:0 0 auto; color:#fff; padding:11px 14px; font-size:14px; line-height:1;
  border-right:1px solid #56585e; white-space:nowrap;
}
.nav-scroll a:hover,.nav-scroll a.is-active{background:var(--accent)}

.breadcrumbs{color:#9a9a9a; font-size:12px; margin:18px 0 8px}
.page-heading{display:flex; align-items:end; justify-content:space-between; gap:16px; padding-bottom:12px; border-bottom:1px solid #e0e0e0}
.page-heading h1{font-size:32px; line-height:1.2; color:#d03a31; font-style:italic; margin:0}
.page-heading p{max-width:620px; margin:0; color:var(--muted); font-size:15px}

.home-layout{display:grid; grid-template-columns:minmax(0, 1fr) 290px; gap:24px; margin:22px 0 36px}
.product-grid{display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:18px}
.product-tile{
  background:#efefef; border:1px solid var(--border); box-shadow:var(--shadow);
  display:flex; flex-direction:column; min-height:100%;
}
.product-tile__media{padding:16px 16px 8px}
.product-tile__media img{width:100%; border:1px solid #ddd; background:#fff}
.product-tile__body{padding:0 16px 16px}
.product-tile__body h2{font-size:22px; line-height:1.08; margin:10px 0 10px; color:#d33b33; text-transform:uppercase}
.tile-subtitle{color:#d33b33; font-weight:700; margin:0 0 10px; text-transform:uppercase}
.product-tile__body ul{margin:0; padding-left:20px; color:#5b5b5b}
.product-tile__body li{margin:7px 0; font-size:15px; line-height:1.35}

.sidebar{display:flex; flex-direction:column; gap:16px}
.side-box{
  background:#fff; border:1px solid var(--border); padding:16px; box-shadow:var(--shadow)
}
.side-box h3{font-size:18px; line-height:1.25; margin:0 0 14px; color:#b2332e}
.side-box.muted{background:#f6f8f2}
.side-button{
  display:block; background:#ebf1e3; border:1px solid #d6e2c3; padding:14px 12px;
  text-align:center; border-radius:8px; font-weight:600; color:#646b57
}
.download-button{
  display:inline-flex; align-items:center; justify-content:center; width:100%; min-height:54px;
  padding:12px 16px; border-radius:999px; text-transform:uppercase; font-weight:800;
  background:linear-gradient(180deg,#a8d439,#88bf16); color:#fff; border:1px solid #77ab0f;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 6px 16px rgba(119,171,15,.18);
}
.side-note{font-size:14px; color:var(--muted); line-height:1.5; padding:4px 2px}

.quick-links{display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); gap:18px; margin-top:20px}
.quick-card{background:#fff; border:1px solid var(--border); padding:16px; box-shadow:var(--shadow)}
.quick-card h3{margin:0 0 10px; color:#cf3b33; border-bottom:1px solid #e1e1e1; padding-bottom:10px; font-size:22px}
.quick-card ul{margin:0 0 14px; padding-left:18px; color:#575757}
.quick-card li{margin:8px 0; font-size:15px}
.quick-card a{font-weight:700; color:#5b5b5b}

.detail-section{background:#fff; padding:56px 0; border-top:1px solid #e7e7e7}
.detail-section.alt{background:#fafafa}
.detail-grid{display:grid; grid-template-columns:1.2fr 1fr 1fr; gap:20px; align-items:start}
.single-left{grid-template-columns:1.2fr 1.2fr}
.detail-title h2{font-size:36px; margin:4px 0 12px}
.detail-title p{font-size:16px; line-height:1.65; color:var(--muted); margin:0}
.eyebrow{display:inline-block; font-size:12px; letter-spacing:.16em; font-weight:800; color:var(--accent); margin-bottom:8px}
.detail-card{background:var(--surface-soft); border:1px solid var(--border); border-radius:18px; padding:22px; box-shadow:var(--shadow)}
.detail-card.wide{grid-column:span 1}
.detail-card h3{margin:0 0 12px; font-size:22px}
.detail-card p,.detail-card li{font-size:15px; line-height:1.6; color:#5b5b5b}
.detail-card ul{margin:0; padding-left:20px}

.publications,.requisites{padding:60px 0}
.section-head{display:flex; flex-direction:column; gap:10px; margin-bottom:24px}
.section-head h2{font-size:34px; margin:0}
.section-head p{margin:0; color:var(--muted); max-width:760px; line-height:1.6}
.pub-grid{display:grid; grid-template-columns:repeat(4, minmax(0,1fr)); gap:18px}
.pub-card{background:#fff; border:1px solid var(--border); border-radius:18px; padding:22px; box-shadow:var(--shadow); min-height:200px; display:flex; flex-direction:column}
.pub-card h3{margin:0 0 10px; font-size:22px}
.pub-card p{margin:0 0 18px; color:var(--muted); line-height:1.55; flex:1}
.pub-card span{font-weight:700; color:var(--accent)}
.req-grid{display:grid; grid-template-columns:1fr 1.1fr; gap:20px}
.req-card{background:#fff; border:1px solid var(--border); border-radius:18px; padding:22px; box-shadow:var(--shadow)}
.req-card h3{margin:0 0 8px; font-size:24px}
.req-card p{margin:8px 0; color:var(--muted); line-height:1.6}
.contact-form{background:#fff; border:1px solid var(--border); border-radius:18px; padding:22px; box-shadow:var(--shadow); display:grid; gap:14px}
.contact-form label{display:grid; gap:8px; font-size:14px; font-weight:600}
.contact-form input,.contact-form textarea{
  width:100%; border:1px solid #cfcfcf; background:#fff; color:var(--text);
  border-radius:12px; padding:12px 14px; font:inherit
}
.contact-form button{
  justify-self:start; background:var(--accent); color:#fff; border:none; border-radius:12px;
  padding:12px 18px; font:inherit; font-weight:700; cursor:pointer
}
.form-status{margin:0; color:var(--muted); font-size:14px}

.site-footer{background:#fff; border-top:1px solid var(--border)}
.footer-inner{display:flex; align-items:center; justify-content:space-between; gap:20px; padding:20px 0}
.footer-inner img{height:42px; width:auto}
.footer-inner p{margin:0; color:var(--muted); font-size:14px; flex:1}
.footer-inner a{font-weight:700; white-space:nowrap}

@media (max-width: 1100px){
  .home-layout{grid-template-columns:1fr}
  .sidebar{order:-1; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px}
  .detail-grid{grid-template-columns:1fr 1fr}
  .detail-title{grid-column:1/-1}
  .pub-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width: 820px){
  .menu-toggle{display:inline-flex}
  .main-nav{display:none}
  .main-nav.is-open{display:block}
  .nav-scroll{flex-direction:column}
  .nav-scroll a{border-right:none; border-bottom:1px solid #56585e}
  .page-heading{flex-direction:column; align-items:flex-start}
  .page-heading h1{font-size:28px}
  .product-grid,.quick-links,.sidebar,.detail-grid,.pub-grid,.req-grid,.single-left{grid-template-columns:1fr}
  .detail-title h2,.section-head h2{font-size:28px}
  .brand img{height:50px}
  .hero-strip{height:68px}
  .footer-inner{flex-direction:column; align-items:flex-start}
}
@media (max-width: 520px){
  .container{width:min(100% - 20px, 1180px)}
  .topbar__inner{padding:10px 0}
  .product-tile__body h2{font-size:18px}
  .product-tile__body li,.quick-card li,.detail-card p,.detail-card li,.section-head p{font-size:14px}
  .page-heading h1{font-size:24px}
  .quick-card h3,.pub-card h3{font-size:20px}
}


/* Framework polish */
body{background:linear-gradient(180deg,#f7f7f7 0,#f2f2f2 100%)}
.topbar{backdrop-filter:saturate(160%) blur(14px); background:rgba(255,255,255,.94)}
.brand img{filter:drop-shadow(0 2px 4px rgba(0,0,0,.06))}
.product-tile,.side-box,.quick-card,.detail-card,.pub-card,.req-card,.contact-form{
  transition:transform .25s ease,box-shadow .25s ease,border-color .25s ease;
}
.product-tile:hover,.quick-card:hover,.pub-card:hover,.detail-card:hover{
  transform:translateY(-4px);
  box-shadow:0 16px 34px rgba(0,0,0,.08);
  border-color:#cfcfcf;
}
.product-tile__media img{transition:transform .3s ease}
.product-tile:hover .product-tile__media img{transform:scale(1.015)}
.main-nav{box-shadow:0 4px 14px rgba(0,0,0,.10)}
.nav-scroll a{font-weight:600; transition:background .2s ease,color .2s ease}
.download-button{transition:transform .2s ease,box-shadow .2s ease}
.download-button:hover{transform:translateY(-2px);box-shadow:0 10px 20px rgba(119,171,15,.22)}
.side-button:hover{background:#e3ebd8}
.pub-card span{display:inline-flex;align-items:center;gap:6px}
.contact-form input:focus,.contact-form textarea:focus{
  border-color:var(--accent)!important;
  box-shadow:0 0 0 .2rem rgba(217,63,54,.12)!important;
  outline:none;
}
.menu-toggle{display:none!important}
@media (max-width:820px){
  .menu-toggle{display:inline-flex!important;align-items:center;gap:7px}
  .topbar__inner{padding-top:8px;padding-bottom:8px}
}

/* Reliable local interactions: no CDN required */
a, button, input, textarea { pointer-events:auto; }
a { position:relative; z-index:2; }
section[id], article[id], main[id] { scroll-margin-top:190px; }

/* Reveal animation is enabled only by JS, so content never stays hidden if JS is blocked */
.reveal-ready {
  opacity:0;
  transform:translateY(24px);
  transition:opacity .6s cubic-bezier(.2,.7,.2,1), transform .6s cubic-bezier(.2,.7,.2,1);
}
.reveal-ready.reveal-visible {
  opacity:1;
  transform:none;
}
.reveal-delay-1 { transition-delay:.07s; }
.reveal-delay-2 { transition-delay:.14s; }
.reveal-delay-3 { transition-delay:.21s; }

.nav-scroll a.active-local { background:var(--accent); }

/* Visible click feedback */
a:active, button:active { transform:translateY(1px); }
.quick-card a, .side-button, .download-button, .pub-card, .nav-scroll a {
  cursor:pointer;
}
.quick-card a:hover { color:var(--accent); text-decoration:underline; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior:auto; }
  .reveal-ready { opacity:1; transform:none; transition:none; }
  * { animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

  