/* ═══════════════════════════════════════════════════════════
   SHORINRYU BUKENKAN — Student Personal Portfolio CSS
   Theme: Dark Obsidian / Ancient Gold / Ivory
   Fonts: Cinzel · Nunito Sans · Cormorant Garamond
   ═══════════════════════════════════════════════════════════ */

/* ── Colour tokens ── */
:root {
    --gold: #c8a951;
    --gold-lt: #e2c76e;
    --gold-dk: #96792e;
    --gold-glow: rgba(200, 169, 81, 0.3);
    --gold-faint: rgba(200, 169, 81, 0.08);
    --content-max: 1360px;
    --gutter: clamp(18px, 2.4vw, 40px);

    --bg: #080808;
    --bg-2: #101010;
    --bg-3: #161616;
    --bg-4: #1e1e1e;
    --bg-5: #262626;

    --text: #f2ebd9;
    --text-70: rgba(242, 235, 217, 0.7);
    --text-30: rgba(242, 235, 217, 0.3);
    --text-10: rgba(242, 235, 217, 0.1);
    --text-05: rgba(242, 235, 217, 0.05);

    --wa-green: #25d366;

    --ff-display: "Cinzel", serif;
    --ff-body: "Nunito Sans", sans-serif;
    --ff-italic: "Cormorant Garamond", serif;

    --nav-h: 68px;
    --r: 5px;
    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --t: 0.5s var(--ease);
}

[data-theme="light"] {
    --gold: #9a7b37;
    --gold-lt: #b8954f;
    --gold-dk: #7a6029;
    --gold-glow: rgba(154, 123, 55, 0.25);
    --gold-faint: rgba(154, 123, 55, 0.08);

    --bg: #faf8f3;
    --bg-2: #f0ece4;
    --bg-3: #e8e4da;
    --bg-4: #ddd8cd;
    --bg-5: #d0cbc0;

    --text: #1a1915;
    --text-70: rgba(26, 25, 21, 0.75);
    --text-30: rgba(26, 25, 21, 0.35);
    --text-10: rgba(26, 25, 21, 0.12);
    --text-05: rgba(26, 25, 21, 0.06);
}

[data-theme="red"] {
    --gold: #c41e3a;
    --gold-lt: #e63946;
    --gold-dk: #9b1b30;
    --gold-glow: rgba(196, 30, 58, 0.3);
    --gold-faint: rgba(196, 30, 58, 0.08);

    --bg: #0a0a0a;
    --bg-2: #141414;
    --bg-3: #1e1e1e;
    --bg-4: #282828;
    --bg-5: #323232;

    --text: #f5f5f5;
    --text-70: rgba(245, 245, 245, 0.7);
    --text-30: rgba(245, 245, 245, 0.3);
    --text-10: rgba(245, 245, 245, 0.1);
    --text-05: rgba(245, 245, 245, 0.05);
}

/* ══════════════════════════════════════
   RESET
══════════════════════════════════════════ */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
html {
    scroll-behavior: smooth;
    font-size: 16px;
}
body {
    font-family: var(--ff-body);
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    transition:
        background 0.4s,
        color 0.4s;
}
img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
a {
    text-decoration: none;
    color: inherit;
}
ul {
    list-style: none;
}

.container {
    max-width: var(--content-max);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

/* ── Scroll reveal ── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.85s var(--ease),
        transform 0.85s var(--ease);
    transition-delay: var(--d, 0s);
}
.reveal.in {
    opacity: 1;
    transform: none;
}

.reveal-left {
    opacity: 0;
    transform: translateX(-28px);
    transition:
        opacity 0.85s var(--ease),
        transform 0.85s var(--ease);
    transition-delay: var(--d, 0s);
}
.reveal-left.in {
    opacity: 1;
    transform: none;
}

/* ── Shared section typography ── */
.sec-eyebrow {
    display: block;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 12px;
}
.sec-h2 {
    font-family: var(--ff-display);
    font-size: clamp(1.9rem, 4.5vw, 3.2rem);
    font-weight: 700;
    line-height: 1.1;
    color: var(--text);
    margin-bottom: 18px;
    letter-spacing: 0.03em;
}
.sec-h2 span {
    color: var(--gold);
}
.sec-sub {
    font-size: 0.95rem;
    color: var(--text-70);
    line-height: 1.8;
    max-width: 560px;
}

/* ══════════════════════════════════════
   PRELOADER
══════════════════════════════════════════ */
#preloader {
    position: fixed;
    inset: 0;
    background: var(--bg);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition:
        opacity 0.5s,
        visibility 0.5s;
}
#preloader.done {
    opacity: 0;
    visibility: hidden;
}
.pc-inner {
    text-align: center;
}
.pc-kanji {
    font-family: var(--ff-display);
    font-size: 3.5rem;
    color: var(--gold);
    opacity: 0;
    animation: fadeInKanji 0.5s ease forwards 0.1s;
    display: block;
    letter-spacing: 0.1em;
}
.pc-name {
    font-family: var(--ff-body);
    font-size: 0.68rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--text-30);
    margin-top: 10px;
    opacity: 0;
    animation: fadeInKanji 0.5s ease forwards 0.3s;
}
.pc-line {
    width: 0;
    height: 1px;
    background: var(--gold);
    margin: 14px auto;
    animation: growLine 0.5s ease forwards 0.5s;
}
.pc-dots {
    display: flex;
    gap: 7px;
    justify-content: center;
    margin-top: 12px;
}
.pc-dots span {
    width: 5px;
    height: 5px;
    background: var(--gold);
    border-radius: 50%;
    opacity: 0;
    animation: dotPulse 0.7s ease infinite;
}
.pc-dots span:nth-child(2) {
    animation-delay: 0.15s;
}
.pc-dots span:nth-child(3) {
    animation-delay: 0.3s;
}
@keyframes fadeInKanji {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}
@keyframes growLine {
    to {
        width: 56px;
    }
}
@keyframes dotPulse {
    0%,
    100% {
        opacity: 0.2;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.4);
    }
}

/* Custom Navbar removed to use global */

/* ══════════════════════════════════════
   HERO — full-bleed split portrait layout
══════════════════════════════════════════ */
.hero {
    position: relative;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
    overflow: hidden;
    background: var(--bg);
}

/* Left panel — text */
.hero-text-panel {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: calc(var(--nav-h) + 60px) clamp(24px, 3vw, 48px) 80px var(--gutter);
    width: 100%;
    max-width: none;
    margin: 0;
}
@media (max-width: 1120px) {
    .hero-text-panel {
        padding-left: var(--gutter);
    }
}

/* Right panel — portrait */
.hero-img-panel {
    position: relative;
    overflow: hidden;
    z-index: 1;
}
.hero-img-panel img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 50%;
    transform: none;
}
.hero-img-panel::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        270deg,
        rgba(8, 8, 8, 0) 20%,
        rgba(8, 8, 8, 0.4) 70%,
        rgba(8, 8, 8, 0.85) 100%
    );
}

/* Decorative vertical gold line */
.hero-text-panel::after {
    content: "";
    position: absolute;
    right: 0;
    top: 20%;
    bottom: 20%;
    width: 1px;
    background: linear-gradient(
        180deg,
        transparent,
        var(--gold-faint) 40%,
        var(--gold-faint) 60%,
        transparent
    );
}

.hero-eyebrow {
    font-family: var(--ff-body);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 22px;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 0.2s;
    display: flex;
    align-items: center;
    gap: 14px;
}
.hero-eyebrow::before {
    content: "";
    width: 32px;
    height: 1px;
    background: var(--gold);
    opacity: 0.5;
}

.hero-h1 {
    font-family: var(--ff-display);
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 0.96;
    margin-bottom: 6px;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 0.35s;
}
.h1-first {
    display: block;
    font-size: clamp(3rem, 7vw, 6.5rem);
    color: var(--text);
}
.h1-last {
    display: block;
    font-size: clamp(3rem, 7vw, 6.5rem);
    color: var(--gold);
}

.hero-title-line {
    font-family: var(--ff-italic);
    font-style: italic;
    font-size: clamp(1rem, 1.8vw, 1.3rem);
    color: #000;
    letter-spacing: 0.12em;
    margin-bottom: 28px;
    display: block;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 0.5s;
    font-weight: 300;
}

.hero-belt-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--gold-faint);
    border: 1px solid rgba(200, 169, 81, 0.22);
    padding: 8px 18px;
    border-radius: 3px;
    margin-bottom: 28px;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 0.62s;
}
.hbb-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--bc, var(--gold));
    flex-shrink: 0;
}
.hbb-text {
    font-family: var(--ff-body);
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-70);
}

.hero-para {
    font-family: var(--ff-italic);
    font-style: italic;
    font-size: clamp(0.95rem, 1.5vw, 1.1rem);
    color: var(--text-70);
    line-height: 1.85;
    max-width: 440px;
    margin-bottom: 40px;
    font-weight: 300;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 0.72s;
}

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 0.85s;
}

.btn-gold {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    background: var(--gold);
    color: #0a0a0a;
    font-family: var(--ff-body);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    padding: 15px 32px;
    border-radius: var(--r);
    transition: all 0.35s ease;
    position: relative;
    overflow: hidden;
}
.btn-gold::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(-102%);
    transition: transform 0.4s ease;
}
.btn-gold:hover::before {
    transform: translateX(0);
}
.btn-gold:hover {
    background: var(--gold-lt);
    box-shadow: 0 0 28px var(--gold-glow);
    transform: translateY(-2px);
}
.btn-gold .arr {
    transition: transform 0.3s;
}
.btn-gold:hover .arr {
    transform: translateX(4px);
}

/* Scroll cue */
.hero-scroll {
    position: absolute;
    bottom: 32px;
    left: calc((100vw - 1120px) / 2 + 28px);
    display: flex;
    align-items: center;
    gap: 12px;
    opacity: 0;
    animation: heroIn 0.9s var(--ease) forwards 1.1s;
}
@media (max-width: 1120px) {
    .hero-scroll {
        left: var(--gutter);
    }
}
.hs-line {
    width: 1px;
    height: 44px;
    background: linear-gradient(180deg, var(--gold), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}
.hs-label {
    font-size: 0.58rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--text-30);
    writing-mode: vertical-lr;
}
@keyframes heroIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}
@keyframes scrollPulse {
    0%,
    100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

/* Floating kanji deco */
.hero-kanji-deco {
    position: absolute;
    right: 6%;
    bottom: 10%;
    z-index: 3;
    font-family: var(--ff-italic);
    font-size: 7rem;
    color: var(--gold);
    opacity: 0.08;
    pointer-events: none;
    font-style: italic;
    line-height: 1;
    animation: kanjiFloat 4s ease-in-out infinite;
}
@keyframes kanjiFloat {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-12px);
    }
}

/* ══════════════════════════════════════
   ABOUT ME
══════════════════════════════════════════ */
.about {
    padding: 110px var(--gutter);
    background: var(--bg-2);
    position: relative;
    overflow: hidden;
}
.about::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 40%;
    height: 100%;
    background: radial-gradient(
        ellipse at 100% 50%,
        rgba(200, 169, 81, 0.04),
        transparent 70%
    );
    pointer-events: none;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.about-left .sec-sub {
    max-width: 100%;
    margin-top: 18px;
}
.about-quote {
    margin-top: 32px;
    padding: 22px 24px;
    border-left: 2px solid var(--gold);
    background: var(--gold-faint);
    border-radius: 0 var(--r) var(--r) 0;
}
.about-quote blockquote {
    font-family: var(--ff-italic);
    font-style: italic;
    font-size: 1.05rem;
    color: var(--text-70);
    line-height: 1.75;
    font-weight: 300;
}
.about-quote cite {
    display: block;
    font-style: normal;
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--text-40);
    margin-top: 10px;
}

.about-right {
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.about-stat-row {
    display: flex;
    gap: 16px;
}
.astat {
    flex: 1;
    background: var(--bg-3);
    border: 1px solid var(--text-10);
    border-radius: var(--r);
    padding: 24px 20px;
    text-align: center;
    transition:
        border-color 0.3s,
        transform 0.3s;
}
.astat:hover {
    border-color: rgba(200, 169, 81, 0.25);
    transform: translateY(-3px);
}
.astat-num {
    font-family: var(--ff-display);
    font-size: 2rem;
    color: var(--gold);
    font-weight: 700;
    line-height: 1;
    margin-bottom: 6px;
}
.astat-lbl {
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #868686;
}
.about-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.about-tag {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: var(--text-70);
    background: var(--text-05);
    border: 1px solid var(--text-10);
    padding: 6px 16px;
    border-radius: 3px;
    transition: all 0.3s;
}
.about-tag:hover {
    border-color: var(--gold);
    color: var(--gold);
    background: var(--gold-faint);
}
.about-dojo-note {
    background: var(--bg-3);
    border: 1px solid var(--text-10);
    border-radius: var(--r);
    padding: 20px 22px;
    display: flex;
    align-items: center;
    gap: 14px;
}
.adn-icon {
    color: var(--gold);
    flex-shrink: 0;
}
.adn-text {
    font-size: 0.82rem;
    color: var(--text-70);
    line-height: 1.55;
    font-weight: 300;
}
.adn-text strong {
    color: var(--text);
    font-weight: 600;
}
.adn-text a {
    color: var(--gold);
    text-decoration: underline;
    transition: color 0.3s;
}
.adn-text a:hover {
    color: var(--gold-lt);
}

/* ══════════════════════════════════════
   JOURNEY — Timeline
══════════════════════════════════════════ */
.journey {
    padding: 110px var(--gutter);
    background: var(--bg);
    position: relative;
    overflow: hidden;
}
.journey-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: repeating-linear-gradient(
        90deg,
        transparent,
        transparent 120px,
        var(--gold-faint) 120px,
        var(--gold-faint) 121px
    );
    opacity: 0.5;
}

.journey-inner {
    max-width: 800px;
}
.journey-inner .sec-sub {
    margin-top: 12px;
}

.timeline {
    position: relative;
    margin-top: 56px;
    padding-left: 28px;
}
.timeline::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: linear-gradient(180deg, var(--gold) 0%, var(--text-10) 100%);
}

.tl-item {
    position: relative;
    margin-bottom: 8px;
    padding-left: 40px;
    padding-bottom: 48px;
}
.tl-item:last-child {
    padding-bottom: 0;
    margin-bottom: 0;
}

/* Timeline node */
.tl-node {
    position: absolute;
    left: -8px;
    top: 20px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: var(--bg-3);
    border: 2px solid var(--text-10);
    transition: all 0.4s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.tl-item.current .tl-node {
    background: var(--gold);
    border-color: var(--gold);
    box-shadow:
        0 0 0 5px var(--gold-faint),
        0 0 20px var(--gold-glow);
}
.tl-item.current .tl-node::after {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #fff;
}
.tl-item:hover .tl-node {
    border-color: var(--gold);
}

.tl-card {
    background: var(--bg-3);
    border: 1px solid var(--text-10);
    border-radius: var(--r);
    padding: 24px 26px;
    transition:
        border-color 0.35s,
        box-shadow 0.35s,
        transform 0.35s;
    position: relative;
    overflow: hidden;
}
.tl-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, var(--gold), transparent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s var(--ease);
}
.tl-card:hover {
    border-color: rgba(200, 169, 81, 0.25);
    transform: translateX(4px);
    box-shadow: 0 6px 32px rgba(0, 0, 0, 0.4);
}
.tl-card:hover::before {
    transform: scaleX(1);
}

.tl-item.current .tl-card {
    border-color: rgba(200, 169, 81, 0.3);
    background: linear-gradient(135deg, var(--bg-3), rgba(200, 169, 81, 0.06));
}

.tl-year {
    font-family: var(--ff-display);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 8px;
    display: block;
}
.tl-card h3 {
    font-family: var(--ff-display);
    font-size: 0.98rem;
    color: var(--text);
    margin-bottom: 8px;
    letter-spacing: 0.04em;
}
.tl-card p {
    font-size: 0.84rem;
    line-height: 1.75;
    color: var(--text-70);
    font-weight: 300;
}
.tl-belt {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 12px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #868686;
}
.tl-belt-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--bc, var(--text-30));
}
.tl-now {
    display: inline-block;
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    background: var(--gold);
    color: #0a0a0a;
    padding: 3px 10px;
    border-radius: 2px;
    margin-left: 8px;
    vertical-align: middle;
}

/* ══════════════════════════════════════
   TRAINING / SKILLS
══════════════════════════════════════════ */
.training {
    padding: 110px var(--gutter);
    background: var(--bg-2);
}

.training-header {
    margin-bottom: 56px;
}
.training-header .sec-sub {
    margin-top: 12px;
}

.training-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.skill-block {
    background: var(--bg-3);
    border: 1px solid var(--text-10);
    border-radius: var(--r);
    padding: 32px 28px;
    position: relative;
    overflow: hidden;
    transition:
        border-color 0.35s,
        transform 0.35s,
        box-shadow 0.35s;
}
.skill-block:hover {
    border-color: rgba(200, 169, 81, 0.25);
    transform: translateY(-4px);
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.45);
}

.skill-block::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, var(--gold-faint), transparent);
}

.sb-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
}
.sb-icon {
    color: var(--gold);
}
.sb-head h3 {
    font-family: var(--ff-display);
    font-size: 0.9rem;
    color: var(--text);
    letter-spacing: 0.06em;
}

.skill-list {
    display: flex;
    flex-direction: column;
    gap: 11px;
}
.skill-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.83rem;
    color: var(--text-70);
    font-weight: 300;
}
.si-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--gold);
    flex-shrink: 0;
    opacity: 0.7;
}
.si-note {
    font-size: 0.8rem;
    color: #323232;
    margin-left: auto;
    letter-spacing: 0.04em;
    font-style: italic;
    font-family: var(--ff-italic);
}

/* Strength bars */
.skill-bars {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.sbar-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 6px;
    font-size: 0.76rem;
    color: var(--text-70);
    font-weight: 600;
    letter-spacing: 0.04em;
}
.sbar-pct {
    color: var(--gold);
    font-family: var(--ff-display);
    font-size: 0.7rem;
}
.sbar-track {
    height: 3px;
    background: var(--text-05);
    border-radius: 2px;
    overflow: hidden;
}
.sbar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold-dk), var(--gold));
    border-radius: 2px;
    width: 0;
    transition: width 1.2s var(--ease);
}
.sbar-fill.animated {
    width: var(--pct);
}

/* ══════════════════════════════════════
   ACHIEVEMENTS
══════════════════════════════════════════ */
.achievements {
    padding: 110px var(--gutter);
    background: var(--bg);
    position: relative;
    overflow: hidden;
}
.achievements::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        ellipse at 50% 0%,
        rgba(200, 169, 81, 0.05),
        transparent 65%
    );
    pointer-events: none;
}

.ach-header {
    margin-bottom: 56px;
}
.ach-header .sec-sub {
    margin-top: 12px;
}

.ach-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.ach-card {
    background: var(--bg-3);
    border: 1px solid var(--text-10);
    border-radius: var(--r);
    padding: 28px 24px;
    position: relative;
    overflow: hidden;
    transition:
        border-color 0.35s,
        transform 0.35s,
        box-shadow 0.35s;
    transition-delay: calc(var(--ai, 0) * 0.06s);
}
.ach-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--gold), var(--gold-lt));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s var(--ease);
}
.ach-card:hover {
    border-color: rgba(200, 169, 81, 0.25);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}
.ach-card:hover::before {
    transform: scaleX(1);
}

.ac-icon {
    width: 40px;
    height: 40px;
    color: var(--gold);
    margin-bottom: 16px;
    opacity: 0.85;
    transition:
        transform 0.4s var(--ease),
        opacity 0.4s;
}
.ach-card:hover .ac-icon {
    transform: scale(1.1) rotate(-5deg);
    opacity: 1;
}
.ac-icon svg {
    width: 100%;
    height: 100%;
}

.ac-year {
    font-size: 0.6rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 8px;
}
.ach-card h3 {
    font-family: var(--ff-display);
    font-size: 0.9rem;
    color: var(--text);
    margin-bottom: 8px;
    letter-spacing: 0.04em;
    font-weight: 600;
}
.ach-card p {
    font-size: 0.8rem;
    line-height: 1.7;
    color: var(--text-50);
    font-weight: 300;
}

.ac-bg-num {
    position: absolute;
    bottom: 8px;
    right: 14px;
    font-family: var(--ff-italic);
    font-size: 5rem;
    color: var(--text);
    opacity: 0.03;
    line-height: 1;
    pointer-events: none;
    font-style: italic;
}

/* ══════════════════════════════════════
   PHILOSOPHY
══════════════════════════════════════════ */
.philosophy {
    position: relative;
    padding: 110px var(--gutter);
    overflow: hidden;
    background: var(--bg-3);
}
.philosophy::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        ellipse at 50% 50%,
        rgba(200, 169, 81, 0.06),
        transparent 70%
    );
    pointer-events: none;
}

.phil-inner {
    max-width: 800px;
    margin-inline: auto;
    text-align: center;
    position: relative;
    z-index: 1;
}

.phil-kanji {
    font-family: var(--ff-italic);
    font-size: 8rem;
    font-style: italic;
    color: var(--gold);
    opacity: 0.1;
    line-height: 1;
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
    user-select: none;
    animation: kanjiFloat 5s ease-in-out infinite;
}

.phil-title {
    font-family: var(--ff-display);
    font-size: clamp(1.6rem, 4vw, 2.8rem);
    font-weight: 700;
    color: var(--text);
    letter-spacing: 0.06em;
    line-height: 1.2;
    margin-bottom: 28px;
    position: relative;
}
.phil-title span {
    color: var(--gold);
}

.phil-quotes {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-bottom: 40px;
}
.phil-q {
    background: var(--bg-4);
    border: 1px solid var(--text-10);
    border-radius: var(--r);
    padding: 28px 32px;
    position: relative;
    transition:
        border-color 0.3s,
        transform 0.3s;
}
.phil-q:hover {
    border-color: rgba(200, 169, 81, 0.2);
    transform: translateY(-2px);
}

.pq-quote {
    font-family: var(--ff-italic);
    font-style: italic;
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-90);
    line-height: 1.8;
    font-weight: 300;
}
.pq-attr {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--text-50);
    margin-top: 12px;
    display: block;
}
.pq-num {
    position: absolute;
    top: 12px;
    right: 16px;
    font-family: var(--ff-display);
    font-size: 1.8rem;
    color: var(--gold);
    opacity: 0.1;
    font-weight: 700;
}

.phil-personal {
    font-family: var(--ff-italic);
    font-style: italic;
    font-size: clamp(0.95rem, 1.6vw, 1.1rem);
    color: var(--text- 50);
    line-height: 1.9;
    font-weight: 300;
}

/* Custom footer removed to use global */

/* Back to top */
.btt {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 800;
    width: 40px;
    height: 40px;
    background: var(--bg-4);
    border: 1px solid var(--text-10);
    color: var(--text-30);
    border-radius: var(--r);
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: all 0.35s;
    transform: translateY(10px);
}
.btt.show {
    opacity: 1;
    pointer-events: all;
    transform: none;
}
.btt:hover {
    background: var(--gold);
    border-color: var(--gold);
    color: #0a0a0a;
}

/* Selection & focus */
::selection {
    background: var(--gold);
    color: #0a0a0a;
}
a:focus-visible,
button:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 4px;
    border-radius: 2px;
}

/* ══════════════════════════════════════
   RESPONSIVE — 1024px
═════════════════════════════════════ */
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        min-height: 100svh;
        align-items: start;
        position: relative;
    }
    .hero-img-panel {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 0;
    }
    .hero-img-panel img {
        object-fit: cover;
        object-position: center top;
        transform: translateY(-18%);
        margin-top: 190px;
    }
    .hero-img-panel::after {
        background: linear-gradient(
            180deg,
            rgba(8, 8, 8, 0.08) 0%,
            rgba(8, 8, 8, 0.18) 22%,
            rgba(8, 8, 8, 0.72) 62%,
            rgba(8, 8, 8, 0.92) 100%
        );
    }
    .hero-text-panel {
        position: relative;
        z-index: 2;
        min-height: 100svh;
        justify-content: flex-end;
        padding: calc(var(--nav-h) + 42px) var(--gutter) 40px;
    }
    .hero-text-panel::after {
        display: none;
    }
    .hero-scroll {
        left: var(--gutter);
    }
    .about-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }
    .training-grid {
        grid-template-columns: 1fr;
    }
    .ach-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .about {
        padding: 80px var(--gutter);
    }
    .journey {
        padding: 80px var(--gutter);
    }
    .achievements {
        padding: 80px var(--gutter);
    }
    .training {
        padding: 80px var(--gutter);
    }
    .philosophy {
        padding: 80px var(--gutter);
    }
}

/* ══════════════════════════════════════
   RESPONSIVE — 768px
══════════════════════════════════════ */
@media (max-width: 768px) {
    :root {
        --nav-h: 60px;
    }

    .burger {
        display: flex;
    }
    .nav-menu {
        display: none;
        position: fixed;
        top: var(--nav-h);
        left: 0;
        right: 0;
        background: #080808;
        backdrop-filter: blur(20px);
        flex-direction: column;
        gap: 0;
        padding: 16px 0 28px;
        border-bottom: 1px solid rgba(200, 169, 81, 0.12);
        z-index: 9998;
    }
    [data-theme="light"] .nav-menu {
        background: #faf8f3;
    }
    .nav-menu.open {
        display: flex !important;
    }
    .nm-link {
        padding: 13px var(--gutter);
        font-size: 0.8rem;
        color: #f2ebd9;
        opacity: 1;
        visibility: visible !important;
        pointer-events: auto !important;
    }
    [data-theme="light"] .nm-link {
        color: #1a1915;
    }
    .nm-link::after {
        display: none;
    }

    .nm-link.highlight {
        margin: 8px var(--gutter);
        text-align: center;
        visibility: visible !important;
        pointer-events: auto !important;
    }

    .ach-grid {
        grid-template-columns: 1fr;
    }
    .about-stat-row {
        flex-direction: column;
        gap: 10px;
    }
    .timeline {
        padding-left: 20px;
    }
    .tl-item {
        padding-left: 28px;
    }
    .footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }
    .hero-kanji-deco {
        display: none;
    }

    .about-dojo-note {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    .about-stat-row {
        flex-direction: column;
    }
    .astat {
        width: 100%;
    }
    .about-tags {
        justify-content: center;
    }

    .hero {
        min-height: 100svh;
        align-items: end;
    }
    .hero-text-panel {
        min-height: 100svh;
        justify-content: flex-end;
        padding: calc(var(--nav-h) + 22px) var(--gutter) 28px;
    }
    .hero-text-panel::before {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        top: calc(var(--nav-h) + 12px);
        border-radius: 28px 28px 0 0;
        background: linear-gradient(
            180deg,
            rgba(8, 8, 8, 0.12) 0%,
            rgba(8, 8, 8, 0.48) 18%,
            rgba(8, 8, 8, 0.82) 52%,
            rgba(8, 8, 8, 0.94) 100%
        );
        border: 1px solid rgba(242, 235, 217, 0.08);
        box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.38);
    }
    .hero-text-panel > * {
        position: relative;
        z-index: 1;
    }
    .hero-eyebrow {
        margin-bottom: 14px;
        font-size: 0.6rem;
        letter-spacing: 0.22em;
        gap: 10px;
    }
    .hero-eyebrow::before {
        width: 24px;
    }
    .hero-h1 {
        line-height: 1;
        margin-bottom: 10px;
    }
    .h1-first {
        font-size: clamp(2.5rem, 11vw, 4rem);
        color: #fff;
    }
    .h1-last {
        font-size: clamp(2.5rem, 11vw, 4rem);
    }
    .hero-title-line {
        font-size: 0.88rem;
        line-height: 1.6;
        letter-spacing: 0.08em;
        color: rgba(242, 235, 217, 0.82);
        margin-bottom: 18px;
    }
    .hero-belt-badge {
        display: inline-flex;
        align-items: center;
        flex-direction: row;
        flex-wrap: wrap;
        gap: 8px;
        text-align: left;
        margin-bottom: 18px;
        padding: 10px 14px;
        background: rgba(200, 169, 81, 0.1);
        border-color: rgba(200, 169, 81, 0.22);
    }
    .hbb-text {
        font-size: 0.62rem;
        letter-spacing: 0.12em;
        color: #fff;
    }
    .hero-para {
        font-size: 0.94rem;
        line-height: 1.78;
        max-width: 100%;
        margin-bottom: 24px;
        color: rgba(242, 235, 217, 0.88);
    }
    .hero-actions {
        width: 100%;
        max-width: 320px;
    }
    .btn-gold {
        width: 100%;
        justify-content: center;
        padding: 16px 22px;
        border-radius: 14px;
        letter-spacing: 0.14em;
    }
    .hero-scroll {
        display: none;
    }

    .sec-h2 {
        font-size: clamp(1.6rem, 6vw, 2.4rem);
    }
    .sec-sub {
        font-size: 0.9rem;
    }
    .sec-eyebrow {
        font-size: 0.6rem;
    }

    .skill-block {
        padding: 20px 16px;
    }
    .skill-item {
        font-size: 0.75rem;
        flex-wrap: wrap;
    }
    .si-note {
        margin-left: 0;
        margin-top: 4px;
        width: 100%;
        text-align: left;
    }

    .phil-q {
        padding: 20px 16px;
    }
    .phil-quotes {
        gap: 16px;
    }
    .phil-kanji {
        font-size: 5rem;
    }

    .about,
    .journey,
    .achievements,
    .training,
    .philosophy {
        padding: 60px var(--gutter);
    }
    .about-grid {
        gap: 32px;
    }
    .journey-inner .sec-h2,
    .ach-header .sec-h2,
    .training-header .sec-h2 {
        text-align: center;
    }
    .footer {
        padding: 28px var(--gutter) calc(28px + env(safe-area-inset-bottom));
        background: var(--bg-2);
    }
    .footer-inner {
        gap: 12px;
    }
    .ft-copy,
    .ft-brand,
    .ft-link,
    .ft-back {
        color: var(--text-70);
        width: 100%;
    }
    .ft-link,
    .ft-back {
        text-align: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero-text-panel {
        padding: calc(var(--nav-h) + 18px) 16px 22px;
    }
    .hero-text-panel::before {
        top: calc(var(--nav-h) + 8px);
        border-radius: 24px 24px 0 0;
    }
    .h1-first,
    .h1-last {
        font-size: clamp(2.2rem, 13vw, 3.3rem);
    }
    .hero-title-line {
        font-size: 0.8rem;
    }
    .hero-para {
        font-size: 0.88rem;
    }
    .hero-actions {
        flex-direction: column;
        max-width: 260px;
    }
    .hero-actions a {
        text-align: center;
        justify-content: center;
        width: 100%;
    }

    .about-stat-row {
        gap: 8px;
    }
    .astat {
        padding: 16px 12px;
    }
    .astat-num {
        font-size: 1.5rem;
    }
    .astat-lbl {
        font-size: 0.55rem;
    }

    .about-tag {
        font-size: 0.6rem;
        padding: 4px 10px;
    }
    .about-quote {
        padding: 16px;
    }
    .about-quote blockquote {
        font-size: 0.9rem;
    }

    .tl-card {
        padding: 16px;
    }
    .tl-card h3 {
        font-size: 0.85rem;
    }
    .tl-card p {
        font-size: 0.75rem;
    }
    .tl-year {
        font-size: 0.55rem;
    }
    .tl-belt {
        font-size: 0.55rem;
    }

    .ach-card {
        padding: 20px 16px;
    }
    .ach-card h3 {
        font-size: 0.8rem;
    }
    .ach-card p {
        font-size: 0.75rem;
    }
    .ac-year {
        font-size: 0.5rem;
    }

    .training-grid {
        gap: 16px;
    }
    .sb-head h3 {
        font-size: 0.8rem;
    }

    .phil-personal {
        font-size: 0.85rem;
    }
    .pq-quote {
        font-size: 0.9rem;
    }
    .pq-attr {
        font-size: 0.55rem;
    }

    .footer {
        padding: 24px var(--gutter);
    }
    .ft-copy,
    .ft-brand,
    .ft-link {
        font-size: 0.65rem;
    }
    .ft-back {
        font-size: 0.6rem;
    }

    .btt {
        width: 36px;
        height: 36px;
        bottom: 20px;
        right: 20px;
    }

    .sbar-label {
        font-size: 0.7rem;
    }
    .sbar-pct {
        font-size: 0.6rem;
    }
}

/* ══════════════════════════════════════
   RESPONSIVE — 768px
══════════════════════════════════════════ */
@media (max-width: 768px) {
    :root {
        --nav-h: 60px;
    }

    .burger {
        display: flex;
    }
    .nav-menu {
        display: none;
        position: fixed;
        top: var(--nav-h);
        left: 0;
        right: 0;
        background: #080808;
        backdrop-filter: blur(20px);
        flex-direction: column;
        gap: 0;
        padding: 16px 0 28px;
        border-bottom: 1px solid rgba(200, 169, 81, 0.12);
        z-index: 9998;
    }
    [data-theme="light"] .nav-menu {
        background: #faf8f3;
    }
    .nav-menu.open {
        display: flex !important;
    }
    .nm-link {
        padding: 13px var(--gutter);
        font-size: 0.8rem;
        color: #f2ebd9;
        opacity: 1;
        visibility: visible !important;
        pointer-events: auto !important;
    }
    .nm-link.highlight {
        margin: 8px var(--gutter);
        text-align: center;
        visibility: visible !important;
        pointer-events: auto !important;
    }

    .ach-grid {
        grid-template-columns: 1fr;
    }
    .about-stat-row {
        gap: 10px;
    }
    .timeline {
        padding-left: 20px;
    }
    .tl-item {
        padding-left: 28px;
    }
    .footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }
    .hero-kanji-deco {
        display: none;
    }
}

@media (max-width: 480px) {
    .h1-first,
    .h1-last {
        font-size: clamp(2.6rem, 13vw, 4rem);
    }
    .hero-actions {
        flex-direction: column;
        max-width: 260px;
    }
    .hero-actions a {
        text-align: center;
        justify-content: center;
    }
}
