/* Homepage-only styles */
:root { --ink: #c9d6ff; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; min-height: min(86vh, 780px); display: flex; align-items: flex-end; isolation: isolate; }
.hero-slides, .hero-shade { position: absolute; inset: 0; }
.hero-slides { z-index: -2; }
.slide { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transform: scale(1.02); transition: opacity 1.4s ease; }
.slide.on { opacity: 1; animation: drift 14s ease-out forwards; }
@keyframes drift { from { transform: scale(1.02); } to { transform: scale(1.1); } }
.hero-shade { z-index: -1; background:
  linear-gradient(180deg, rgba(7,8,11,.55) 0%, rgba(7,8,11,.15) 35%, rgba(7,8,11,.78) 80%, var(--bg) 100%),
  linear-gradient(90deg, rgba(7,8,11,.75) 0%, rgba(7,8,11,0) 62%); }
.hero-inner { width: 100%; max-width: 1180px; margin: 0 auto; padding: 120px 40px 56px; display: grid; grid-template-columns: 1fr 340px; gap: 48px; align-items: end; }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(60px, 9.4vw, 132px); line-height: .9; letter-spacing: -.035em; margin: 0 0 26px; }
.hero h1 span { display: block; }
.hero-copy p { color: #bcc3d3; font-size: 18px; line-height: 1.6; max-width: 500px; margin: 0 0 32px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.hero-in > * { opacity: 0; transform: translateY(14px); animation: rise .8s cubic-bezier(.2,.7,.2,1) forwards; }
.hero-in > *:nth-child(2) { animation-delay: .12s; }
.hero-in > *:nth-child(3) { animation-delay: .24s; }
.board { opacity: 0; animation: rise .9s .35s cubic-bezier(.2,.7,.2,1) forwards; }
@keyframes rise { to { opacity: 1; transform: none; } }

.board { background: rgba(9,11,16,.72); border: 1px solid rgba(255,255,255,.12); border-radius: 16px; backdrop-filter: blur(14px); overflow: hidden; }
.board-head { display: flex; align-items: center; gap: 9px; padding: 14px 20px; border-bottom: 1px solid rgba(255,255,255,.08); font-size: 13px; font-weight: 600; }
.board-row { display: flex; justify-content: space-between; align-items: center; padding: 15px 20px; border-bottom: 1px solid rgba(255,255,255,.08); }
.board-row:last-child { border-bottom: none; }
.board-row .k { color: var(--muted); font-size: 13px; }
.board-row .v { font-size: 22px; font-weight: 700; letter-spacing: -.5px; display: inline-flex; align-items: center; gap: 9px; }
.code-btn { display: inline-flex; align-items: center; gap: 10px; background: transparent; border: 1px dashed rgba(201,214,255,.4); color: var(--ink); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 16px; letter-spacing: 3px; padding: 6px 12px; border-radius: 8px; cursor: pointer; transition: background .15s, border-color .15s; }
.code-btn:hover { background: rgba(201,214,255,.08); border-color: var(--ink); }
.code-btn small { font-family: 'Inter', sans-serif; letter-spacing: 0; font-size: 11px; color: var(--muted); }

.hero-ticks { position: absolute; right: 40px; top: 96px; display: flex; gap: 6px; }
.tick { width: 28px; height: 22px; background: none; border: 0; padding: 0; cursor: pointer; position: relative; }
.tick::after { content: ''; position: absolute; left: 0; right: 0; top: 10px; height: 2px; background: rgba(255,255,255,.3); border-radius: 2px; transition: background .2s; }
.tick.on::after { background: #fff; }

/* ---------- Layout ---------- */
.section { max-width: 1180px; margin: 0 auto; padding: 128px 40px 0; }
.section h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(38px, 5vw, 60px); line-height: 1; letter-spacing: -.025em; margin: 0 0 16px; }
.lead { color: var(--muted); font-size: 16.5px; line-height: 1.65; max-width: 560px; margin: 0; }
.section-head { margin-bottom: 44px; }

/* ---------- Ways in ---------- */
.ways { border-top: 1px solid var(--border); }
.way { display: grid; grid-template-columns: minmax(180px, 320px) 1fr auto; gap: 32px; align-items: center; padding: 30px 8px; border-bottom: 1px solid var(--border); text-decoration: none; transition: background .2s, padding .2s; }
.way h3 { font-family: var(--serif); font-weight: 400; font-size: 38px; letter-spacing: -.02em; margin: 0; }
.way p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.6; max-width: 460px; }
.way .go { font-size: 22px; color: var(--muted); transition: transform .2s, color .2s; }
.way:hover { background: var(--panel); padding-left: 20px; padding-right: 20px; }
.way:hover .go { color: var(--text); transform: translateX(4px); }

/* ---------- Departments ---------- */
.dept-showcase { display: grid; grid-template-columns: 1.3fr 1fr 1fr; grid-template-rows: 250px 250px; gap: 14px; }
.dept-tile { position: relative; border-radius: 14px; overflow: hidden; border: 1px solid var(--border); background: var(--panel-2); text-decoration: none; display: flex; align-items: flex-end; padding: 22px; }
.dept-tile .ph { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.dept-tile:hover .ph { transform: scale(1.06); }
.dept-tile::before { content: ''; position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(7,8,11,0) 30%, rgba(7,8,11,.92) 100%); }
.dept-tile.big { grid-row: span 2; }
.dept-tile.t4 { grid-column: 2 / span 2; }
.dept-tile.t4 .ph { background-image: radial-gradient(circle at 18% 30%, rgba(255,120,80,.22), transparent 55%), repeating-linear-gradient(135deg, rgba(255,255,255,.03) 0 2px, transparent 2px 14px); }
.dept-tile .inner { position: relative; z-index: 2; }
.dept-tile .kind { font-size: 12.5px; color: #aab2c4; }
.dept-tile h3 { margin: 4px 0 0; font-size: 22px; font-weight: 700; letter-spacing: -.4px; }
.dept-more { margin-top: 22px; }

/* ---------- On duty tabs ---------- */
.duty { display: grid; grid-template-columns: 300px 1fr; gap: 48px; align-items: stretch; }
.duty-tabs { display: flex; flex-direction: column; border-top: 1px solid var(--border); }
.duty-tab { text-align: left; background: none; border: 0; border-bottom: 1px solid var(--border); color: var(--muted); font-family: inherit; padding: 22px 4px; cursor: pointer; transition: color .2s; }
.duty-tab strong { display: block; font-family: var(--serif); font-weight: 400; font-size: 28px; letter-spacing: -.01em; }
.duty-tab span { display: none; font-size: 14.5px; line-height: 1.6; margin-top: 8px; color: var(--muted); }
.duty-tab[aria-selected="true"] { color: var(--text); box-shadow: inset 2px 0 0 var(--accent); padding-left: 18px; }
.duty-tab[aria-selected="true"] span { display: block; }
.duty-tab:hover { color: var(--text); }
.duty-view { position: relative; border-radius: 14px; overflow: hidden; border: 1px solid var(--border); min-height: 420px; background: var(--panel-2); }
.duty-view .pic { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity .5s ease; }
.duty-view .pic.on { opacity: 1; }

/* ---------- Gallery strip ---------- */
.strip-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.strip-nav { display: flex; gap: 8px; }
.strip-nav button { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--border); background: transparent; color: var(--text); font-size: 18px; cursor: pointer; transition: background .15s, border-color .15s; }
.strip-nav button:hover { background: var(--panel-2); border-color: #2b3040; }
.strip { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-bottom: 4px; cursor: grab; }
.strip::-webkit-scrollbar { display: none; }
.strip.drag { cursor: grabbing; scroll-snap-type: none; }
.strip a { position: relative; flex: 0 0 min(420px, 82vw); aspect-ratio: 16 / 10; border-radius: 14px; overflow: hidden; border: 1px solid var(--border); scroll-snap-align: start; background: var(--panel-2); }
.strip img { width: 100%; height: 100%; object-fit: cover; display: block; user-select: none; -webkit-user-drag: none; }
.strip figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 28px 14px 12px; font-size: 13px; font-weight: 600; background: linear-gradient(180deg, transparent, rgba(7,8,11,.85)); }

/* ---------- Map ---------- */
.mapwrap { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.seg { display: inline-flex; border: 1px solid var(--border); border-radius: 999px; padding: 4px; gap: 4px; margin: 26px 12px 0 0; background: var(--panel); }
.seg button { border: 0; background: none; color: var(--muted); font-family: inherit; font-size: 13px; font-weight: 600; padding: 8px 16px; border-radius: 999px; cursor: pointer; transition: background .15s, color .15s; }
.seg button[aria-pressed="true"] { background: var(--text); color: #07080b; }
.mapbox { position: relative; aspect-ratio: 1; border-radius: 14px; border: 1px solid var(--border); background: radial-gradient(circle at 50% 40%, #11151f, var(--panel)); overflow: hidden; }
.mapbox img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transition: opacity .25s; }

/* ---------- Path ---------- */
.path { display: grid; grid-template-columns: repeat(4, 1fr); position: relative; gap: 24px; }
.path::before { content: ''; position: absolute; top: 18px; left: 18px; right: 18px; height: 1px; background: var(--border); }
.step { position: relative; }
.step .marker { width: 36px; height: 36px; border-radius: 50%; background: var(--bg); border: 1px solid var(--accent); color: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; position: relative; z-index: 1; margin-bottom: 22px; }
.step h3 { margin: 0 0 8px; font-size: 18px; letter-spacing: -.2px; }
.step p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65; padding-right: 12px; }

/* ---------- Standards ---------- */
.standards { display: grid; grid-template-columns: 1fr 1.4fr; gap: 64px; align-items: start; }
.standards .sticky { position: sticky; top: 110px; }
.rows { border-top: 1px solid var(--border); }
.row { padding: 26px 0 26px 22px; border-bottom: 1px solid var(--border); box-shadow: inset 2px 0 0 var(--border); transition: box-shadow .2s; }
.row:hover { box-shadow: inset 2px 0 0 var(--accent); }
.row h3 { margin: 0 0 6px; font-size: 19px; letter-spacing: -.2px; }
.row p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.7; }

/* ---------- Closing band ---------- */
.cta-band { position: relative; max-width: 1180px; margin: 140px auto 0; border-radius: 22px; overflow: hidden; padding: 110px 40px; text-align: center; border: 1px solid var(--border); background: linear-gradient(180deg, rgba(7,8,11,.5), rgba(7,8,11,.88)), url('/images/scene-gas.webp') center/cover; }
.cta-band h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(42px, 6vw, 76px); line-height: .98; letter-spacing: -.03em; margin: 0 0 14px; }
.cta-band p { color: #bcc3d3; font-size: 17px; max-width: 480px; margin: 0 auto 30px; line-height: 1.6; }
.cta-band .hero-actions { justify-content: center; }
@media (max-width: 1240px) { .cta-band { margin-left: 20px; margin-right: 20px; } }

/* ---------- Floating join ---------- */
.float-join { position: fixed; right: 20px; bottom: 20px; z-index: 30; box-shadow: 0 8px 30px rgba(0,0,0,.45); transform: translateY(80px); opacity: 0; pointer-events: none; transition: transform .35s ease, opacity .35s ease, background .15s; }
.float-join.show { transform: none; opacity: 1; pointer-events: auto; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero { min-height: 640px; }
  .hero-inner { grid-template-columns: 1fr; padding: 110px 20px 40px; gap: 32px; }
  .hero-ticks { right: 20px; top: 84px; }
  .section { padding: 88px 20px 0; }
  .way { grid-template-columns: 1fr auto; gap: 8px 16px; }
  .way h3 { font-size: 32px; grid-column: 1; }
  .way p { grid-column: 1; }
  .way .go { grid-row: 1; grid-column: 2; }
  .dept-showcase { grid-template-columns: 1fr; grid-template-rows: none; }
  .dept-tile { min-height: 210px; }
  .dept-tile.big { grid-row: auto; min-height: 290px; }
  .dept-tile.t4 { grid-column: auto; }
  .duty { grid-template-columns: 1fr; gap: 24px; }
  .duty-view { min-height: 280px; order: -1; }
  .mapwrap, .standards { grid-template-columns: 1fr; gap: 32px; }
  .standards .sticky { position: static; }
  .path { grid-template-columns: 1fr; }
  .path::before { display: none; }
  .cta-band { padding: 72px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  .slide.on { animation: none; }
  .hero-in > *, .board { animation: none; opacity: 1; transform: none; }
  .dept-tile .ph, .way, .way .go, .float-join { transition: none; }
}
