:root {
    --background-main: #030303;
    --background-card: #080808;
    --border-main: #141414;
    --text-main: #dcdcdc;
    --text-sub: #777;
    --text-dark: #444;
}

* {
    box-sizing: border-box;
}

html {
    margin: 0;
    padding: 0;
    width: 100%;
    scroll-behavior: smooth;
    background: var(--background-main);
}

body {
    margin: 0;
    padding: 0;
    width: 100%;
    min-height: 100%;
    overflow-x: hidden;
    background: var(--background-main);
    color: var(--text-main);
    font-family: "Helvetica Neue", Arial, sans-serif;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 50;

    background:
        repeating-linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0.008) 0,
            rgba(255, 255, 255, 0.008) 1px,
            transparent 1px,
            transparent 4px
        );

    opacity: 0.18;
}

/* Header - 構造設計の刷新 */

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;

    display: flex;
    align-items: center;
    justify-content: space-between;

    min-height: 72px;
    padding: 18px 38px;

    background: rgba(3, 3, 3, 0.82);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);

    border-bottom: 1px solid rgba(255, 255, 255, 0.05);

    z-index: 100;

    overflow-wrap: anywhere;
    word-break: normal;

}

/* 左側の塊をDIVで完全制御 */
.header-left {
    display: flex;
    align-items: center;
    gap: 24px;
    min-width: 0;
}

.header-brand {
    display: flex;
    align-items: center;
    min-width: 0;
}

.brand-tagline {
    color: rgba(255,255,255,.72);
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    white-space: nowrap;
}

.header-logos {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
}

.header-logos img {
    display: block;
    width: 104px;
    height: auto;
    object-fit: contain;
}

/* メニューの塊をDIVで完全制御 */
.header-nav {
    display: flex;
    align-items: center;
}

nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
}

nav a {
    margin-left: 30px;

    color: #666;
    text-decoration: none;

    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;

    white-space: nowrap;

    transition:
        color 0.3s ease,
        opacity 0.3s ease;
}

nav a:hover,
nav a:focus-visible {
    color: #fff;
}

/* Hero */

.hero-section {
    position: relative;

    width: 100%;
    min-height: 100vh;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;
    isolation: isolate;

    padding: 120px 20px 70px;
}

.hero-video-wrapper {
    position: absolute;
    inset: 0;
    z-index: -3;
    overflow: hidden;

    background: #000;
}

.hero-video {

    position: absolute;
    top: 50%;
    left: 50%;

    width: 110%;
    height: 110%;

    min-width: 100%;
    min-height: 100%;

    object-fit: cover;

    transform: translate(-50%, -50%) scale(1.08);

    filter:
        blur(1.5px)
        brightness(0.50)
        saturate(0.90)
        contrast(1.08);

    will-change: transform;
}

.hero-video-overlay {

    background:
        radial-gradient(
            circle at center,
            rgba(0,0,0,.04) 0%,
            rgba(0,0,0,.22) 58%,
            rgba(3,3,3,.72) 100%
        ),

        linear-gradient(
            to bottom,
            rgba(3,3,3,.12) 0%,
            rgba(3,3,3,.08) 45%,
            rgba(3,3,3,.70) 100%
        );
}

.hero-video-noise {
    position: absolute;
    inset: 0;
    z-index: -1;

    background:
        repeating-linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0.01) 0,
            rgba(255, 255, 255, 0.01) 1px,
            transparent 1px,
            transparent 4px
        );

    opacity: 0.25;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;

    width: 100%;
    max-width: 900px;

    display: flex;
    flex-direction: column;
    align-items: center;

    text-align: center;
}

.hero-presented {
    margin: 0 0 30px;

    color: rgba(255, 255, 255, 0.52);

    font-size: 9px;
    font-weight: 600;
    letter-spacing: 5px;
    text-transform: uppercase;
}

.hero-title-box {
    width: 100%;
    margin-bottom: 24px;
}

.hero-title-box img {
    display: block;

    width: min(520px, 82vw);
    height: auto;

    margin: 0 auto;

    object-fit: contain;
    filter: none;
    opacity: 1;
}

.hero-subtitle {
    margin: 0 0 38px;

    color: rgba(255, 255, 255, 0.58);

    font-size: 10px;
    font-weight: 600;
    letter-spacing: 8px;
    text-transform: uppercase;
}

.hero-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;

    gap: 14px;
}

.hero-button {
    min-width: 160px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    padding: 15px 26px;

    border: 1px solid rgba(255, 255, 255, 0.35);

    color: #fff;
    background: rgba(0, 0, 0, 0.22);

    text-decoration: none;

    font-size: 10px;
    font-weight: 600;
    letter-spacing: 2.6px;
    text-transform: uppercase;

    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);

    transition:
        background 0.3s ease,
        color 0.3s ease,
        border-color 0.3s ease,
        transform 0.3s ease;
}

.hero-button:hover,
.hero-button:focus-visible {
    background: #fff;
    color: #050505;
    border-color: #fff;
    transform: translateY(-2px);
}

.hero-button-secondary {
    border-color: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.72);
}

.scroll-indicator {
    position: absolute;
    left: 50%;
    bottom: 24px;

    width: 1px;
    height: 45px;

    background:
        linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0.8),
            rgba(255, 255, 255, 0)
        );

    transform: translateX(-50%);
    opacity: 0.5;
}

/* Introduction */

.introduction {
    max-width: 960px;
    color: #888;
    font-size: 13px;
    line-height: 2.2;
    letter-spacing: 1.5px;
    justify-content: center;
    margin: 0 auto;
}

.introduction p {
    text-align: center;
}

/* Common sections */

section.content-block {
    width: 100%;
    max-width: 1200px;

    margin: 0 auto;
    padding: 120px 40px;

    border-bottom: 1px solid #111;
}

.section-title {
    position: relative;

    margin: 0 0 60px;
    padding-left: 15px;

    color: #fff;

    font-size: 14px;
    font-weight: 600;
    letter-spacing: 6px;
    text-transform: uppercase;
}

.section-title::before {
    content: "";

    position: absolute;
    top: 2px;
    bottom: 2px;
    left: 0;

    width: 1px;

    background: #fff;
}

/* Character */

.character-grid {
    width: 100%;

    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));

    gap: 30px;
}

.character-card {
    overflow: hidden;

    background: var(--background-card);
    border: 1px solid var(--border-main);
    border-radius: 2px;

    transition:
        border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.character-card:hover {
    border-color: #333;
    transform: translateY(-5px);
}

.char-img-box {
    width: 100%;
    aspect-ratio: 11 / 14;

    overflow: hidden;

    background: #0f0f0f;
    border-bottom: 1px solid var(--border-main);
}

.char-img-box img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: contain;
    object-position: center;
}

.char-info {
    padding: 25px 20px;
}

.char-id {
    margin-bottom: 8px;

    color: #555;

    font-family: monospace;
    font-size: 9px;
    letter-spacing: 1.5px;
}

.char-name {
    margin: 0 0 10px;

    color: #fff;

    font-size: 15px;
    font-weight: 600;
    letter-spacing: 1px;
}

.char-role {
    color: #444;

    font-size: 10px;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Team and Legacy */

.split-layout {
    width: 100%;

    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));

    gap: 50px;
}

.info-box {
    padding: 45px;

    background: var(--background-card);
    border: 1px solid var(--border-main);
    border-radius: 2px;
}

.info-box h3 {
    margin: 0 0 25px;

    color: #fff;

    font-size: 13px;
    letter-spacing: 4px;
    text-transform: uppercase;
}

.info-box p {
    margin: 0 0 30px;

    color: var(--text-sub);

    font-size: 12px;
    line-height: 2.4;
}

.legacy-img-box {
    width: 100%;

    overflow: hidden;

    background: #0f0f0f;
}

.legacy-img-box img {
    display: block;

    width: 100%;
    height: auto;

    padding-top: 20%;
    padding-bottom: 20%;
}

.legacy-description {
    margin: 18px 0 0;
    padding: 18px;

    color: var(--text-sub);

    font-size: 12px;
    line-height: 2.1;
}

/* About */

.about-table {
    width: 100%;

    margin-top: 20px;

    border-collapse: collapse;
}

.about-table th,
.about-table td {
    padding: 24px 20px;

    border-bottom: 1px solid #111;

    text-align: left;

    font-size: 11px;
    letter-spacing: 1.5px;
    vertical-align: top;
}

.about-table th {
    width: 25%;

    color: #484848;

    font-weight: 600;
    text-transform: uppercase;
}

.about-table td {
    color: #999;
    line-height: 1.8;
}

.schedule-line {
    display: block;
    margin-bottom: 4px;
}

/* Footer */

footer {
    padding: 80px 40px;

    background: #010101;
    border-top: 1px solid #111;

    text-align: center;
}

.footer-logo {
    display: block;

    width: 126px;
    height: auto;

    margin: 0 auto 25px;

    filter: none;
    opacity: 1;
}

.footer-copy {
    color: #666;

    font-size: 12px;
}

.footer-disclaimer {
    max-width: 700px;

    margin: 18px auto 0;

    color: #444;

    font-size: 10px;
    line-height: 1.8;
}

/* Candy Pop gateway */

.candy-pop-gateway {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 120px 40px;
    border-bottom: 1px solid #111;
}

.candy-pop-link {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.75fr);
    align-items: stretch;
    overflow: hidden;
    border: 1px solid #1b1b1b;
    background: #080808;
    color: inherit;
    text-decoration: none;
    transition:
        transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
        border-color 0.35s ease;
}

.candy-pop-link:hover,
.candy-pop-link:focus-visible {
    transform: translateY(-5px);
    border-color: #444;
}

.candy-pop-image {
    min-height: 360px;
    overflow: hidden;
    background: #111;
}

.candy-pop-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.candy-pop-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px;
}

.candy-pop-label {
    margin-bottom: 18px;
    color: #777;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.candy-pop-copy h3 {
    margin: 0 0 18px;
    color: #fff;
    font-size: clamp(28px, 4vw, 52px);
    font-weight: 600;
    letter-spacing: 1px;
}

.candy-pop-copy p {
    margin: 0 0 30px;
    color: #888;
    font-size: 12px;
    line-height: 2;
    letter-spacing: 0.8px;
}

.candy-pop-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-width: 188px;
    min-height: 46px;
    padding: 0 20px;
    gap: 12px;
    border: 1px solid #444;
    color: #fff;
    background: rgba(255, 255, 255, 0.02);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    transition:
        border-color 0.3s ease,
        background 0.3s ease;
}

.candy-pop-cta::after {
    content: "→";
    font-size: 15px;
    transition: transform 0.3s ease;
}

.candy-pop-link:hover .candy-pop-cta,
.candy-pop-link:focus-visible .candy-pop-cta {
    border-color: #888;
    background: rgba(255, 255, 255, 0.06);
}

.candy-pop-link:hover .candy-pop-cta::after,
.candy-pop-link:focus-visible .candy-pop-cta::after {
    transform: translateX(6px);
}

/* Responsive (新しいDIV構造に基づいた確実な制御) */

@media (max-width: 960px) {
    .character-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    header {
        min-height: auto;
        padding: 16px 20px;
        flex-direction: column;
        justify-content: center;
        gap: 14px;
    }

    .header-left {
        width: 100%;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 8px;
        text-align: center;
    }

    .header-brand {
        justify-content: center;
    }

    .brand-tagline {
        white-space: normal;
        text-align: center;
    }

    .header-logos {
        justify-content: center;
    }

    .header-nav {
        width: 100%;
        justify-content: center;
    }

    nav {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px 16px;
    }

    nav a {
        margin-left: 0;
        font-size: 8.5px;
        letter-spacing: 1.5px;
        white-space: normal;
    }

    .hero-section {
        min-height: 100svh;
        padding: 150px 20px 60px;
    }

    .hero-presented {
        letter-spacing: 3px;
    }

    .hero-subtitle {
        letter-spacing: 4px;
        line-height: 1.8;
    }

    section.content-block {
        padding: 90px 24px;
    }

    .split-layout {
        grid-template-columns: 1fr;
    }

    .info-box {
        padding: 30px;
    }

    .candy-pop-link {
        grid-template-columns: 1fr;
    }

    .candy-pop-image {
        min-height: auto;
        aspect-ratio: 16 / 9;
    }

    .candy-pop-copy {
        padding: 34px 28px 38px;
    }

    .about-table th,
    .about-table td {
        display: block;
        width: 100%;
    }

    .about-table th {
        padding-bottom: 7px;
        border-bottom: none;
    }

    .about-table td {
        padding-top: 0;
    }
}

@media (max-width: 560px) {
    .character-grid {
        grid-template-columns: 1fr;
    }

    .hero-buttons {
        width: 100%;
        flex-direction: column;
    }

    .hero-button {
        width: min(300px, 100%);
    }
}

/* Reduced Motion */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .hero-video {
        display: none;
    }

    .hero-video-wrapper {
        background:
            radial-gradient(
                circle at center,
                #171717 0%,
                #030303 75%
            );
    }

    .character-card,
    .hero-button {
        transition: none;
    }
}

.footer-company {
    margin-bottom: 24px;
    text-align: center;
}

.footer-presented {
    color: #888;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.footer-founded {
    color: #555;
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
}