:root {
    /* Colors */
    --primary: #00AEEF;
    --primary-rgb: 0, 174, 239;
    --primary-dark: #008dc2;
    --bg-base: #FFFFFF;
    --bg-pale: #F4FAFD;
    --accent: #FFC107;
    --text-main: #333333;
    --text-light: #666666;
    --white: #FFFFFF;

    /* Border Colors for Cards */
    --border-light: #E1F0F5;

    /* Typography */
    --font-ja: 'Noto Sans JP', sans-serif;
    --font-en: 'Montserrat', sans-serif;

    /* Layout */
    --header-height: 80px;
    --max-width: 1080px;
    --radius-lg: 20px;
    --radius-md: 12px;
    --radius-sm: 8px;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.1);

    /* Card Shadow for Contrast */
    --shadow-card: 0 5px 15px rgba(0, 50, 100, 0.05);
    --shadow-card-hover: 0 15px 30px rgba(0, 174, 239, 0.15);
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* --- Base & Overflow Fixes --- */
html {
    scroll-behavior: smooth;
    font-size: 16px;
    width: 100%;
    overflow-x: hidden;
    position: relative;
}

body {
    font-family: var(--font-ja);
    color: var(--text-main);
    line-height: 1.8;
    background-color: var(--bg-base);
    -webkit-font-smoothing: antialiased;
    width: 100%;
    overflow-x: hidden;
    position: relative;
    overflow-wrap: break-word;
    word-wrap: break-word;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1.5rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
}

/* --- Utilities --- */
.container {
    width: 90%;
    max-width: var(--max-width);
    margin: 0 auto;
    position: relative;
    overflow-x: visible;
}

.section {
    padding: var(--spacing-xl) 0;
    width: 100%;
    overflow-x: hidden;
}

.text-center {
    text-align: center;
}

.text-primary {
    color: var(--primary);
}

.text-accent {
    color: var(--accent);
}

.font-en {
    font-family: var(--font-en);
}

.mb-4 {
    margin-bottom: 1rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-primary {
    background-color: var(--primary);
    color: var(--white);
    border: 2px solid var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-outline {
    background-color: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background-color: var(--primary);
    color: var(--white);
}

/* Animation Utilities */
.fade-in-up {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.delay-200 {
    transition-delay: 0.2s;
}

.delay-400 {
    transition-delay: 0.4s;
}

/* =========================================
   Header & Navigation (Mobile Logic Updated)
   ========================================= */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    /* コンテンツに合わせてシュリンク */
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    z-index: 10000;
    padding: 12px 0;
    /* 全体のパディングで高さを調整 */
}

.header-inner {
    width: 90%;
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;
}

.logo-text {
    font-size: 1.6rem;
    font-family: 'Caveat', cursive;
    font-weight: 700;
    color: var(--primary);
}

.nav {
    flex: 1;
}

.nav-list {
    display: flex;
    gap: 1.8rem;
    align-items: center;
    justify-content: center;
    list-style: none;
}

.nav-list li {
    position: relative;
    display: flex;
    align-items: center;
}

.nav-list a {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-main);
    padding: 0;
    line-height: 1.2;
}

/* --- PC版: ホバーライン（中央揃え） --- */
.nav-list>li>a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    width: 0%;
    height: 2px;
    background-color: var(--primary);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-list>li>a:hover::after {
    width: 100%;
}

/* --- PC版のみポップアップ表示 (901px以上) --- */
@media (min-width: 901px) {
    .nav-list .dropdown {
        position: absolute;
        top: calc(100% + 15px);
        left: 50%;
        transform: translateX(-50%) translateY(10px);
        background-color: var(--white);
        box-shadow: var(--shadow-lg);
        border-radius: var(--radius-md);
        min-width: 200px;
        padding: 0.8rem 0;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 10001;
    }

    .nav-list .dropdown::before {
        content: '';
        position: absolute;
        top: -8px;
        left: 50%;
        transform: translateX(-50%);
        border-left: 8px solid transparent;
        border-right: 8px solid transparent;
        border-bottom: 8px solid var(--white);
    }

    .has-dropdown:hover .dropdown {
        opacity: 1;
        visibility: visible;
        transform: translateX(-50%) translateY(0);
    }

    .dropdown li a {
        padding: 0.6rem 1.5rem;
        font-size: 0.85rem;
        display: block;
    }
}

/* --- モバイル版ナビゲーション (900px以下) --- */
@media (max-width: 900px) {
    .header {
        padding: 10px 0;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--white);
        padding: 4rem 2rem;
        transition: 0.3s ease;
        overflow-y: auto;
    }

    .nav.active {
        right: 0;
    }

    .nav-list {
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
    }

    .nav-list li {
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 1.2rem;
    }

    /* モバイルでは「コース・料金」自体のラインを無効化 */
    .nav-list>li.has-dropdown>a::after {
        display: none !important;
    }

    /* モバイルでのサブメニュー（常時リスト表示） */
    .nav-list .dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        display: block;
        width: 100%;
        padding: 0.5rem 0 0 1rem;
        /* 字下げ */
    }

    .nav-list .dropdown::before {
        display: none;
    }

    .dropdown li {
        margin-bottom: 0;
        padding: 0;
    }

    /* 各コース項目のスタイル */
    .dropdown li a {
        padding: 0.5rem 0;
        font-size: 0.95rem;
        color: var(--text-light);
        display: inline-block;
        /* ラインの幅を文字に合わせるため */
        width: auto;
        position: relative;
    }

    /* モバイル用：各コースを押した（ホバー・アクティブ）際にラインを表示 */
    .dropdown li a::after {
        content: '';
        position: absolute;
        bottom: 2px;
        /* 文字のすぐ下に配置 */
        left: 0;
        width: 0%;
        height: 1px;
        background-color: var(--primary);
        transition: width 0.3s ease;
    }

    .dropdown li a:active::after,
    .dropdown li a:hover::after {
        width: 100%;
    }
}

/* Hero Section (General & Page Specific) */

.page-subtitle {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.9);
}

/* Section Titles */
.section-title {
    font-size: 2.2rem;
    margin-bottom: 1rem;
    text-align: center;
}

.section-title span {
    display: block;
    font-size: 1rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
    letter-spacing: 0.15em;
}

.section-desc {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 3rem;
    color: var(--text-light);
}

/* Empathy Section (Grid) */
.empathy-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.empathy-image-col img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    width: 100%;
}

.empathy-text-col {
    background: var(--white);
    padding: 2rem;
    border-radius: var(--radius-lg);
}

/* Features / Solution Section */
.solution-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 3rem;
    width: 100%;
}

.solution-card {
    background: var(--white);
    padding: 3rem 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
    height: 100%;
    transition: all 0.3s ease;
    border: 2px solid var(--border-light);
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card-icon-circle {
    width: 90px;
    height: 90px;
    background: var(--bg-pale);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.card-icon-circle img {
    width: 75%;
    height: auto;
    object-fit: contain;
}

.solution-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--primary);
    font-weight: 700;
}

.solution-card p {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 0;
}

/* Tablet: Horizontal Layout */
@media (min-width: 501px) and (max-width: 900px) {
    .solution-card {
        flex-direction: row;
        text-align: left;
        padding: 2.5rem;
        gap: 2rem;
        align-items: center;
    }

    .card-icon-circle {
        margin: 0;
        width: 100px;
        height: 100px;
    }

    .solution-content {
        flex-grow: 1;
    }

    .solution-card h3 {
        margin-bottom: 0.5rem;
    }
}

/* Desktop: 3 Column Grid */
@media (min-width: 901px) {
    .solution-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Glass Card (Used in About/Contact/Results) */
.glass-card {
    background: rgba(255, 255, 255, 0.9);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-md);
    padding: 2rem;
    transition: transform 0.3s ease;
}

/* Courses Section */
.courses-section {
    background-color: var(--bg-pale);
}


/* =========================================
   FAQ Section - Smart Accordion Layout
   ========================================= */

/* FAQリスト全体のレイアウト */
.faq-list {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    /* align-items: start にすることで、開いたカードが隣のカードを強制的に伸ばすのを防ぎます */
    align-items: start;
}

/* 各FAQカード */
.faq-item {
    background: var(--white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    border-left: 4px solid var(--primary);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
    /* カード単体で完結する高さに設定 */
    height: auto;
    overflow: hidden;
}

.faq-item:hover {
    box-shadow: var(--shadow-md);
}

/* 質問エリア（summaryタグ） */
.faq-question {
    font-size: 1.1rem;
    color: var(--text-main);
    font-weight: 700;
    line-height: 1.5;
    padding: 1.5rem;
    cursor: pointer;
    list-style: none;
    position: relative;
    padding-right: 3.5rem;
    display: flex;
    /* 文字を枠の上端に揃える */
    align-items: flex-start;
    /* 閉じている時の高さを揃えるための最小高さ（必要に応じて調整） */
    min-height: 4.5rem;
}

.faq-question::-webkit-details-marker {
    display: none;
}

/* カスタム矢印アイコン */
.faq-question::after {
    content: '';
    position: absolute;
    right: 1.5rem;
    /* アイコンも上端（テキスト1行目）の高さに固定 */
    top: 1.8rem;
    width: 10px;
    height: 10px;
    border-right: 2px solid var(--primary);
    border-bottom: 2px solid var(--primary);
    transform: rotate(45deg);
    transition: transform 0.4s ease;
}

/* 開いている時の矢印 */
.faq-item[open] .faq-question::after {
    transform: rotate(-135deg) translateY(-2px) translateX(-2px);
}

/* --- スムーズな展開アニメーション --- */
.faq-answer-container {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.4s ease-in-out;
}

.faq-item[open] .faq-answer-container {
    grid-template-rows: 1fr;
}

.faq-answer {
    overflow: hidden;
    min-height: 0;
}

/* 回答テキスト */
.faq-answer p {
    padding: 1rem 1.5rem 1.5rem;
    margin: 0 1.5rem;
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.7;
    border-top: 1px dashed var(--border-light);
}

/* --- レスポンシブ対応 --- */
@media (min-width: 768px) {
    .faq-list {
        /* PC版：2列表示 */
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    .faq-question {
        padding: 1.8rem 2rem;
        padding-right: 4rem;
        /* PC版のフォントサイズに合わせて最小高さを微調整 */
        min-height: 5.5rem;
    }

    .faq-question::after {
        top: 2.1rem;
        right: 2rem;
    }
}

/* CTA Section */
.cta-section {
    position: relative;
    padding: 8rem 0;
    background-color: var(--bg-pale);
    overflow: hidden;
    width: 100%;
    text-align: center;
}

.cta-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    opacity: 0.8;
    object-position: center bottom;
}

.cta-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.6) 0%, rgba(255, 255, 255, 0.9) 100%);
    z-index: 1;
    backdrop-filter: blur(2px);
}

.cta-container {
    position: relative;
    z-index: 2;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 2rem;
    color: var(--text-main);
    line-height: 1.4;
    text-shadow: 0 2px 10px rgba(255, 255, 255, 0.8);
}

.cta-title .font-en {
    display: block;
    font-size: 1.2rem;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
    font-weight: 700;
    color: var(--primary);
}

.cta-desc {
    color: var(--text-light);
    margin-bottom: 3rem;
    font-weight: 600;
}

.btn-lg {
    padding: 1.2rem 3.5rem;
    font-size: 1.1rem;
}

.shadow-lg {
    box-shadow: 0 10px 20px rgba(0, 174, 239, 0.25);
}

@media (max-width: 500px) {
    .cta-section {
        padding: 5rem 0;
    }

    .cta-title {
        font-size: 1.8rem;
    }

    .cta-title .font-en {
        font-size: 1rem;
    }
}

/* Footer */
.footer {
    background-color: #1a202c;
    color: #cbd5e0;
    padding: 2rem 0;
    font-size: 0.9rem;
    overflow-x: hidden;
    width: 100%;
}

/* --- Media Queries --- */
@media (max-width: 1200px) and (min-width: 901px) {
    .header {
        height: auto;
        padding: 1rem 0;
    }

    .header-inner {
        flex-wrap: wrap;
        gap: 1rem;
    }

    .logo {
        order: 1;
        flex: 0 0 auto;
    }

    .header-cta {
        order: 2;
        margin-left: auto;
        display: flex;
    }

    .nav {
        order: 3;
        flex: 0 0 100%;
        width: 100%;
        margin-top: 0.5rem;
    }

    .nav-list {
        display: flex;
        width: 100%;
        justify-content: space-between;
        gap: 0;
    }

    .nav-list li {
        flex: 1;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .nav-list a {
        white-space: nowrap;
        font-size: 0.9rem;
    }

    .nav-list a::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .hero {
        padding-top: 13rem;
    }
}

@media (max-width: 900px) {
    .header-cta {
        display: inline-flex;
        margin-left: auto;
        margin-right: 1.5rem;
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
    }

    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        gap: 6px;
        cursor: pointer;
        z-index: 1001;
    }

    .mobile-menu-toggle span {
        width: 25px;
        height: 2px;
        background-color: var(--text-main);
        transition: 0.3s;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--white);
        padding: 5rem 2rem;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
        transition: 0.3s ease;
    }

    .nav.active {
        right: 0;
    }

    .nav-list {
        flex-direction: column;
    }

    /* モバイルではホバーラインを無効化 */
    .nav-list>li>a::after {
        display: none;
    }

    .section {
        padding: 4rem 0;
    }


    .empathy-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .empathy-text-col {
        padding: 1.5rem 0.5rem;
        margin: 0 0.5rem;
        box-shadow: none;
        border-radius: var(--radius-md);
    }
}

@media (max-width: 500px) {
    .container {
        width: 90%;
    }

    .logo-text {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.75rem;
        line-height: 1.35;
    }

    .section-title .title-group {
        flex-direction: column;
        gap: 0;
    }

    .section-title .title-divider {
        display: none;
    }


    .cta-title {
        font-size: 2rem;
    }

}

/* Mobile Sticky CTA */
.mobile-sticky-cta {
    display: none;
    position: fixed;
    bottom: 20px;
    left: 0;
    width: 100%;
    z-index: 9999;
    padding: 0 5%;
    pointer-events: none;
}

.mobile-sticky-cta .btn {
    pointer-events: auto;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1rem;
    font-size: 1.1rem;
    box-shadow: 0 4px 20px rgba(0, 174, 239, 0.4);
    border: 2px solid rgba(255, 255, 255, 0.8);
    background: var(--primary);
    animation: fadeUp 0.5s ease-out forwards;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 600px) {
    .header-cta {
        display: none;
    }

    .hero-cta-wrapper {
        display: none;
    }

    .mobile-menu-toggle {
        margin-left: auto;
    }

    .mobile-sticky-cta {
        display: block;
    }

    body {
        padding-bottom: 0;
    }

    .footer {
        padding-bottom: 120px;
    }
}

/* =========================================
   Support Section (Permanent Glow & No Animation)
   ========================================= */

/* Grid Layout Base */
.support-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
    margin-top: 3rem;
}

/* Support Card Base Style */
.support-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 25px rgba(0, 174, 239, 0.15);
    border: 1px solid rgba(0, 174, 239, 0.3);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Image Wrapper */
.support-card-img-box {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
    background-color: var(--bg-pale);
    border-bottom: 1px solid var(--border-light);
}

.support-card-img-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 60%, rgba(0, 0, 0, 0) 100%);
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 60%, rgba(0, 0, 0, 0) 100%);
    opacity: 1;
}

/* Text Content */
.support-card-info {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    text-align: center;
    justify-content: flex-start;
}

.support-card-info h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.8rem;
    line-height: 1.4;
}

.support-card-info p {
    font-size: 0.95rem;
    color: var(--text-light);
    margin-bottom: 0;
    line-height: 1.7;
}

/* --- Responsive Layout Adjustments --- */
@media (min-width: 501px) {
    .support-card {
        flex-direction: row;
        align-items: stretch;
        text-align: left;
    }

    .support-card-img-box {
        width: 40%;
        height: auto;
        min-height: 180px;
        border-bottom: none;
        border-right: 1px solid var(--border-light);
    }

    .support-card-img-box img {
        height: 100%;
        -webkit-mask-image: linear-gradient(to right, rgba(0, 0, 0, 1) 70%, rgba(0, 0, 0, 0) 100%);
        mask-image: linear-gradient(to right, rgba(0, 0, 0, 1) 70%, rgba(0, 0, 0, 0) 100%);
    }

    .support-card-info {
        width: 60%;
        padding: 2rem 1.5rem;
        justify-content: center;
    }

    .support-card-info h3 {
        margin-bottom: 0.5rem;
    }
}

@media (min-width: 768px) {
    .support-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .support-card {
        flex-direction: column;
        text-align: center;
    }

    .support-card-img-box {
        width: 100%;
        height: 200px;
        border-right: none;
        border-bottom: 1px solid var(--border-light);
    }

    .support-card-img-box img {
        -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 60%, rgba(0, 0, 0, 0) 100%);
        mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 60%, rgba(0, 0, 0, 0) 100%);
    }

    .support-card-info {
        width: 100%;
        padding: 2rem;
        justify-content: flex-start;
    }
}

@media (min-width: 1024px) {
    .support-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 2.5rem;
    }
}

/* =========================================
   コースページ共通スタイル (3q.html, p2q.html等)
   ========================================= */

/* --- 悩みセクション：幅いっぱい画像付きカード --- */