/* Base & Variables */
:root {
    --primary: #1b4332;
    --primary-light: #2d6a4f;
    --accent: #d4a373;
    --accent-light: #faedcd;
    --text: #333333;
    --text-light: #666666;
    --bg-light: #fdfaf5;
    --white: #ffffff;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.12);
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --font-serif: 'Noto Serif JP', serif;
    --font-sans: 'Noto Sans JP', sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    color: var(--text);
    background-color: var(--white);
    line-height: 1.8;
    overflow-x: hidden;
}

body.no-scroll {
    overflow: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-fluid {
    padding: 0 40px;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-family: var(--font-serif);
    line-height: 1.4;
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 16px 40px;
    border-radius: 60px;
    font-weight: 700;
    letter-spacing: 0.05em;
    cursor: pointer;
    text-align: center;
    border: none;
    box-shadow: var(--shadow-sm);
}

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

.btn-secondary {
    background-color: var(--accent);
    color: var(--white);
}

/* Header Styles */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: var(--white);
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: var(--shadow-sm);
    padding-top: 30px;
    padding-bottom: 10px;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 90px;
    transition: all 0.4s ease;
    gap: 20px; /* 要素間の隙間を確保 */
}

header.scrolled .header-inner {
    height: 70px;
}

.logo-text {
    font-family: var(--font-serif);
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--primary);
    letter-spacing: 0.1em;
    white-space: nowrap;
    flex-shrink: 0; /* ロゴが潰れないように */
}

@media (max-width: 1400px) {
    .logo-text {
        font-size: 1.4rem; /* 1400px以下で早めに小さくする */
    }
}

.nav-desktop {
    display: block; /* PC版では常に表示 */
}

.nav-desktop ul {
    display: flex;
    gap: 20px;
    margin: 0;
}

@media (min-width: 1025px) {
    .nav-desktop {
        display: block;
        margin: 0 auto; /* 中央に配置 */
    }
    
    .nav-desktop ul {
        display: flex;
        gap: 1.2vw; /* さらに間隔をタイトに */
        padding: 0;
    }
}

@media (max-width: 1300px) {
    .nav-desktop a {
        font-size: 0.9rem;
        letter-spacing: 0.1em; /* 少し間隔を空ける */
    }
}

.nav-desktop a {
    font-weight: 500;
    font-size: 1.05rem;
    color: var(--text);
    position: relative;
    padding: 5px 0;
    letter-spacing: 0.15em; /* 末広がりのバランスにするため文字間隔を拡大 */
    transition: var(--transition);
}

.nav-desktop a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

.nav-desktop a:hover::after {
    width: 100%;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-shrink: 0; /* 縮みすぎないように */
}

@media (max-width: 1200px) {
    .header-info {
        display: none; /* 1200px以下では電話番号を非表示にしてスペース確保 */
    }
}

.header-info {
    text-align: right;
    line-height: 1.2;
}

.opening-hours {
    display: block;
    font-size: 0.75rem;
    color: var(--text-light);
    margin-bottom: 4px;
}

.header-tel {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary);
}

.btn-reservation {
    background: var(--primary);
    color: var(--white);
    padding: 12px 28px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition);
}

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

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.45);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: var(--white);
}

.hero-logo-title {
    font-family: var(--font-serif);
    font-size: clamp(3rem, 10vw, 6rem);
    font-weight: 700;
    letter-spacing: 0.2em;
    margin-bottom: 20px;
    animation: fadeInDown 1.5s ease-out;
}

.hero-cta {
    position: absolute;
    bottom: 160px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    width: 100%;
    text-align: center;
    animation: fadeInUp 1.5s ease-out 0.5s both;
}

.hero-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background: var(--accent);
    color: var(--white);
    padding: 20px 48px;
    border-radius: 60px;
    font-weight: 700;
    font-size: 1.25rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    border: 2px solid var(--accent);
}

.hero-cta-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.hero-cta-btn i {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.hero-cta-btn:hover i {
    transform: scale(1.2);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translate(-50%, 30px);
    }

    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.hero-scroll {
    position: absolute;
    bottom: 30px;
    /* Force to bottom of hero section */
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.9;
    color: var(--white);
    z-index: 5;
}

.scroll-text {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.3em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.scroll-bar {
    width: 2px;
    height: 60px;
    background: linear-gradient(to bottom, var(--white), transparent);
    animation: scrollLine 2s infinite;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

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

@keyframes scrollLine {
    0% {
        transform: scaleY(0);
        transform-origin: top;
    }

    50% {
        transform: scaleY(1);
        transform-origin: top;
    }

    51% {
        transform: scaleY(1);
        transform-origin: bottom;
    }

    100% {
        transform: scaleY(0);
        transform-origin: bottom;
    }
}

/* Sections */
.section {
    padding: 80px 0;
    scroll-margin-top: 20px; /* 位置を「上目」にするために余白を最小限に */
}

.bg-light {
    background-color: var(--bg-light);
}

.section-header {
    margin-bottom: 60px;
}

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

.sub-title {
    display: block;
    color: var(--accent);
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.section-title {
    font-size: 2.5rem;
    color: var(--primary);
    position: relative;
    padding-bottom: 20px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--accent);
}

.align-center .section-title::after {
    left: 50%;
    transform: translateX(-50%);
}

/* About Section (Director) */
.section-about {
    background: var(--white);
    padding: 100px 0;
}

.about-flex {
    display: flex;
    align-items: flex-start;
    gap: 80px;
    margin-top: 40px;
}

.about-image {
    flex: 0 0 450px; /* 写真の幅をしっかり固定 */
    max-width: 100%;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 30px;
    box-shadow: var(--shadow-lg);
    display: block !important; /* 確実に表示させる */
    opacity: 1 !important;
    visibility: visible !important;
    object-fit: cover;
}

.about-content {
    flex: 1;
}

@media (max-width: 1024px) {
    .about-flex {
        flex-direction: column;
        gap: 40px;
        align-items: center;
    }
    .about-image {
        flex: none;
        width: 100%;
        max-width: 500px;
    }
}

/* Intro Grid */
.intro-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.intro-card {
    background: var(--white);
    padding: 60px 40px;
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    text-align: center;
    transition: var(--transition);
}

.card-icon {
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 30px;
}

/* About Section */
.about-flex {
    display: flex;
    align-items: center;
    gap: 80px;
}

.about-image {
    flex: 1;
}

.image-frame {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.about-content {
    flex: 1.2;
}

.history-list li {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-item {
    background: var(--white);
    border-radius: 20px;
    padding: 50px 30px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.service-image {
    font-size: 3rem;
    color: var(--accent);
    margin-bottom: 30px;
}

/* Guide Section */
.guide-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.step-item {
    background: var(--white);
    padding: 30px;
    border-radius: 20px;
    position: relative;
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.step-num {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: var(--accent);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
}

.step-item h3 {
    margin-top: 15px;
    margin-bottom: 15px;
    color: var(--primary);
}

/* Prices Section */
.price-container {
    display: flex;
    justify-content: center;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
}

.price-card {
    flex: 1;
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(0,0,0,0.05);
}

.price-card.popular {
    transform: scale(1.05);
    border: 2px solid var(--accent);
}

.price-header {
    background: var(--primary);
    color: var(--white);
    padding: 20px;
    text-align: center;
}

.price-card.popular .price-header {
    background: var(--accent);
}

.recommend {
    background: var(--white);
    color: var(--accent);
    display: inline-block;
    padding: 2px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-top: 10px;
}

.price-body {
    padding: 40px 30px;
    text-align: center;
}

.price-val {
    margin-bottom: 20px;
}

.price-val .amount {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--primary);
}

.price-val .currency, .price-val .tax {
    font-size: 1.2rem;
    font-weight: 700;
}

.price-old {
    text-decoration: line-through;
    color: var(--text-light);
    margin-bottom: 10px;
}

.price-val.special .amount {
    color: #e74c3c;
}

.price-features {
    text-align: left;
    margin-top: 30px;
}

.price-features li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.price-features i {
    color: var(--accent);
}

/* Cases Section */
.cases-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.case-card {
    background: var(--white);
    border-radius: 20px;
    padding: 30px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.case-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.case-label {
    display: inline-block;
    padding: 2px 12px;
    background: rgba(198, 163, 107, 0.1);
    color: var(--accent);
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 15px;
}

.case-info h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--primary);
}

.case-body p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 10px;
}

.section-reservation {
    background-color: var(--bg-light);
    scroll-margin-top: 100px; /* スクロール時にさらに上に表示 */
    padding: 20px 0 !important; /* 上下余白を最小限に */
    min-height: 70vh;
    display: flex;
    align-items: center;
}

.section-reservation .container {
    width: 100%;
}

.section-reservation .section-title {
    font-size: 1.8rem;
    margin-bottom: 5px;
}

.section-reservation .section-header {
    margin-bottom: 20px; /* タイトル下の余白を最小限に */
}

.reservation-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* PCでは4列横並び */
    gap: 15px;
    max-width: 1140px;
    margin: 0 auto;
}

.reservation-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px; /* 究極にコンパクトなパディング */
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    border: 1px solid rgba(0,0,0,0.05);
}

.reservation-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--accent);
}

.res-icon {
    width: 50px; /* 少しだけ大きく */
    height: 50px;
    background: var(--bg-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
    transition: var(--transition);
}

.reservation-card.tel .res-icon { color: var(--primary); background: rgba(13, 33, 25, 0.05); }
.reservation-card.line .res-icon { color: #06C755; background: rgba(6, 199, 85, 0.05); }
.reservation-card.hotpepper .res-icon { color: #FF4D4D; background: rgba(255, 77, 77, 0.05); }
.reservation-card.web .res-icon { color: var(--accent); background: rgba(198, 163, 107, 0.05); }

.reservation-card:hover .res-icon {
    transform: scale(1.1);
}

.reservation-card.tel h3 { color: var(--primary); }
.reservation-card.line h3 { color: #06C755; } /* LINEの文字を緑に */
.reservation-card.hotpepper h3 { color: #FF4D4D; } /* ホットペッパーの文字を赤に */
.reservation-card.web h3 { color: var(--accent); }

.res-content h3 {
    font-size: 1.6rem; /* さらに大きく！ */
    font-weight: 800; /* より太く！ */
    margin-bottom: 2px;
}

.res-number {
    font-size: 1.3rem; /* 番号をさらに小さく */
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0;
}

.res-text {
    font-size: 1.25rem; /* さらに大きく！ */
    font-weight: 700;
    margin-bottom: 0;
}

.res-note {
    font-size: 0.8rem;
    color: var(--text-light);
}

/* Access Section */
.access-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
}

.info-block {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
}

.phone-link {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
}

.access-map {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

#access {
    margin-bottom: 250px; /* ページ最下部でもマップを中央まで引き上げるため */
}

/* Footer */
footer {
    background-color: #0d2119;
    color: var(--white);
    padding: 80px 0 40px;
}

.footer-top {
    display: flex;
    justify-content: space-between;
    padding-bottom: 60px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 40px;
}

.footer-brand .logo-text {
    color: var(--white);
    display: block;
    margin-bottom: 15px;
    font-size: 2.2rem;
}

.footer-addr {
    font-size: 0.95rem;
    opacity: 0.8;
}

.footer-nav ul {
    display: flex;
    gap: 30px;
}

.footer-bottom {
    text-align: center;
    font-size: 0.9rem;
    opacity: 0.6;
}

/* Mobile Toggle */
.menu-toggle {
    display: none; /* デフォルトは非表示 */
}

/* Mobile Optimization */
@media (max-width: 1024px) {
    .container-fluid {
        padding: 0 20px;
    }

    .header-inner {
        height: 70px;
    }

    .nav-desktop {
        display: none;
    }

    .nav-desktop.active {
        display: flex !important;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: linear-gradient(rgba(13, 33, 25, 0.9), rgba(13, 33, 25, 0.9)), url('treatment_bg.png') no-repeat center center / cover;
        z-index: 1000;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 40px;
        animation: fadeIn 0.3s ease;
    }

    .nav-desktop.active ul {
        flex-direction: column;
        align-items: center;
        gap: 40px;
    }

    .nav-desktop.active a {
        font-size: 1.8rem;
        font-weight: 700;
        color: var(--white);
        font-family: var(--font-serif);
        letter-spacing: 0.1em;
    }

    .header-right {
        display: none;
    }

    .menu-toggle {
        display: flex;
        flex-direction: column;
        gap: 6px;
        background: none;
        border: none;
        cursor: pointer;
        z-index: 1001;
        position: relative; /* absoluteから変更 */
        /* top, rightを削除 */
    }

    .menu-toggle span {
        width: 30px;
        height: 2px;
        background: var(--primary);
        transition: var(--transition);
    }

    .menu-toggle[aria-expanded="true"] span {
        background: var(--white);
    }

    .menu-toggle[aria-expanded="true"] span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .menu-toggle[aria-expanded="true"] span:nth-child(2) {
        opacity: 0;
    }

    .menu-toggle[aria-expanded="true"] span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    @keyframes fadeIn {
        from { opacity: 0; }
        to { opacity: 1; }
    }

    .logo-text {
        font-size: 1.5rem; /* 少し小さくして安全に */
        position: relative;
        left: auto;
        top: auto;
        transform: none;
        width: auto;
        text-align: left;
    }

    .hero-logo-title {
        display: none;
    }

    .section {
        padding: 80px 0;
    }

    .intro-grid,
    .services-grid,
    .access-grid {
        grid-template-columns: 1fr;
    }

    .about-flex {
        flex-direction: column;
        gap: 40px;
    }

    .footer-top {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }

    .footer-nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px 15px;
    }

    .footer-nav a {
        font-size: 0.85rem;
        white-space: nowrap;
    }

    /* New Sections Mobile */
    .guide-steps, .cases-grid {
        grid-template-columns: 1fr;
    }

    .price-container {
        flex-direction: column;
        align-items: center;
    }

    .price-card.popular {
        transform: scale(1);
    }

    /* Reservation Mobile Optimized: 2Columns */
    .reservation-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .reservation-card {
        padding: 12px 8px;
        flex-direction: column;
        text-align: center;
        gap: 8px;
        border-radius: 10px;
    }

    .res-icon {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .res-content h3 {
        font-size: 0.85rem;
        margin-bottom: 2px;
    }

    .res-number {
        font-size: 0.9rem;
    }

    .res-text {
        font-size: 0.8rem;
    }

    .res-note {
        display: none;
    }
}