/* GOKUDO front page layout. inc/assets.php loads this file after the shared styles.
   The reveal delays below use a shorter interval than base.css. */

/* HERO: product carousel.
   The image sets the stage height up to the available viewport space above the carousel controls. */

.hero{--foot-h:80px;position:relative;overflow:hidden;background:var(--surface);border-bottom:1px solid var(--line)}
/* All slides share 1 grid cell, so the stage is as tall as the tallest slide.
   home.js handles horizontal swipes. The browser handles vertical scrolling and pinch zoom.
   Browsers without the pinch-zoom value use the first touch-action declaration. */
.hero-stage{position:relative;display:grid;touch-action:pan-y;touch-action:pan-y pinch-zoom}
.hslide{grid-area:1/1;position:relative;display:flex;align-items:center;justify-content:center;background:var(--surface);
	opacity:0;pointer-events:none;transition:opacity 1.1s cubic-bezier(.4,0,.2,1)}
.hslide.active{opacity:1;pointer-events:auto}
.hslide img{width:100%;height:auto;max-height:calc(92vh - 30px - var(--foot-h));object-fit:contain;will-change:transform}
.hslide-hit{position:absolute;inset:0}

/* The caption fades over half the image transition. home.js uses the same duration as FADE.
   Only the changing index and product name fade. The total slide count stays visible.
   Keep opacity and color in the same transition declaration. */
#hIdx,.hf-name{transition:opacity .55s cubic-bezier(.4,0,.2,1),color .2s}
.txt-fade{opacity:0}

.edge{position:absolute;left:20px;top:0;bottom:0;z-index:3;display:flex;align-items:center;pointer-events:none}
.edge .stack{writing-mode:vertical-rl;transform:rotate(180deg);display:flex;gap:26px;font-family:var(--label);font-size:10.5px;letter-spacing:.32em;text-transform:uppercase;color:var(--muted)}
/* Exception: Manuka inherits .32em tracking to separate the vertical text. */
.edge .stack b{color:var(--blue);font-weight:400;font-family:var(--display);font-size:15px;display:inline-block;transform:rotate(90deg)}
.edge .stack .han-v{text-orientation:sideways;color:var(--blue);letter-spacing:.1em}
.edge .stack .gold{color:var(--gold)}   /* Exception: --gold on light, for the wordmark. See .gk in base.css. */

/* --name-cap measures the height of the product name capitals within .hero-foot.
   Keep --foot-h equal to the control height plus the top and bottom padding. */
.hero-foot{--name-cap:33px}
.hero-foot .wrap{display:flex;justify-content:space-between;align-items:center;padding-top:18px;padding-bottom:18px;gap:24px}
.hf-left{display:flex;align-items:center;gap:18px}
/* The hero and card rails share these arrow dimensions. Focus and active states preserve the resting fill. */
.hnav,.hnav:is(:focus,:active){--hnav:44px;width:var(--hnav);height:var(--hnav);border:1px solid var(--line);background:transparent;color:var(--ink);cursor:pointer;
	font-size:16px;line-height:1;transition:.2s;display:flex;align-items:center;justify-content:center}
.hnav:hover{background:var(--blue);color:var(--on-dark);border-color:var(--blue)}
/* Rail arrows remain visible when disabled. Hero arrows loop and never reach this state. */
.hnav:disabled,.hnav:disabled:hover{background:var(--bg2);color:var(--faint);border-color:var(--line);cursor:not-allowed}
/* The caption keeps the slide index and product name on a shared baseline. */
.hf-cap{display:flex;align-items:baseline;gap:14px;white-space:nowrap}
.hf-idx{color:var(--muted);font-size:15px;line-height:1}
.hf-idx b{color:var(--blue);font-weight:700}
/* Fraktion Sans capitals are 0.682 times the font size. Use that ratio to calculate the font size from --name-cap.
   Exception: no link mark at rest. The linked slide opens the same product. */
body.gokudo-home .hf-name{font-family:var(--label);font-weight:400;font-style:italic;font-size:calc(var(--name-cap) / .682);line-height:var(--name-cap);text-transform:uppercase;color:var(--ink)}
body.gokudo-home a.hf-name:hover{color:var(--blue)}
.hf-dots{display:flex;align-items:center;gap:10px}
/* The 24px target gives the 3px track enough room for touch.
   Exception: the track uses a color literal. Its fill stays fixed in all interaction states. The progress bar marks the current slide. */
.dot,.dot:is(:hover,:focus,:active){width:46px;height:24px;border:none;padding:0;cursor:pointer;background:transparent;position:relative}
.dot::before,.dot::after{content:"";position:absolute;left:0;right:0;top:calc(50% - 1.5px);height:3px}
.dot::before{background:rgba(0,0,0,.16)}
.dot::after{background:var(--blue);transform:scaleX(0);transform-origin:left}
.dot.active::after{animation:dotfill 5.5s linear forwards}
@keyframes dotfill{from{transform:scaleX(0)}to{transform:scaleX(1)}}

@media (prefers-reduced-motion:reduce){.dot.active::after{transform:scaleX(1);animation:none}}
/* Short viewports hide the vertical text because the hero clips it. */
@media(max-width:980px),(max-height:620px){.edge{display:none}}
/* The dot container supplies the vertical padding. A hero with 1 slide has no dots and therefore needs no space for the controls. */
@media(max-width:980px){
	.hero{--foot-h:40px}
	.hf-left{display:none}
	.hero-foot .wrap{justify-content:center;padding-top:0;padding-bottom:0}
	.hf-dots{padding:8px 0}
}

/* The front page uses shorter reveal delays between sections. */
.reveal.d1{animation-delay:.08s}.reveal.d2{animation-delay:.16s}.reveal.d3{animation-delay:.24s}.reveal.d4{animation-delay:.32s}

/* LINEUP: product cards on a horizontal rail. components.css controls the cards.
   Both the lineup and newsroom use .hrail. Each section sets its card width. */
#lineup{padding:var(--space-xl) 0;background:var(--bg)}
/* This heading shares the size of .details-head on the product page. */
.lineup-head{font-family:var(--display);font-weight:900;font-size:clamp(40px,5vw,76px);line-height:.92;
	text-transform:uppercase;letter-spacing:var(--track-lg);margin-bottom:var(--space-sm)}
.lineup-head em{font-style:normal;color:var(--blue)}

/* The rail inset aligns its content with .wrap. Percentage padding excludes the scrollbar width.
   Equal end padding aligns the final card with the opposite container edge.
   home.js moves arrows to card boundaries. The rail allows free dragging between those boundaries.
   scroll-padding-left keeps focused links clear of the inset.
   Vertical padding reserves room for the card lift and shadow.
   overscroll-behavior-x contains horizontal scroll at the rail ends. */
.hrail{--rail-gap:36px;--rail-pad:40px;
	--rail-inset:calc(max(0px,(100% - 1320px) / 2) + var(--rail-pad));
	display:flex;gap:var(--rail-gap);overflow-x:auto;overscroll-behavior-x:contain;
	scroll-padding-left:var(--rail-inset);
	padding:10px var(--rail-inset) 24px;
	scrollbar-width:none;-ms-overflow-style:none}
/* The arrows and native scrolling control the rail. The scrollbar stays hidden above the card shadows. */
.hrail::-webkit-scrollbar{display:none}
/* The desktop rail matches the catalog card width within a 1320px container.
   flex-basis percentages use the rail content box. The fixed calculation caps the card width.
   Keep $gk_rail_sizes in front-page.php in sync with this width. */
.hrail > .pcard{flex:0 0 min(calc((100% - var(--rail-gap)) / 2),calc((1320px - var(--rail-pad) * 2 - var(--rail-gap)) / 2))}
/* The closing catalog card has no price. Its button aligns with the product card buttons. */
.pc-more .pc-foot{justify-content:flex-end}
/* contain preserves the full catalog image at both card aspect ratios. */
.pc-cover{width:100%;height:100%;object-fit:contain}

/* Rail arrows align below the left container edge. */
.hrail-nav{display:flex;gap:12px;margin-top:14px}

@media(max-width:980px){
	/* The rail padding follows the 24px .wrap gutter. */
	.hrail{--rail-gap:24px;--rail-pad:24px}
	/* The visible part of the next card indicates more content.
	   Keep $gk_rail_sizes in front-page.php in sync with this width. */
	#lineup .hrail > .pcard{flex-basis:calc(100% / 3 + 126px)}
	/* The price and the button need about 376px to fit on 1 row. */
	#lineup .pc-foot{flex-direction:column;align-items:stretch;gap:14px}
	#lineup .pc-cta{justify-content:center}
	/* The specification table makes the narrow card too tall. */
	#lineup .pc-specs{display:none}
}
/* The description can take more than 3 lines below 801px. Hide it to limit the card height. */
@media(max-width:800px){
	#lineup .pc-desc{display:none}
}
@media(min-width:801px) and (max-width:980px){
	/* The footer supplies the divider because the specification table is hidden. */
	#lineup .pcard:has(.pc-price) .pc-foot{border-top:1px solid var(--line2)}
}
/* The overlay link in components.css leaves the catalog card footer empty at this width. */
@media(max-width:700px){
	.pc-more .pc-foot{padding-top:0}
}

/* ============ THEORY: brand philosophy ============ */
#theory{padding:var(--space-xl) 0;background:var(--bg);border-top:1px solid var(--line);border-bottom:1px solid var(--line)}
/* The background and subject images share 1 grid cell. The later subject image paints above the background.
   The default prose layout sits above the images. */
.theory-art{position:relative;display:grid}
.theory-art img{grid-area:2/1;width:100%;height:auto;user-select:none}
.theory-prose{grid-area:1/1;display:grid;grid-template-columns:1fr 1fr;gap:80px;margin-bottom:var(--space-sm)}
.theory-prose p{color:var(--muted);font-size:17px;line-height:1.8;text-wrap:pretty}
/* Exception: this button uses the dark secondary fill to keep the button distinct from the photograph. */
body.gokudo-home .theory-cta{position:absolute;right:24px;bottom:24px;
	display:inline-flex;align-items:center;gap:12px;
	font-size:12px;letter-spacing:.2em;padding:18px 30px;transition:.22s}

/* The 2 prose cells occupy open areas of the image above the mat.
   Their bounds keep the text clear of the wrestlers.
   home.js detects clipped prose and adds .is-stacked to move the prose above the image. */
@media(min-width:1100px){
	.theory-art:not(.is-stacked) .theory-prose{position:absolute;inset:0;margin:0;gap:0;
		grid-template-columns:39% 1fr 27.4%;grid-template-rows:44% 1fr calc(31.8% + 28px)}
	.theory-art:not(.is-stacked) .theory-prose>*{max-height:100%;overflow:hidden}
	.theory-art:not(.is-stacked) .theory-prose>:first-child{grid-area:1/1;align-self:start}
	.theory-art:not(.is-stacked) .theory-prose>:nth-child(2){grid-area:1/3/3/4;align-self:end}
}

@media(max-width:980px){
	.theory-prose{grid-template-columns:1fr;gap:22px}
	body.gokudo-home .theory-cta{right:16px;bottom:16px}
}
/* The button moves below the image on narrow screens so it does not cover the mat. */
@media(max-width:640px){
	body.gokudo-home .theory-cta{position:static;grid-area:3/1;justify-self:stretch;justify-content:center;margin-top:24px}
}

/* ============ NEWSROOM: the picked posts on a rail, then subscribe ============ */
#newsroom{padding:var(--space-lg) 0;background:var(--bg)}

/* The desktop reference width fits 3 cards inside the 1320px .wrap.
   Use this width to limit changes in text wrapping as the rail narrows. */
.hrail > .ncard{--ncard-w:calc((1320px - 40px * 2 - 36px * 2) / 3);flex:0 0 var(--ncard-w)}
/* Exception: news cards share the product card lift permitted by DESIGN.md.
   translate keeps the lift independent of the reveal animation. The rail reserves room for the shadow.
   Only the Read button opens the post. */
.ncard{position:relative;display:flex;flex-direction:column;min-height:440px;padding:32px;
	background:var(--surface);border:1px solid var(--line);overflow:hidden;
	transition:border-color .35s,translate .35s,box-shadow .35s}
.ncard:hover{border-color:var(--ink);translate:0 -6px;box-shadow:0 18px 34px -24px var(--shadow-sm)}
@media (prefers-reduced-motion:reduce){.ncard:hover{translate:none}}
.ncard-title{font-family:var(--display);font-weight:900;font-size:clamp(28px,2.4vw,38px);line-height:.92;
	text-transform:uppercase;letter-spacing:var(--track-md);text-wrap:balance}
.ncard-desc{color:var(--muted);font-size:15px;line-height:1.65;margin:18px 0 24px}
.ncard-foot{margin-top:auto;display:flex;align-items:center;justify-content:space-between;gap:20px;
	padding-top:24px;border-top:1px solid var(--line2)}
.ncard-date{font-family:var(--label);font-size:11px;letter-spacing:.14em;text-transform:uppercase;color:var(--faint)}
/* The sizing is .pc-cta's, so both rails end alike. */
.ncard-cta{display:inline-flex;align-items:center;gap:12px;
	font-size:12px;letter-spacing:.2em;padding:17px 24px;transition:.24s;white-space:nowrap}
/* The closing card links to Newsroom. Its button aligns with the dated card buttons. */
.ncard-mark{position:absolute;right:-12px;bottom:96px;font-family:var(--display);font-weight:400;font-size:220px;
	line-height:1;color:var(--wash-lg);user-select:none;pointer-events:none}
.ncard-more .ncard-foot{justify-content:flex-end}
/* The subscribe box sits under the rail's arrows. */
#newsroom .hrail-nav{margin-bottom:var(--space-md)}

/* The minimum height follows the desktop width-to-height ratio of 389:440.
   Subtract the 2 rail insets from the viewport width to match the percentage in flex-basis. */
@media(max-width:980px){
	.hrail > .ncard{flex-basis:min(calc(100% / 3 + 126px),var(--ncard-w));
		min-height:calc(min((100vw - 48px) / 3 + 126px,var(--ncard-w)) * 440 / 389)}
}
/* The excerpt can make the card taller than the desktop proportions allow at this width. */
@media(max-width:560px){
	.ncard{padding:22px 20px 24px}
	.ncard-title{font-size:27px}
	.ncard-desc{display:none}
	.ncard-foot{flex-direction:column;align-items:stretch;gap:14px;padding-top:18px}
	.ncard-cta{justify-content:center;padding:15px 20px}
	.ncard-mark{font-size:160px;bottom:104px}
}
.news-in{display:flex;align-items:center;justify-content:space-between;gap:40px;flex-wrap:wrap;border:1px solid var(--line);padding:48px 52px;background:var(--bg2)}
.news-in h3{font-family:var(--display);font-weight:900;font-size:clamp(28px,3.4vw,46px);text-transform:uppercase;letter-spacing:var(--track-md);line-height:.95}
.news-in h3 em{font-style:normal;color:var(--blue)}
.news-in p{color:var(--muted);font-size:16px;margin-top:12px;max-width:440px;line-height:1.6}
.news-in form{display:flex;border:1px solid var(--line);min-width:320px;background:var(--surface)}
.news-in input{flex:1;background:transparent;border:none;color:var(--ink);padding:18px 18px;font-family:var(--label);font-size:12px;letter-spacing:.1em;outline:none}
.news-in input::placeholder{color:var(--faint)}
/* The shared subscribe form also appears in .reg-in and .artcta-in. */
.news-in button{border:none;cursor:pointer;font-size:11px;letter-spacing:.18em;padding:0 24px;transition:.2s}

/* ============ FOOTER ============ */

@media(max-width:980px){
	.news-in{padding:34px 28px}
}
