:root {
    --bg: #e9e3d5;
    --surface: #ffffff;
    --ink: #1f2430;
    --muted: #6b7280;
    --border: #e5e2da;
    --accent: #2f6fed;
    --accent-soft: #e7edfd;
    --hero-bg-from: #171a24;
    --hero-bg-to: #2a3050;
    --hero-ink: #ffffff;
    --hero-muted: rgba(255, 255, 255, 0.72);
    --badge-plugin-from: #ff5f6d;
    --badge-plugin-to: #ff2d55;
    --badge-plugin-ink: #ffffff;
    --badge-duration-bg: rgba(17, 20, 28, 0.78);
    --badge-duration-ink: #ffffff;
    --btn-hover-from: #4b8f8c;
    --btn-hover-to: #3a6d8f;
    --radius: 16px;
    --font-display: "Sora", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Segoe UI", sans-serif;
    --font-body: "Inter", "Hiragino Kaku Gothic ProN", "Yu Gothic", "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--ink);
    animation: page-fade-in 0.32s ease;
}

body.is-leaving {
    opacity: 0;
    transition: opacity 0.16s ease;
}

@keyframes page-fade-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-shell {
    max-width: 1200px;
    margin: 0 auto;
    background: var(--surface);
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(30, 22, 12, 0.14);
    border: 1px solid var(--border);
    border-top: none;
}

@media (max-width: 720px) {
    .page-shell {
        border-width: 0;
    }
}

.hero {
    position: relative;
    display: flex;
    align-items: flex-end;
    min-height: 340px;
    padding: 40px 40px 110px;
    background: linear-gradient(135deg, var(--hero-bg-from), var(--hero-bg-to));
    color: var(--hero-ink);
    overflow: hidden;
}

.hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    filter: grayscale(0.35) saturate(1.15) contrast(1.1) brightness(0.9);
    /* 動画右端にわずかに写り込む黒帯を切り取るため、左基準で少しだけ拡大する。 */
    transform: scale(1.08);
    transform-origin: left center;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        repeating-linear-gradient(rgba(0, 0, 0, 0.1) 0, rgba(0, 0, 0, 0.1) 1px, transparent 1px, transparent 3px),
        linear-gradient(90deg, rgba(10, 22, 40, 0.72) 0%, rgba(10, 22, 40, 0.55) 40%, rgba(10, 22, 40, 0.15) 100%);
}

.hero-inner {
    position: relative;
    z-index: 2;
    margin-bottom: 56px;
}

.hero-explainer-btn.card-media-link {
    position: absolute;
    left: 40px;
    bottom: 110px;
    z-index: 2;
    width: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 9px 20px;
    border: none;
    border-radius: 999px;
    background: #3a4a5f;
    color: #ffffff;
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 600;
    white-space: nowrap;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
}

.hero-explainer-btn.card-media-link:hover {
    background: linear-gradient(135deg, #4c8cf7, #1f4fd1);
    transform: translateY(-1px);
}

@media (max-width: 620px) {
    .hero-explainer-btn.card-media-link {
        left: 20px;
        bottom: 90px;
        padding: 8px 18px;
        font-size: 0.78rem;
    }
}

.hero-eyebrow {
    margin: 0 0 8px;
    font-family: var(--font-display);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--hero-muted);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.hero-title {
    margin: 0 0 10px;
    font-family: var(--font-display);
    font-size: 2.3rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    text-shadow: 0 3px 14px rgba(0, 0, 0, 0.75);
}

.hero-logo-link {
    color: inherit;
    text-decoration: none;
}

.hero-logo-link:hover {
    text-decoration: underline;
}

.hero-subtitle {
    margin: 0;
    color: var(--hero-muted);
    font-size: 0.95rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.catalog-toolbar {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    padding: 20px 40px;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
}

.hero-count {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--muted);
}

.toggle-filter {
    display: flex;
    align-items: center;
    justify-self: end;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    user-select: none;
    color: var(--muted);
}

.toolbar-page-indicator {
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--muted);
    white-space: nowrap;
    justify-self: center;
}

.toggle-filter input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.toggle-track {
    position: relative;
    width: 38px;
    height: 21px;
    flex-shrink: 0;
    background: #d9d3c4;
    border-radius: 999px;
    transition: background 0.15s ease;
}

.toggle-track::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background: #ffffff;
    transition: transform 0.15s ease;
}

.toggle-filter input:checked ~ .toggle-track {
    background: #34c77b;
}

.toggle-filter input:checked ~ .toggle-track::after {
    transform: translateX(17px);
}

.toggle-filter input:focus-visible ~ .toggle-track {
    outline: 2px solid #34c77b;
    outline-offset: 2px;
}

.page-container {
    padding: 40px 40px 48px;
}

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

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

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

    .hero {
        min-height: 320px;
        padding: 28px 20px 80px;
    }

    .hero-inner {
        margin-bottom: 64px;
    }

    .hero-eyebrow {
        font-size: 0.7rem;
    }

    .hero-title {
        font-size: 1.5rem;
    }

    .hero-subtitle {
        font-size: 0.82rem;
    }

    .catalog-toolbar {
        grid-template-columns: 1fr;
        justify-items: center;
        text-align: center;
        padding: 16px 20px;
    }

    .toggle-filter,
    .toolbar-page-indicator {
        justify-self: center;
    }

    .page-container {
        padding: 28px 20px 40px;
    }
}

.card {
    display: flex;
    flex-direction: column;
}

.card-media-link {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: none;
    text-align: left;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    font: inherit;
}

.card-media {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #11141c;
    overflow: hidden;
    border-radius: var(--radius);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover .card-media {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
}

.card-thumb,
.card-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.15s ease;
}

.card-video {
    opacity: 0;
}

.card:hover .card-video {
    opacity: 1;
}

.card:hover .card-thumb {
    opacity: 0;
}

.card-caption {
    padding: 14px 2px 0;
}

.card-title {
    margin: 0;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-number {
    display: inline-block;
    font-family: var(--font-display);
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 700;
    font-size: 0.72rem;
    padding: 2px 8px;
    border-radius: 999px;
    margin-right: 8px;
    vertical-align: middle;
    white-space: nowrap;
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
}

.card-price {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--ink);
    white-space: nowrap;
}

.btn-request {
    display: inline-block;
    margin-left: auto;
    padding: 6px 14px;
    border-radius: 999px;
    border: none;
    background: #5c6b80;
    color: #ffffff;
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease;
}

.btn-request:hover {
    background: linear-gradient(135deg, var(--btn-hover-from), var(--btn-hover-to));
    transform: translateY(-1px);
}

.badge {
    position: absolute;
    z-index: 2;
    font-size: 0.65rem;
    font-weight: 600;
    padding: 3px 9px;
    border-radius: 999px;
    white-space: nowrap;
}

.badge-plugin {
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, var(--badge-plugin-from), var(--badge-plugin-to));
    color: var(--badge-plugin-ink);
    box-shadow: 0 2px 8px rgba(255, 45, 85, 0.45);
}

.badge-duration {
    bottom: 8px;
    right: 8px;
    background: var(--badge-duration-bg);
    color: var(--badge-duration-ink);
    font-weight: 500;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 48px;
}

.page-arrow {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--surface);
    border: 1px solid var(--border);
    font-size: 1.1rem;
    color: var(--ink);
    text-decoration: none;
    transition: border-color 0.15s ease, color 0.15s ease;
}

.page-arrow:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.page-arrow-disabled {
    opacity: 0.35;
    pointer-events: none;
}

.page-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
    transition: transform 0.15s ease, background 0.15s ease;
}

.page-dot:hover {
    background: var(--muted);
    transform: scale(1.25);
}

.page-dot-active {
    background: var(--accent);
    transform: scale(1.35);
}

.page-count {
    margin: 10px 0 0;
    text-align: center;
    font-family: var(--font-display);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: var(--muted);
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--muted);
    padding: 60px 0;
}

.lightbox {
    border: none;
    border-radius: var(--radius);
    padding: 0;
    background: transparent;
    max-width: min(900px, 92vw);
    width: 100%;
}

.lightbox::backdrop {
    background: rgba(10, 12, 18, 0.78);
}

.lightbox-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: auto;
    height: auto;
    border-radius: 0;
    border: none;
    background: none;
    color: #ffffff;
    font-size: 2rem;
    line-height: 1;
    padding: 0;
    cursor: pointer;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
    z-index: 2;
}

.lightbox-close:hover {
    color: var(--accent);
    background: none;
}

.lightbox-video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius);
    background: #000;
}

.lightbox-title {
    margin: 14px 4px 0;
    color: #ffffff;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7);
}

.site-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 24px 40px 32px;
    border-top: 1px solid var(--border);
}

.footer-copyright {
    font-family: var(--font-body);
    font-size: 0.78rem;
    color: var(--muted);
    text-decoration: none;
}

.footer-copyright:hover {
    color: var(--accent);
}

.footer-notice-link {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    padding: 0;
    font-family: var(--font-body);
    font-size: 0.8rem;
    color: var(--muted);
    text-decoration: underline;
    cursor: pointer;
}

.footer-notice-en {
    font-family: var(--font-display);
    font-size: 0.62rem;
    letter-spacing: 0.04em;
    text-decoration: none;
    opacity: 0.6;
}

.footer-notice-link:hover {
    color: var(--accent);
}

@media (max-width: 620px) {
    .site-footer {
        justify-content: center;
        text-align: center;
        padding: 20px 20px 28px;
    }
}

.notice-dialog {
    border: none;
    border-radius: var(--radius);
    padding: 32px 36px;
    background: var(--surface);
    max-width: min(560px, 92vw);
    width: 100%;
    box-shadow: 0 20px 50px rgba(30, 22, 12, 0.2);
}

.notice-dialog::backdrop {
    background: rgba(10, 12, 18, 0.6);
}

.notice-close {
    position: absolute;
    top: 14px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: var(--accent-soft);
    color: var(--ink);
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
}

.notice-close:hover {
    background: var(--accent);
    color: #ffffff;
}

.notice-content h2 {
    margin: 0 0 16px;
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--ink);
}

.notice-heading-en {
    display: block;
    margin-top: 6px;
    font-family: var(--font-display);
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--muted);
}

.notice-content p {
    margin: 0 0 12px;
    font-size: 0.88rem;
    line-height: 1.7;
    color: var(--ink);
}

.notice-content p:last-child {
    margin-bottom: 0;
}

.notice-divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 20px 0;
}
