/*
Theme Name: Yulia Japan Admission
Theme URI: https://example.com/
Author: Yulia
Description: Одностраничная тема для консультаций по поступлению в японские университеты.
Version: 1.1.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: yulia-japan-admission
*/

:root {
  --text:#231f20;
  --text-light:#4a4a4a;
  --bg:#fff;
  --bg-alt:#f8f7f5;
  --accent:#231f20;
  --border:#e5e5e5;
  --placeholder:#e8e6e3;
}

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

body{
  font-family:"Open Sans",sans-serif;
  color:var(--text);
  background:var(--bg);
  line-height:1.65;
  font-size:16px;
}

h1,h2,h3,h4{
  font-family:"Cormorant",serif;
  font-weight:500;
  line-height:1.25;
}

a{color:inherit;text-decoration:none}
img{max-width:100%;display:block}

/* HEADER */
.site-header{
  position:fixed;
  top:0;
  left:0;
  right:0;
  z-index:100;
  background:rgba(255,255,255,.95);
  backdrop-filter:blur(8px);
  border-bottom:1px solid transparent;
  transition:.3s;
}

.site-header.scrolled{border-bottom-color:var(--border)}

.header-inner{
  max-width:1200px;
  margin:auto;
  padding:18px 32px;
  display:flex;
  align-items:center;
  justify-content:space-between;
}

.logo{
  font-family:"Cormorant",serif;
  font-size:20px;
  font-weight:600;
  letter-spacing:.04em;
  text-align:center;
  line-height:1.2;
}

.logo span{
  display:block;
  font-size:13px;
  font-weight:400;
  letter-spacing:.12em;
  text-transform:uppercase;
  margin-top:2px;
}

.nav,.nav-right{
  display:flex;
  gap:28px;
  font-size:13px;
  letter-spacing:.06em;
  text-transform:uppercase;
}

.nav a:hover,.nav-right a:hover{opacity:.6}

/* GENERAL */
.hero{
  min-height:100vh;
  display:flex;
  align-items:center;
  padding:120px 32px 80px;
  max-width:1200px;
  margin:auto;
  gap:60px;
}

.hero-content{flex:1;max-width:560px}
.hero-photo{flex:0 0 420px;height:520px}

.hero h1{
  font-size:clamp(32px,4.5vw,48px);
  margin-bottom:28px;
}

.hero p{
  font-size:17px;
  color:var(--text-light);
  margin-bottom:16px;
}

.btn{
  display:inline-block;
  background:var(--accent);
  color:#fff;
  padding:16px 36px;
  font-size:13px;
  letter-spacing:.1em;
  text-transform:uppercase;
  border:0;
  cursor:pointer;
  margin-top:20px;
}

.btn:hover{background:#424242}

section{padding:90px 32px}
.section-inner{max-width:1100px;margin:auto}
.section-title{font-size:36px;margin-bottom:40px;text-align:center}
.bg-alt{background:var(--bg-alt)}

.image-box,.photo-placeholder{
  background:var(--placeholder);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  text-align:center;
  color:#999;
}

.image-box img{
  width:100%;
  height:100%;
  object-fit:cover;
}

/* ABOUT */
.about-layout{
  display:grid;
  grid-template-columns:320px 1fr;
  gap:50px;
  align-items:start;
}

.about-photo{width:100%;height:400px}

.about-text p{
  font-size:17px;
  color:var(--text-light);
  margin-bottom:18px;
}

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

.credentials{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(200px,1fr));
  gap:20px;
  margin-top:48px;
}

.cred-item{
  background:#fff;
  padding:24px 20px;
  border:1px solid var(--border);
}

.cred-item h4{font-size:18px;margin-bottom:8px}
.cred-item p{font-size:14px;color:var(--text-light);line-height:1.5}

/* WHY / PROCESS */
.why-list{max-width:720px;margin:auto}
.why-list p{margin-bottom:20px;font-size:17px;color:var(--text-light)}

.process-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:40px;
}

.process-block h3{
  font-size:24px;
  margin-bottom:20px;
  padding-bottom:12px;
  border-bottom:1px solid var(--border);
}

.process-block ol{padding-left:20px}
.process-block li{margin-bottom:14px;color:var(--text-light)}

/* DOCUMENTS
   Compact grid:
   4 columns on large screens, then 3 / 2 / 1.
   All image areas have exactly the same height.
*/
.docs-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:20px;
  align-items:stretch;
}

.doc-card{
  background:#fff;
  border:1px solid var(--border);
  overflow:hidden;
  display:flex;
  flex-direction:column;
  min-width:0;
}

/* Orientation remains available in admin,
   but no longer changes the number of grid columns. */
.doc-card.portrait,
.doc-card.landscape,
.doc-card.square{
  grid-column:auto;
}

.doc-photo{
  width:100%;
  height:235px;
  background:#f4f3f1;
  padding:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}

.doc-photo img{
  width:100%;
  height:100%;
  object-fit:contain;
  object-position:center;
}

.doc-info{
  padding:14px 12px 16px;
  text-align:center;
  margin-top:auto;
}

.doc-info h4{
  font-size:16px;
  margin-bottom:5px;
}

.doc-info p{
  font-size:12px;
  color:var(--text-light);
}

/* SERVICES */
.services-grid{
  display:grid;
  gap:28px;
  max-width:900px;
  margin:auto;
}

.service-card{
  background:#fff;
  border:1px solid var(--border);
  padding:36px 32px;
  display:grid;
  grid-template-columns:1fr auto;
  gap:24px;
}

.service-card h3{font-size:22px;margin-bottom:12px}
.service-card p{font-size:15px;color:var(--text-light);margin-bottom:8px}
.service-card .note{font-size:13px;color:#888;margin-top:12px}

.price{text-align:right;white-space:nowrap}
.price .main{font-family:"Cormorant",serif;font-size:28px}
.price .sub{font-size:14px;color:var(--text-light);margin-top:4px}

/* GALLERY */
.gallery-main{
  width:100%;
  height:min(68vh,620px);
  min-height:360px;
  border:1px solid var(--border);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  position:relative;
  background:#ece9e4;
  isolation:isolate;
}

.gallery-main::before{
  content:"";
  position:absolute;
  inset:-36px;
  background-image:var(--gallery-bg);
  background-size:cover;
  background-position:center;
  filter:blur(28px);
  transform:scale(1.08);
  opacity:.42;
  z-index:-2;
}

.gallery-main::after{
  content:"";
  position:absolute;
  inset:0;
  background:rgba(255,255,255,.28);
  z-index:-1;
}

.gallery-main img{
  width:100%;
  height:100%;
  object-fit:contain;
  padding:10px;
}

.gallery-thumbs{
  display:flex;
  gap:10px;
  overflow-x:auto;
  scroll-behavior:smooth;
  padding:14px 2px 12px;
}

.gallery-thumb{
  flex:0 0 112px;
  height:82px;
  padding:0;
  border:2px solid transparent;
  background:#f1efec;
  cursor:pointer;
  overflow:hidden;
  opacity:.72;
}

.gallery-thumb.active,.gallery-thumb:hover{
  opacity:1;
  border-color:var(--text);
}

.gallery-thumb img{
  width:100%;
  height:100%;
  object-fit:cover;
}

.gallery-controls{
  display:flex;
  justify-content:center;
  gap:10px;
  margin-top:12px;
}

.gallery-controls button{
  width:44px;
  height:44px;
  border:1px solid var(--border);
  background:#fff;
  cursor:pointer;
  font-size:22px;
}

/* CONTACT / FOOTER */
.cta{text-align:center;padding:100px 32px}
.cta h2{font-size:36px;margin-bottom:20px}
.cta p{font-size:17px;color:var(--text-light);max-width:520px;margin:0 auto 32px}

.site-footer{
  padding:40px 32px;
  text-align:center;
  border-top:1px solid var(--border);
  font-size:14px;
  color:#888;
}

@media(max-width:1050px){
  .docs-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}

@media(max-width:760px){
  .docs-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .doc-photo{height:250px}
}

@media(max-width:900px){
  .nav,.nav-right{display:none}
  .header-inner{justify-content:center}
  .hero{flex-direction:column-reverse;padding-top:100px;text-align:center}
  .hero-photo{flex:none;width:100%;max-width:360px;height:420px}
  .about-layout,.process-grid,.service-card{grid-template-columns:1fr}
  .about-photo{max-width:320px;margin:auto}
  .price{text-align:left}
}

@media(max-width:520px){
  .docs-grid{grid-template-columns:1fr}
  .doc-photo{height:300px}
}
