
/*
Theme Name: HAMIN Studio V19
Theme URI: https://hamin1.ir/
Author: HAMIN
Description: Minimal three-section WooCommerce theme for HAMIN.
Version: 19.0.0
Text Domain: hamin
*/
:root{--paper:#f3f3ed;--ink:#090909;--line:rgba(9,9,9,.15);--muted:#777;--ease:cubic-bezier(.16,1,.3,1)}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;background:var(--paper);color:var(--ink);font-family:Tahoma,Arial,sans-serif;overflow-x:hidden;overscroll-behavior-x:none}
a{color:inherit;text-decoration:none}
img{display:block;max-width:100%;height:auto}
button,input,select,textarea{font:inherit}
.page{width:100%;overflow-x:clip}
html,body{max-width:100%;overflow-x:hidden}


.site-header{position:sticky;top:0;z-index:60;background:rgba(243,243,237,.94);backdrop-filter:blur(14px);border-bottom:1px solid var(--line)}
.header-inner{max-width:1500px;margin:auto;padding:15px 28px;display:flex;align-items:center;justify-content:space-between;gap:25px}
.logo{font-weight:900;letter-spacing:.34em;font-size:12px}
.nav{display:flex;gap:30px;font-size:11px}
.nav a{position:relative;padding-bottom:5px}.nav a:after{content:"";position:absolute;right:0;bottom:0;width:100%;height:1px;background:var(--ink);transform:scaleX(0);transform-origin:right;transition:.45s var(--ease)}.nav a:hover:after{transform:scaleX(1)}
.header-tools{display:flex;align-items:center;gap:9px}
.cart-button{border:1px solid var(--ink);border-radius:999px;padding:9px 14px;display:flex;align-items:center;gap:9px;font-size:10px;white-space:nowrap}.cart-button b{width:16px;height:16px;border-radius:50%;display:grid;place-items:center;background:var(--ink);color:#fff;font-size:8px}
.menu-button{display:none;width:42px;height:42px;border:1px solid var(--ink);border-radius:50%;background:transparent;align-items:center;justify-content:center;flex-direction:column;gap:4px;cursor:pointer}.menu-button span{display:block;width:15px;height:1px;background:var(--ink);transition:.35s var(--ease)}
.menu-button.is-open span:first-child{transform:translateY(2.5px) rotate(45deg)}.menu-button.is-open span:last-child{transform:translateY(-2.5px) rotate(-45deg)}
.mobile-drawer{position:fixed;inset:0;z-index:100;pointer-events:none;visibility:hidden}
.mobile-drawer-backdrop{position:absolute;inset:0;background:rgba(0,0,0,.28);opacity:0;transition:opacity .35s ease}
.mobile-drawer-panel{position:absolute;top:0;left:0;width:min(86vw,360px);height:100%;background:var(--paper);padding:90px 26px 30px;transform:translateX(-100%);transition:transform .55s var(--ease);box-shadow:18px 0 50px rgba(0,0,0,.12)}
.mobile-drawer.is-open{pointer-events:auto;visibility:visible}.mobile-drawer.is-open .mobile-drawer-backdrop{opacity:1}.mobile-drawer.is-open .mobile-drawer-panel{transform:none}
.mobile-drawer-nav{display:flex;flex-direction:column;gap:18px;font-size:22px;font-weight:800}.mobile-drawer-nav a{padding:12px 0;border-bottom:1px solid var(--line)}
.hero{min-height:calc(100vh - 62px);display:grid;grid-template-columns:1fr 1fr;border-bottom:1px solid var(--line)}
.hero-copy{padding:8vw 7vw 6vw;display:flex;flex-direction:column;justify-content:center}
.eyebrow{font-size:9px;letter-spacing:.38em;direction:ltr;margin-bottom:25px}
.hero h1{font-size:clamp(72px,10vw,170px);line-height:.85;letter-spacing:-.08em;max-width:8ch;margin:0 0 28px;font-weight:900}
.hero-sub{max-width:590px;font-size:clamp(16px,1.5vw,22px);line-height:1.9;margin:0}
.hero-cta{display:flex;align-items:center;gap:12px;margin-top:36px;font-size:11px;width:max-content}.round-arrow{width:50px;height:50px;border:1px solid var(--ink);border-radius:50%;display:grid;place-items:center;transition:.55s var(--ease)}.hero-cta:hover .round-arrow{transform:rotate(45deg);background:var(--ink);color:#fff}
.hero-art{position:relative;background:#090909;color:#fff;display:grid;place-items:center;overflow:hidden}
.hatch{position:absolute;inset:-30%;background:repeating-linear-gradient(135deg,transparent 0 12px,rgba(255,255,255,.08) 12px 13px,transparent 13px 26px);pointer-events:none;animation:hatchFlow 26s linear infinite}.hatch-2{opacity:.23;animation-duration:39s;animation-direction:reverse}.hatch-3{opacity:.1;animation-duration:55s}
@keyframes hatchFlow{from{transform:translate3d(-5%,-2%,0)}to{transform:translate3d(8%,5%,0)}}
.hero-frame{width:min(67%,520px);aspect-ratio:4/5;border:1px solid rgba(255,255,255,.28);position:relative;overflow:hidden}.hero-frame:before,.hero-frame:after{content:"";position:absolute;inset:8%;border:1px solid rgba(255,255,255,.14);transform:rotate(4deg)}.hero-frame:after{inset:17%;transform:rotate(-5deg)}
.hero-image{position:absolute;inset:10%;width:80%;height:80%;object-fit:cover;filter:grayscale(1) saturate(.8);mix-blend-mode:screen;opacity:.95;transition:filter 1s var(--ease),transform 1s var(--ease),opacity 1s var(--ease)}
.hero-art:hover .hero-image,.hero-art:focus-visible .hero-image,.hero-art.is-color .hero-image{filter:grayscale(0) saturate(1.08);transform:scale(1.045);opacity:1}
.hero-art{outline:none}
.hero-art:focus-visible{box-shadow:inset 0 0 0 2px rgba(255,255,255,.55)}
.hero-title-line{position:relative;display:inline-block;overflow:visible}
.hero-title-line:after{content:"";position:absolute;right:-1.5%;bottom:-13px;width:103%;height:1.5px;background:linear-gradient(90deg,rgba(9,9,9,.18),rgba(9,9,9,.98) 18%,rgba(9,9,9,.98) 78%,rgba(9,9,9,.22));transform-origin:right center;transform:scaleX(0);opacity:0;filter:blur(.05px);animation:heroUnderlineDraw 1.45s cubic-bezier(.22,.75,.12,1) 3s forwards;box-shadow:0 0 0 rgba(9,9,9,0)}
.hero-title-line:before{content:"";position:absolute;right:3%;bottom:-13px;width:0;height:1px;border-radius:999px;background:linear-gradient(90deg,transparent,rgba(255,255,255,.95),transparent);mix-blend-mode:screen;opacity:0;filter:blur(.5px);animation:heroUnderlineGlint 1.2s cubic-bezier(.2,.8,.2,1) 3.65s forwards}
@keyframes heroUnderlineDraw{0%{transform:scaleX(0);opacity:0}16%{opacity:.7}72%{transform:scaleX(1.035);opacity:1}86%{transform:scaleX(.985)}100%{transform:scaleX(1);opacity:.94;box-shadow:0 0 10px rgba(9,9,9,.055)}}
@keyframes heroUnderlineGlint{0%{width:0;right:3%;opacity:0}25%{width:16%;opacity:.85}55%{width:7%;right:72%;opacity:.55}100%{width:0;right:72%;opacity:0}}
.hero-overlay{position:absolute;left:16px;bottom:16px;font-size:9px;letter-spacing:.2em;direction:ltr}

.about{padding:105px 7vw;border-bottom:1px solid var(--line)}
.about-top{display:flex;justify-content:space-between;align-items:flex-end;border-bottom:1px solid var(--line);padding-bottom:25px}
.about-top h2{font-size:clamp(46px,7vw,105px);line-height:.85;letter-spacing:-.06em;margin:0}
.about-main{display:grid;grid-template-columns:1.25fr .75fr;gap:7vw;padding-top:65px;align-items:start}
.about-main blockquote{font-size:clamp(35px,5.8vw,82px);line-height:.98;letter-spacing:-.06em;font-weight:900;margin:0}
.about-text{font-size:15px;line-height:2;color:#555}

.shop{padding:105px 6vw}
.section-head{display:flex;justify-content:space-between;align-items:flex-end;gap:30px;border-bottom:1px solid var(--line);padding-bottom:30px;margin-bottom:35px}
.section-head h2{font-size:clamp(50px,7vw,105px);line-height:.85;letter-spacing:-.06em;margin:0}.section-head p{max-width:360px;color:#666;font-size:13px;line-height:1.9;margin:0}
.products{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}
.product-card{background:#e8e8e0;border:1px solid var(--line);overflow:hidden;opacity:0;transform:translateY(35px);transition:opacity 1s var(--ease),transform 1s var(--ease),background .35s}.product-card.in{opacity:1;transform:none}.product-card:hover{background:#e0e0d8}
.product-media{aspect-ratio:4/5;position:relative;overflow:hidden;background:#ddd}.product-media img{width:100%;height:100%;object-fit:cover;filter:grayscale(1);transition:transform .9s var(--ease)}.product-card:hover .product-media img{transform:scale(1.045)}
.product-hatch{position:absolute;inset:-25%;background:repeating-linear-gradient(135deg,transparent 0 12px,rgba(0,0,0,.07) 12px 13px,transparent 13px 25px);transition:transform 1s var(--ease);z-index:1;pointer-events:none}.product-card:hover .product-hatch{transform:translate3d(3%,2%,0)}
.product-copy{padding:17px}.product-row{display:flex;justify-content:space-between;gap:12px;font-size:13px}.product-row span{font-size:11px}.product-meta{margin-top:9px;font-size:9px;letter-spacing:.16em;color:#777;direction:ltr}
.empty-shop{grid-column:1/-1;padding:70px;text-align:center;border:1px dashed var(--line);color:#666}

.site-footer{padding:24px 28px;display:flex;justify-content:space-between;gap:20px;font-size:9px;letter-spacing:.15em;direction:ltr}
.simple-page{padding:90px 7vw;min-height:70vh}

.reveal,.reveal-up,.reveal-soft,.reveal-scale{opacity:0;transition:opacity 1.15s var(--ease),transform 1.15s var(--ease)}
.reveal,.reveal-up{transform:translateY(34px)}
.reveal-soft{transform:translateY(22px);transition-duration:1.35s}
.reveal-scale{transform:translateY(18px) scale(.985);transition-duration:1.25s}
.reveal.in,.reveal-up.in,.reveal-soft.in,.reveal-scale.in{opacity:1;transform:none}

@media(max-width:900px){
  .header-inner{padding:14px 16px}.nav{gap:15px}
  .hero{display:flex;flex-direction:column;min-height:auto}.hero-art{order:1;min-height:58vh}.hero-copy{order:2;padding:70px 20px 55px}.hero h1{font-size:clamp(60px,18vw,96px)}
  .about{padding:65px 18px}.about-top{display:block}.about-top h2{margin-top:20px}.about-main{grid-template-columns:1fr;gap:30px;padding-top:38px}
  .shop{padding:65px 18px}.section-head{display:block}.section-head p{margin-top:18px}.products{grid-template-columns:1fr}
  .site-footer{padding:18px;flex-wrap:wrap}
}
@media(max-width:600px){.nav{display:none}.cart-button{padding:8px 11px}.hero-art{order:1;min-height:52vh}.hero-copy{order:2}.hero-frame{width:70%}.hatch{animation-duration:31s}}
@media(max-width:900px){.hero-art{cursor:pointer}.hero-art:active .hero-image{transform:scale(1.025)}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}.hatch{animation:none}.reveal,.reveal-up,.reveal-soft,.reveal-scale{opacity:1;transform:none;transition:none}.product-card{opacity:1;transform:none;transition:none}.hero-title-line:after{animation:none;transform:scaleX(1);opacity:.94}.hero-title-line:before{animation:none;width:0;opacity:0}.hero-image{transition:none}}


/* =====================================================
   HAMIN V14 — Story + editorial footer
   ===================================================== */
.story-section{
  background:var(--ink);
  color:#fff;
  min-height:64vh;
  display:grid;
  grid-template-columns:.9fr 1.1fr;
  gap:6vw;
  align-items:center;
  padding:100px 7vw;
  border-bottom:1px solid rgba(255,255,255,.16);
  overflow:hidden;
}
.story-copy-v14 h2{
  font-size:clamp(42px,5.5vw,88px);
  line-height:.92;
  letter-spacing:-.06em;
  font-weight:900;
  margin:0 0 24px;
}
.story-copy-v14 p{
  max-width:520px;
  font-size:15px;
  line-height:2;
  color:#d0d0ca;
}
.story-media-v14{
  position:relative;
  min-height:520px;
  border:1px solid rgba(255,255,255,.23);
  overflow:hidden;
  display:grid;
  place-items:center;
}
.story-media-v14 img{
  width:78%;
  height:82%;
  object-fit:cover;
  filter:grayscale(1);
  mix-blend-mode:screen;
  opacity:.92;
  transition:transform 1s var(--ease);
  position:relative;
  z-index:2;
}
.story-media-v14:hover img{transform:scale(1.035)}
.hatch-light{
  opacity:.24;
  animation-duration:32s;
}
.story-badge{
  position:absolute;
  left:24px;
  bottom:22px;
  z-index:3;
  font-weight:900;
  font-size:clamp(36px,5vw,90px);
  letter-spacing:-.08em;
  line-height:.8;
}
.footer-v14{
  background:var(--paper);
  border-top:1px solid var(--line);
  padding:60px 6vw 22px;
}
.footer-grid{
  display:grid;
  grid-template-columns:1.35fr .8fr .95fr .8fr .8fr;
  gap:35px;
  padding-bottom:55px;
}
.footer-brand{padding-right:10px}
.footer-logo{
  font-size:20px;
  font-weight:900;
  letter-spacing:.35em;
  direction:ltr;
}
.footer-brand p{
  max-width:270px;
  font-size:12px;
  line-height:2;
  color:#666;
  margin-top:18px;
}
.footer-col{
  display:flex;
  flex-direction:column;
  gap:10px;
  font-size:11px;
}
.footer-col a,.footer-col span{color:#555}
.footer-col a:hover{color:var(--ink)}
.footer-label{
  font-size:9px;
  letter-spacing:.16em;
  margin-bottom:6px;
  color:var(--ink);
}
.enamad-box{
  border:1px solid var(--line);
  min-height:110px;
  min-width:130px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  padding:12px;
  text-align:center;
  font-size:14px;
  font-weight:900;
}
.enamad-box small{font-size:8px;font-weight:400;color:#777;margin-top:8px}
.footer-bottom{
  border-top:1px solid var(--line);
  padding-top:18px;
  display:flex;
  justify-content:space-between;
  gap:18px;
  font-size:9px;
  letter-spacing:.15em;
  direction:ltr;
}
@media(max-width:1000px){
  .story-section{grid-template-columns:1fr;gap:35px}
  .story-media-v14{min-height:420px}
  .footer-grid{grid-template-columns:repeat(2,1fr)}
}
@media(max-width:650px){
  .story-section{padding:65px 18px}
  .story-media-v14{min-height:330px}
  .footer-v14{padding:48px 18px 18px}
  .footer-grid{grid-template-columns:1fr 1fr;gap:28px 18px}
  .footer-brand{grid-column:1/-1}
  .footer-license{grid-column:1/-1}
  .footer-bottom{flex-wrap:wrap;line-height:1.7}
}

/* HAMIN V15: exact mobile hero order — image first, copy second */
@media(max-width:900px){.hero-art{order:1}.hero-copy{order:2}.hero{display:flex;flex-direction:column}}

/* V16 mobile: hero art is the first screen block, copy comes directly underneath. */
@media(max-width:900px){
  body{overflow-x:hidden}
  .header-inner{padding:10px 14px}
  .logo{position:absolute;right:50%;transform:translateX(50%);font-size:12px}
  .header-tools{margin-left:auto}
  .menu-button{display:flex;order:1}
  .cart-button{order:2;padding:7px 10px;min-height:42px}
  .cart-button span{font-size:10px}
  .cart-button b{width:15px;height:15px}
  .nav{display:none}
  .hero{display:flex;flex-direction:column;min-height:auto}
  .hero-art{order:1;width:100%;min-height:68vh}
  .hero-copy{order:2;width:100%;padding:48px 20px 58px}
  .hero-frame{width:min(76%,430px)}
  .hero h1{font-size:clamp(58px,18vw,96px);margin-bottom:20px}
  .hero-sub{font-size:clamp(17px,4.8vw,23px);line-height:1.9}
  .hero-cta{margin-top:28px}
}
@media(max-width:600px){
  .hero-art{min-height:62vh}
  .hero-frame{width:78%;aspect-ratio:4/5}
  .hero-image{inset:7%;width:86%;height:86%}
  .hero-overlay{left:12px;bottom:12px;font-size:8px}
}

/* HAMIN V17 — compact mobile header: menu then cart on the left */
@media(max-width:900px){
  .header-inner{position:relative;min-height:62px;display:flex;justify-content:flex-end}
  .header-tools{margin-right:0;margin-left:auto;display:flex;gap:7px}
  .menu-button{display:flex;flex:0 0 40px;width:40px;height:40px}
  .cart-button{flex:0 0 auto}
}


/* HAMIN V20 — slow editorial scroll reveals */
.about-top,.about-main,.section-head,.story-copy-v14,.story-media-v14,.footer-grid,.footer-bottom{will-change:opacity,transform}
.about-top.reveal-soft,.about-main.reveal-soft,.section-head.reveal-soft,.story-copy-v14.reveal-soft,.story-media-v14.reveal-scale,.footer-grid.reveal-soft,.footer-bottom.reveal-soft{opacity:0;transform:translateY(30px);transition:opacity 1.25s var(--ease),transform 1.25s var(--ease)}
.about-top.reveal-soft.in,.about-main.reveal-soft.in,.section-head.reveal-soft.in,.story-copy-v14.reveal-soft.in,.story-media-v14.reveal-scale.in,.footer-grid.reveal-soft.in,.footer-bottom.reveal-soft.in{opacity:1;transform:none}
.hero-title-line:after{pointer-events:none}
@media(max-width:900px){.hero-title-line:after{bottom:-10px;width:101%;height:1.35px}.hero-title-line:before{bottom:-10px}}
@media(prefers-reduced-motion:reduce){.about-top.reveal-soft,.about-main.reveal-soft,.section-head.reveal-soft,.story-copy-v14.reveal-soft,.story-media-v14.reveal-scale,.footer-grid.reveal-soft,.footer-bottom.reveal-soft{opacity:1;transform:none;transition:none}}


/* =========================================================
 * HAMIN V20 — Real WordPress navigation + dropdown system
 * ========================================================= */
.nav{margin-inline:auto}
.nav .primary-menu,.nav .primary-menu ul{list-style:none;margin:0;padding:0}
.nav .primary-menu{display:flex;align-items:center;gap:26px}
.nav .primary-menu>li{position:relative;margin:0}
.nav .primary-menu a{display:flex;align-items:center;gap:7px;padding:8px 0;color:var(--ink);font-size:11px;line-height:1.2;white-space:nowrap}
.nav .primary-menu .sub-menu{position:absolute;right:50%;top:calc(100% + 9px);transform:translate(50%,8px);min-width:180px;background:var(--paper);border:1px solid var(--line);box-shadow:0 18px 40px rgba(0,0,0,.08);padding:8px;display:block;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .3s var(--ease),transform .3s var(--ease),visibility .3s}
.nav .primary-menu .sub-menu li{position:relative}
.nav .primary-menu .sub-menu a{padding:11px 12px;font-size:11px;border-bottom:1px solid rgba(0,0,0,.06)}
.nav .primary-menu .sub-menu li:last-child>a{border-bottom:0}
.nav .primary-menu>li:hover>.sub-menu,.nav .primary-menu>li:focus-within>.sub-menu{opacity:1;visibility:visible;pointer-events:auto;transform:translate(50%,0)}
.nav .primary-menu .menu-item-has-children>a:after{content:'⌄';font-size:10px;opacity:.55;transform:translateY(-1px)}
.nav .primary-menu .sub-menu .sub-menu{right:100%;top:-8px;transform:translateX(-8px)}
.nav .primary-menu .sub-menu li:hover>.sub-menu,.nav .primary-menu .sub-menu li:focus-within>.sub-menu{opacity:1;visibility:visible;pointer-events:auto;transform:none}
.nav .primary-menu .submenu-toggle{display:none}

.mobile-drawer-top{display:flex;align-items:center;justify-content:space-between;margin-bottom:28px;padding-bottom:16px;border-bottom:1px solid var(--line)}
.drawer-label{font-family:var(--hamin-en);font-size:10px;letter-spacing:.25em}
.drawer-close{border:1px solid var(--ink);width:36px;height:36px;border-radius:50%;background:transparent;font-size:18px;line-height:1;cursor:pointer}
.mobile-drawer-nav ul{list-style:none;margin:0;padding:0}
.mobile-menu>li{border-bottom:1px solid var(--line);position:relative}
.mobile-menu a{display:block;color:var(--ink);padding:15px 0;font-size:18px;font-weight:800}
.mobile-menu .sub-menu{display:grid;grid-template-rows:0fr;overflow:hidden;opacity:0;transition:grid-template-rows .45s var(--ease),opacity .3s ease}
.mobile-menu .sub-menu>li{min-height:0}
.mobile-menu .sub-menu a{font-size:14px;font-weight:500;padding:10px 12px;color:#555}
.mobile-menu .menu-item-has-children.is-sub-open>.sub-menu{grid-template-rows:1fr;opacity:1}
.mobile-menu .menu-item-has-children{padding-right:34px}
.mobile-menu .submenu-toggle{position:absolute;right:0;top:10px;width:34px;height:34px;border:0;background:transparent;cursor:pointer}
.mobile-menu .submenu-toggle:before,.mobile-menu .submenu-toggle:after{content:'';position:absolute;left:50%;top:50%;background:var(--ink);transform:translate(-50%,-50%);transition:transform .3s ease}
.mobile-menu .submenu-toggle:before{width:12px;height:1px}
.mobile-menu .submenu-toggle:after{width:1px;height:12px}
.mobile-menu .menu-item-has-children.is-sub-open>.submenu-toggle:after{transform:translate(-50%,-50%) rotate(90deg)}
.mobile-drawer-panel{overflow-y:auto;overscroll-behavior:contain}
body.menu-open{overflow:hidden}
@media(max-width:900px){
  .nav{display:none}
}
@media(min-width:901px){
  .menu-button{display:none!important}
}
