:root {
    --bs-body-font-family: "Noto Sans JP", "Yu Gothic", "YuGothic", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Meiryo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --td-primary: #0d6efd;
    --td-primary-soft: #eef5ff;
    --td-dark: #111827;
    --td-body: #212529;
    --td-muted: #6c757d;
    --td-soft-bg: #f8fafc;
    --td-border: rgba(15, 23, 42, 0.08);
    --td-card-shadow: 0 1rem 3rem rgba(15, 23, 42, 0.08);
    --td-card-shadow-sm: 0 0.5rem 1.5rem rgba(15, 23, 42, 0.06);
    --td-radius-sm: 1rem;
    --td-radius-md: 1.5rem;
    --td-radius-lg: 2rem;
}

/* =========================================================
   Base
========================================================= */

html {
    position: relative;
    min-height: 100%;
    font-size: 14px;
    width: 100%;
    max-width: 100%;
    scrollbar-gutter: stable;
}

body {
    min-height: 100vh;
    margin: 0;
    width: 100%;
    max-width: 100%;
    font-family: var(--bs-body-font-family);
    font-weight: 400;
    color: var(--td-body);
    background-color: #ffffff;
    letter-spacing: 0;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

/* 横方向のはみ出し対策。
   main や page wrapper に overflow-x:hidden を付けると、
   ページ内に二重スクロールが出る場合があるため、html/body 側で制御する。 */
@supports (overflow: clip) {
    html,
    body {
        overflow-x: clip;
    }
}

@supports not (overflow: clip) {
    body {
        overflow-x: hidden;
    }
}

button,
input,
select,
textarea {
    font-family: inherit;
}

img,
video {
    max-width: 100%;
}

img {
    height: auto;
}

/* section に overflow:hidden を付けると、アンカー移動やアニメーションで
   予期せず内容が切れる場合があるため、基本は付けない。 */

/* =========================================================
   Typography
========================================================= */

h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--td-dark);
    font-weight: 700;
    letter-spacing: 0;
}

p {
    line-height: 1.85;
}

.lead {
    line-height: 1.85;
}

.text-secondary {
    color: var(--td-muted) !important;
}

.section-eyebrow {
    color: var(--td-primary);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 0.5rem;
}

.section-heading,
.section-title {
    font-weight: 700;
    line-height: 1.3;
    color: var(--td-dark);
}

.section-text,
.section-subtitle {
    color: var(--td-muted);
    line-height: 1.9;
}

/* =========================================================
   Text Utilities
========================================================= */

.text-indent-1 {
    text-indent: 1em;
}

/* =========================================================
   Layout Spacing
========================================================= */

.py-lg-6 {
    padding-top: 5rem;
    padding-bottom: 5rem;
}

/* =========================================================
   Header / Navigation
========================================================= */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: #ffffff;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.site-header-navbar {
    min-height: 84px;
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

.site-header .container {
    display: flex;
    align-items: center;
}

.navbar,
.navbar-brand,
.navbar-nav,
.nav-link {
    font-family: inherit;
}

.site-header .navbar-brand {
    min-width: 0;
    text-decoration: none;
}

.site-header-logo {
    width: 52px;
    height: 52px;
    object-fit: cover;
    border-radius: 0.75rem;
}

.site-header-title {
    font-family: var(--bs-body-font-family);
    font-size: 1.45rem;
    font-weight: 800 !important;
    letter-spacing: -0.04em;
    line-height: 1.08;
    color: #111827 !important;
}

.site-header-subtitle {
    font-family: var(--bs-body-font-family);
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    line-height: 1.25;
    color: #64748b !important;
    margin-top: 0.16rem;
}

.header-nav-list {
    gap: 1.35rem;
    flex-wrap: nowrap;
}

.header-nav-link,
.header-nav-link:link,
.header-nav-link:visited,
.header-nav-link:hover,
.header-nav-link:focus,
.header-nav-link:active {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.72rem 1.05rem !important;
    border-radius: 999px;
    font-family: var(--bs-body-font-family);
    font-size: 0.98rem;
    font-weight: 700 !important;
    line-height: 1;
    letter-spacing: 0;
    white-space: nowrap;
    color: #020617 !important;
    text-decoration: none;
    transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

    .header-nav-link:hover,
    .header-nav-link:focus {
        color: var(--td-primary) !important;
        background: rgba(13, 110, 253, 0.06);
    }

.active-nav-link,
.active-nav-link:hover,
.active-nav-link:focus {
    color: #020617 !important;
    background: rgba(15, 23, 42, 0.045) !important;
    font-weight: 800 !important;
}

/* =========================================================
   Mobile Header / Offcanvas
========================================================= */

.site-menu-toggle {
    width: 44px;
    height: 44px;
    border: 1px solid #dbe3f0;
    border-radius: 14px;
    background: linear-gradient(180deg, #ffffff 0%, #f7f9fc 100%);
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    padding: 0;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    transition: all 0.25s ease;
}

    .site-menu-toggle:hover,
    .site-menu-toggle:focus {
        border-color: #b8c7e6;
        box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
        transform: translateY(-1px);
        outline: none;
    }

    .site-menu-toggle span {
        display: block;
        width: 18px;
        height: 2px;
        border-radius: 999px;
        background: #1f2a44;
    }

.site-mobile-menu {
    width: min(86vw, 360px);
    height: 100vh;
    border-left: 1px solid rgba(15, 23, 42, 0.08);
    background: rgba(255, 255, 255, 0.98);
    z-index: 1060;
}

.site-mobile-menu-header {
    padding: 16px 16px 12px;
    border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.site-mobile-menu-logo {
    width: 40px;
    height: 40px;
    object-fit: cover;
}

.site-mobile-menu-close {
    width: 40px;
    height: 40px;
    border: 1px solid #dbe3f0;
    border-radius: 12px;
    background: #ffffff;
    color: #1f2a44;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

    .site-mobile-menu-close:hover {
        background: #f8fbff;
    }

.site-mobile-menu .offcanvas-body {
    display: flex;
    flex-direction: column;
    padding: 14px 16px 16px;
    gap: 14px;
    overflow: hidden;
}

.site-mobile-menu-scroll {
    flex: 1 1 auto;
    overflow-y: auto;
    padding-right: 2px;
}

.site-mobile-menu-section + .site-mobile-menu-section {
    margin-top: 14px;
}

.site-mobile-menu-section-title {
    font-size: 12px;
    font-weight: 700;
    color: #7b8794;
    letter-spacing: 0.04em;
    margin-bottom: 8px;
}

.site-mobile-menu-links {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.site-mobile-menu-link {
    display: block;
    padding: 12px 14px;
    border-radius: 14px;
    text-decoration: none;
    color: #1f2a44;
    font-weight: 700;
    background: #f8fafc;
    border: 1px solid transparent;
    transition: all 0.2s ease;
}

    .site-mobile-menu-link.soft {
        font-weight: 600;
        background: #fbfcfe;
    }

    .site-mobile-menu-link:hover {
        color: var(--td-primary);
        background: var(--td-primary-soft);
        border-color: #d8e6ff;
    }

.site-mobile-menu-cta {
    flex-shrink: 0;
    padding-top: 12px;
    border-top: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
   Cards
========================================================= */

.card {
    border-radius: var(--td-radius-lg);
}

.ui-card {
    border: 0;
    border-radius: var(--td-radius-lg);
    box-shadow: var(--td-card-shadow);
    background-color: #ffffff;
}

.ui-card-bordered {
    border: 1px solid var(--td-border);
    border-radius: var(--td-radius-lg);
    box-shadow: var(--td-card-shadow);
    background-color: #ffffff;
}

.card-fixed-shadow {
    box-shadow: var(--td-card-shadow);
}

.card.rounded-4 {
    border-radius: var(--td-radius-md) !important;
}

.card.rounded-5,
.rounded-5 {
    border-radius: var(--td-radius-lg) !important;
}

.card.shadow-sm {
    box-shadow: var(--td-card-shadow-sm) !important;
}

.card.shadow,
.card.shadow-lg {
    box-shadow: var(--td-card-shadow) !important;
}

/* =========================================================
   Hover
========================================================= */

.hover-lift {
    transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease, background-color 0.28s ease;
    will-change: transform, box-shadow;
}

@media (hover: hover) and (pointer: fine) {
    .hover-lift {
        cursor: pointer;
    }

        .hover-lift:hover {
            transform: translateY(-8px);
            box-shadow: 0 1.4rem 3rem rgba(15, 23, 42, 0.12) !important;
        }
}

/* =========================================================
   Badges / Pills
========================================================= */

.badge {
    font-weight: 700;
    letter-spacing: 0;
    white-space: normal;
}

.rounded-pill {
    border-radius: 50rem !important;
}

/* =========================================================
   Buttons
========================================================= */

.btn {
    font-weight: 700;
    letter-spacing: 0;
}

.btn-lg {
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}

.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus,
.form-select:focus {
    box-shadow: 0 0 0 0.1rem #ffffff, 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

/* =========================================================
   Icons
========================================================= */

.icon-badge {
    width: 56px;
    height: 56px;
    border-radius: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* =========================================================
   Timeline / Service Point
========================================================= */

.timeline-item,
.service-point-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.timeline-no {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--td-primary-soft);
    color: var(--td-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-weight: 700;
}

.service-point-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: #e9f8ef;
    color: #22c55e;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.15rem;
}

/* =========================================================
   Tables / Definition Lists
========================================================= */

.pricing-table th {
    font-weight: 700;
    white-space: nowrap;
}

.job-summary dt {
    font-weight: 700;
    color: var(--td-dark);
}

.job-summary dd {
    color: var(--td-muted);
}

/* =========================================================
   Reveal Animation
========================================================= */

.reveal-on-scroll {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
    will-change: opacity, transform;
}

    .reveal-on-scroll.is-visible {
        opacity: 1;
        transform: translateY(0);
    }

.reveal-delay-1 {
    transition-delay: 0.08s;
}

.reveal-delay-2 {
    transition-delay: 0.16s;
}

.reveal-delay-3 {
    transition-delay: 0.24s;
}

.reveal-delay-4 {
    transition-delay: 0.32s;
}

.reveal-delay-5 {
    transition-delay: 0.4s;
}

.reveal-delay-6 {
    transition-delay: 0.48s;
}

/* =========================================================
   Responsive
========================================================= */

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

@media (min-width: 992px) {
    .ui-card .card-body,
    .ui-card-bordered .card-body {
        padding: 3rem;
    }

    .site-menu-toggle,
    .site-mobile-menu {
        display: none !important;
    }
}

@media (max-width: 991.98px) {
    .py-lg-6 {
        padding-top: 3rem;
        padding-bottom: 3rem;
    }

    .site-header-navbar {
        min-height: 76px;
    }

    .site-header-logo {
        width: 48px;
        height: 48px;
    }

    .site-header-title {
        font-size: 1.25rem;
        line-height: 1.12;
    }

    .site-header-subtitle {
        font-size: 0.78rem;
        line-height: 1.3;
    }

    .header-nav-list {
        row-gap: 0.25rem;
        flex-wrap: wrap;
    }

    .section-heading {
        font-size: 1.75rem;
    }

    .display-3 {
        font-size: 2.4rem;
    }

    .timeline-item,
    .service-point-item {
        gap: 0.85rem;
        margin-bottom: 1.5rem;
    }
}

@media (max-width: 575.98px) {
    .site-header-navbar {
        min-height: 72px;
    }

    .site-header-logo {
        width: 44px;
        height: 44px;
    }

    .site-header-title {
        font-size: 1.08rem;
        line-height: 1.15;
    }

    .site-header-subtitle {
        font-size: 0.72rem;
        line-height: 1.3;
    }

    .site-header .navbar-brand {
        gap: 0.65rem !important;
    }

    .display-3 {
        font-size: 2rem;
    }

    .lead {
        font-size: 1rem;
    }

    .card-body {
        padding: 1.5rem !important;
    }

    .site-mobile-menu {
        width: min(90vw, 360px);
    }

    .site-mobile-menu-link {
        padding: 11px 12px;
        font-size: 14px;
    }
}

/* =========================================================
   Language Switcher
========================================================= */

.header-language-item {
    position: relative;
    margin-left: 0;
}

.language-switcher {
    position: relative;
    display: inline-flex;
    align-items: center;
    z-index: 1040;
}

.language-switcher::after {
    content: "";
    position: absolute;
    right: 0;
    bottom: -10px;
    width: 100%;
    height: 10px;
}

.language-trigger {
    position: relative;
    min-width: 64px;
    height: 32px;
    padding: 0 0.46rem;
    border: 1px solid rgba(37, 99, 235, 0.18);
    border-radius: 999px;
    background:
        linear-gradient(#ffffff, #ffffff) padding-box,
        linear-gradient(135deg, rgba(13, 110, 253, 0.48), rgba(99, 102, 241, 0.26), rgba(34, 211, 238, 0.42)) border-box;
    color: #0f172a;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.24rem;
    font-weight: 800;
    letter-spacing: 0;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.06);
    overflow: hidden;
    transition:
        transform 0.24s ease,
        box-shadow 0.24s ease,
        border-color 0.24s ease;
}

.language-trigger::before {
    content: "";
    position: absolute;
    inset: -42%;
    background: conic-gradient(
        from 180deg,
        transparent,
        rgba(13, 110, 253, 0.16),
        transparent,
        rgba(34, 211, 238, 0.16),
        transparent
    );
    opacity: 0;
    transform: rotate(0deg);
    transition: opacity 0.25s ease;
}

.language-trigger-glow {
    position: absolute;
    inset: 1px;
    border-radius: inherit;
    background: radial-gradient(circle at 25% 20%, rgba(59, 130, 246, 0.1), transparent 48%);
    pointer-events: none;
}

.language-trigger-icon,
.language-trigger-code,
.language-trigger-arrow {
    position: relative;
    z-index: 1;
}

.language-trigger-icon {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #0d6efd;
    background: rgba(13, 110, 253, 0.08);
    font-size: 0.72rem;
}

.language-trigger-code {
    font-size: 0.74rem;
    line-height: 1;
}

.language-trigger-arrow {
    font-size: 0.54rem;
    color: #64748b;
    transition: transform 0.22s ease;
}

.language-switcher:hover .language-trigger,
.language-switcher:focus-within .language-trigger {
    transform: translateY(-1px);
    box-shadow: 0 10px 22px rgba(13, 110, 253, 0.12);
    border-color: rgba(13, 110, 253, 0.32);
}

.language-switcher:hover .language-trigger::before,
.language-switcher:focus-within .language-trigger::before {
    opacity: 1;
    animation: language-rotate 4s linear infinite;
}

.language-switcher:hover .language-trigger-arrow,
.language-switcher:focus-within .language-trigger-arrow {
    transform: rotate(180deg);
}

.language-panel {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 198px;
    padding: 0.48rem;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 1rem;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.97), rgba(248, 250, 252, 0.93));
    box-shadow:
        0 16px 38px rgba(15, 23, 42, 0.13),
        0 0 0 1px rgba(255, 255, 255, 0.68) inset;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px) scale(0.97);
    transform-origin: top right;
    transition:
        opacity 0.22s ease,
        visibility 0.22s ease,
        transform 0.22s ease;
}

.language-panel::before {
    content: "";
    position: absolute;
    top: -6px;
    right: 21px;
    width: 11px;
    height: 11px;
    background: rgba(255, 255, 255, 0.96);
    border-left: 1px solid rgba(148, 163, 184, 0.18);
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    transform: rotate(45deg);
}

.language-panel::after {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    background: radial-gradient(circle at 20% 0%, rgba(13, 110, 253, 0.1), transparent 42%);
    pointer-events: none;
}

.language-switcher:hover .language-panel,
.language-switcher:focus-within .language-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.language-panel-head {
    position: relative;
    z-index: 1;
    padding: 0.24rem 0.38rem 0.36rem;
}

.language-panel-kicker {
    display: block;
    color: var(--td-primary);
    font-size: 0.58rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.language-panel-title {
    display: block;
    margin-top: 0.08rem;
    color: #0f172a;
    font-size: 0.64rem;
    font-weight: 800;
}

.language-option {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.48rem;
    border-radius: 0.82rem;
    color: #1f2937;
    text-decoration: none;
    transition:
        transform 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease;
}

.language-option + .language-option {
    margin-top: 0.12rem;
}

.language-option:hover,
.language-option:focus {
    color: #0d6efd;
    background: rgba(13, 110, 253, 0.07);
    transform: translateX(2px);
    outline: none;
}

.language-option-code {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    color: #0f172a;
    font-size: 0.6rem;
    font-weight: 900;
    flex-shrink: 0;
}

.language-option-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    min-width: 0;
}

.language-option-text strong {
    font-size: 0.76rem;
}

.language-option-text small {
    margin-top: 0.08rem;
    color: #64748b;
    font-size: 0.6rem;
    font-weight: 600;
}

.language-option-check {
    margin-left: auto;
    color: #0d6efd;
    opacity: 0;
    transform: scale(0.7);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.language-option.is-active {
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.1), rgba(34, 211, 238, 0.08));
    color: #0d6efd;
    box-shadow: 0 7px 15px rgba(13, 110, 253, 0.07);
}

.language-option.is-active .language-option-code {
    background: #0d6efd;
    color: #ffffff;
}

.language-option.is-active .language-option-check {
    opacity: 1;
    transform: scale(1);
}

@keyframes language-rotate {
    to {
        transform: rotate(360deg);
    }
}

/* Mobile language selector */
.site-mobile-language-bar {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 16px;
    background:
        linear-gradient(135deg, rgba(13, 110, 253, 0.07), rgba(255, 255, 255, 0.96) 48%, rgba(34, 211, 238, 0.06));
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.055);
}

.site-mobile-language-title {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #64748b;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.site-mobile-language-title i {
    color: #0d6efd;
    font-size: 13px;
}

.site-mobile-language-list {
    flex: 1 1 auto;
    min-width: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
    padding: 3px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.site-mobile-language-link {
    min-width: 0;
    height: 26px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #1f2a44;
    text-decoration: none;
    font-size: 11px;
    font-weight: 900;
    line-height: 1;
    transition:
        color 0.2s ease,
        background-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.site-mobile-language-link:hover,
.site-mobile-language-link:focus {
    color: #0d6efd;
    background: rgba(13, 110, 253, 0.07);
    outline: none;
}

.site-mobile-language-link.is-active {
    color: #ffffff;
    background: #0d6efd;
    box-shadow: 0 5px 12px rgba(13, 110, 253, 0.18);
}

.site-mobile-language-link.is-active:hover,
.site-mobile-language-link.is-active:focus {
    color: #ffffff;
    transform: translateY(-1px);
}

/* Header spacing fine tune */
@media (min-width: 992px) {
    .header-nav-list {
        gap: 1rem;
    }
}

@media (min-width: 992px) and (max-width: 1199.98px) {
    .header-nav-list {
        gap: 0.5rem;
    }

    .header-nav-link,
    .header-nav-link:link,
    .header-nav-link:visited,
    .header-nav-link:hover,
    .header-nav-link:focus,
    .header-nav-link:active {
        padding-left: 0.74rem !important;
        padding-right: 0.74rem !important;
        font-size: 0.9rem;
    }

    .language-trigger {
        min-width: 62px;
        height: 31px;
        padding-left: 0.42rem;
        padding-right: 0.42rem;
    }
}

@media (max-width: 575.98px) {
    .site-mobile-language-bar {
        gap: 8px;
        padding: 7px 8px;
        border-radius: 14px;
    }

    .site-mobile-language-title {
        font-size: 10px;
    }

    .site-mobile-language-link {
        height: 24px;
        font-size: 10px;
    }
}
