/* ==========================================================================
   全体設定
   ========================================================================== */
:root {
    --main-color: #f0f0d8;
    --purple: #C04890;
    --blue: #00A8C0;
    --orange: #F07800;
    --green: #A8D800;
    --black: #585048;
    --white: #FFF;
}

html {
    color: var(--black);
    font-size: 1em;
    line-height: 1.8;
    font-family: "a-otf-ud-shin-maru-go-pr6n", sans-serif;
    font-weight: 400;
    font-style: normal;
    scroll-behavior: smooth;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    width: 100%;
    height: auto;
}

.h2 {
    font-size: clamp(2.5rem, 2.057rem + 1.8vw, 3.5rem);
    line-height: 1.4;
    position: relative;
}

main {
    margin-top: clamp(3.75rem, 2.196rem + 6.63vw, 7.5rem);
}

header {
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    background-color: var(--main-color);
    z-index: 999;
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
}

header nav ul {
    display: flex;
    gap: 30px;
    list-style: none;
    padding: 0;
    margin: 0;
    background-color: var(--main-color);
}

header nav ul li a {
    text-decoration: none;
    color: inherit;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

nav ul li {
    position: relative;
}

nav ul li a {
    display: block;
    padding: 0.3rem 1rem;
    color: var(--black);
    text-decoration: none;
    transition: color 0.3s ease;
}

nav ul li a:hover,
nav ul li a:focus,
nav ul li a:active {
    color: var(--purple);
}

nav ul li ul {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1000;
}

nav ul li:hover>ul {
    display: block;
}

nav ul li ul li {
    white-space: nowrap;
}

nav ul li ul li a:hover {
    color: var(--blue);
}

/* 腫瘍センター */
header nav ul li a.nav-tumor-center:hover {
    color: var(--purple);
}

header nav ul li a.nav-tumor-center:active {
    color: var(--green);
}

/* お知らせ */
header nav ul li a.nav-news:hover {
    color: var(--blue);
}

header nav ul li a.nav-news:active {
    color: var(--orange);
}

/* 患者さんへ */
header nav ul li a.nav-patient:hover {
    color: var(--purple);
}

header nav ul li a.nav-patient:active {
    color: var(--orange);
}

/* お役立ち情報 */
header nav ul li a.nav-info:hover {
    color: var(--green);
}

header nav ul li a.nav-info:active {
    color: var(--purple);
}

.footer {
    margin-top: clamp(3.75rem, 2.196rem + 6.63vw, 7.5rem);
    background-color: var(--black);
    padding: clamp(1.75rem, 1.595rem + 0.66vw, 2.125rem) 0 clamp(8.875rem, 14.886rem - 7.51vw, 4.625rem) 0;
    color: var(--main-color);
    position: relative;
}

.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 10px 15px;
    border-radius: 5px;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: none;
    z-index: 998;
}

.back-to-top--visible {
    display: block;
    opacity: 1;
}

.back-to-top a {
    color: #fff;
    text-decoration: none;
}

.back-to-top a:hover {
    text-decoration: underline;
}

a {
    color: inherit;
}

.cooperative-inner {
    & img {
        width: clamp(27.875rem, 12.751rem + 64.53vw, 64.375rem);
        height: auto;
        margin: 0 auto;
        display: block;
    }
}

/* ==========================================================================
   3カラム折り返しリスト用スタイル
   ========================================================================== */
.facility-list {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 0;
    margin: 0;
    list-style: none;
    justify-content: center;
    align-items: flex-start;
}

.facility-list li {
    flex: 1 1 calc(25% - 20px);
    background-color: #fff;
    border-radius: 12px;
    text-align: center;
    overflow: hidden;
    box-shadow: 0 0 0 1px #ccc;
}

.facility-list .item-head {
    background-color: #4d443c;
    color: #fff;
    padding: 0.5em;
    font-weight: bold;
}

.facility-list .item-body {
    padding: 1em;
    color: #333;
    font-size: 1.1em;
}

.facility-list li.col-span-2 {
    flex: 1 1 calc(50% - 20px);
}

/* ==========================================================================
   テーブル
   ========================================================================== */

.table-scroll {
    overflow-x: auto;
    width: 100%;
}

.data-table {
    border-collapse: separate;
    border-spacing: 10px;
    width: 100%;
}

.data-table th,
.data-table td {
    text-align: center;
    padding: 1rem;
    border-radius: 12px;
    background-color: #fff;
    font-weight: normal;
    white-space: nowrap;
}

.data-table .main-title {
    background-color: #a5e331;
    color: #8e3e90;
    font-weight: bold;
    font-size: 1.2rem;
}

.data-table thead th:not(.main-title) {
    background-color: #4d443c;
    color: #fff;
    font-weight: bold;
}

.data-table .row-label {
    background-color: #4d443c;
    color: #fff;
    font-weight: bold;
    text-align: left;
}

/* ==========================================================================
   ブログ用スタイル
   ========================================================================== */

.article {
    border-radius: 5px;
    margin-bottom: 1rem;
    padding: 1rem;
    transition: box-shadow 0.3s;
    width: 100%;
    box-sizing: border-box;
    overflow-wrap: break-word;
}

.article:hover {
    box-shadow: 0 4px 8px color-mix(in srgb, black 10%, transparent);
}

.article-title {
    margin: 0;
    font-size: 1.25rem;
    cursor: pointer;
    font-weight: 400;
}

.article-title.hover-green:hover {
    color: var(--green);
}

.article-title.hover-orange:hover {
    color: var(--orange);
}

.article-title.hover-blue:hover {
    color: var(--blue);
}

.article-title.hover-black:hover {
    color: var(--black);
}

.article-title.hover-purple:hover {
    color: var(--purple);
}

.article-content {
    background-color: #fff;
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 5px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    display: none;
}

.article-content p {
    margin: 0;
}

.article-date {
    font-size: 0.875rem;
    margin: 0.5rem 0;
}

.article-content img {
    max-width: 100%;
    height: auto;
    display: block;
}

.loading {
    text-align: center;
    padding: 2rem;
    color: #666;
}

.figure {
    width: 100%;

    & img {
        width: 100%;
        height: auto;
    }
}

.error {
    background-color: #fff3f3;
    border: 1px solid #ff8080;
    border-radius: 5px;
    padding: 1rem;
    margin: 1rem 0;
    color: #d32f2f;
}

.error button {
    background-color: #d32f2f;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 0.5rem;
}

.error button:hover {
    background-color: #b71c1c;
}

.expandable-text {
    font-size: clamp(1rem, 0.767rem + 0.99vw, 1.563rem);
    max-height: 7em;
    overflow: hidden;
    position: relative;
    transition: max-height 0.4s ease;
}

.expandable-text.expanded {
    max-height: 100em;
}

.expandable-text p {
    margin: 0;
}

#pagination {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

#pagination a {
    text-decoration: none;
    width: fit-content;
    border-radius: 5px;
    margin-bottom: 1rem;
    padding: .5rem 1rem;
    transition: box-shadow 0.3s;
    box-sizing: border-box;
    overflow-wrap: break-word;
}

#pagination a:hover {
    background-color: #f28c38;
    color: #fff;
    text-decoration: none;
}

#pagination a.current-page {
    background-color: #f28c38;
    color: #fff;
    padding: .5rem 1rem;
    font-weight: bold;
    pointer-events: none;
}

.outline-orange {
    border: 1px solid #f28c38;
    color: #fff;
    border-radius: 5px;
    text-decoration: none;
}

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

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

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

.accordion-toggle {
    cursor: pointer;
}

.accordion-toggle:hover {
    color: var(--purple);
}

/* ==========================================================================
   ul（リスト）の汎用スタイル
   ========================================================================== */

.default-list {
    list-style-type: disc;
    padding-left: 1em;
    margin: 0;
}

.no-marker {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.numbered-list {
    list-style-type: decimal;
    padding-left: 1.5em;
    margin: 0;
}

/* ==========================================================================
   マップモーダル
   ========================================================================== */
#modalMap {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.7);
    align-items: center;
    justify-content: center;
}

#modalMapClose {
    position: absolute;
    top: 20px;
    right: 40px;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
}

#modalMapImg {
    max-width: 90vw;
    max-height: 90vh;
    margin: auto;
    display: block;
}

.modal-fade {
    opacity: 0;
    pointer-events: none;
}

.modal-fade.active {
    display: flex !important;
    opacity: 1;
    pointer-events: auto;
    transition: opacity 0.3s;
}

/* ==========================================================================
   インデント
   ========================================================================== */
.indent {
    display: inline-block;
    width: 1em;
}


/* ==========================================================================
   大型ディスプレイ（1440px以上）
   ========================================================================== */
@media (min-width: 1440px) {
    body {
        background-color: var(--main-color);
        margin: 0;
    }

    .container {
        max-width: 1320px;
        margin: 0 auto;
        position: relative;
    }

    section {
        position: relative;
        padding: clamp(3.75rem, 2.196rem + 6.63vw, 7.5rem) 0;
    }

    .about-title::after {
        position: absolute;
        content: "";
        background-image: url("../img/about-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 100%;
        left: 0;
        transform: translateY(0);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .greeting-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/greeting-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;

    }

    .news-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/news-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .patient-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/patient-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .info-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/info-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .animation {
        margin-top: -120px;
        overflow-x: hidden;
    }

    .animation-inner {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100vh;
        gap: 20px;
        max-width: 100%;
        overflow-x: hidden;
        flex-wrap: wrap;
        justify-content: center;
        box-sizing: border-box;
    }

    .object {
        width: 15vw;
        height: 15vw;
        border-radius: 50%;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .purple {
        background-color: var(--purple);
    }

    .blue {
        background-color: var(--blue);
    }

    .orange {
        background-color: var(--orange);
    }

    .green {
        background-color: var(--green);
    }

    .object span {
        font-size: 4em;
        font-weight: 400;
        color: white;
        pointer-events: none;
    }

    .sp-header {
        display: none;
    }

    #cancerboard,
    #consultation,
    #surgery,
    #chemotherapy,
    #radiation-therapy,
    #palliative-care,
    #genome-testing,
    #medical-achievements,
    #second-opinion,
    #cancer-information-service,
    #procedure {
        padding-top: 150px;
        margin-top: -150px;
    }
}

/* ==========================================================================
   デスクトップ（1280px以上）
   ========================================================================== */
@media (max-width: 1439px) {
    body {
        background-color: var(--main-color);
        margin: 0;
    }

    .container {
        max-width: 1200px;
        margin: 0 auto;
        position: relative;
        padding: 0 clamp(1.25rem, 0.179rem + 5.36vw, 5rem);
    }

    section {
        position: relative;
        padding: clamp(3.75rem, 2.196rem + 6.63vw, 7.5rem) 0;
    }

    .about-title::after {
        position: absolute;
        content: "";
        background-image: url("../img/about-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 100%;
        left: 0;
        transform: translateY(0);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .greeting-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/greeting-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;

    }

    .news-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/news-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .patient-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/patient-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .info-title::before {
        position: absolute;
        content: "";
        background-image: url("../img/info-object.svg");
        background-repeat: no-repeat;
        background-size: contain;
        top: 50%;
        right: 0;
        transform: translateY(-50%);
        width: clamp(0rem, -11.395rem + 48.62vw, 27.5rem);
        height: clamp(0rem, -7.096rem + 30.28vw, 17.125rem);
        pointer-events: none;
        z-index: -1;
    }

    .animation {
        margin-top: -120px;
        overflow-x: hidden;
    }

    .animation-inner {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 100vh;
        gap: 20px;
    }

    .object {
        width: 15vw;
        height: 15vw;
        border-radius: 50%;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .purple {
        background-color: var(--purple);
    }

    .blue {
        background-color: var(--blue);
    }

    .orange {
        background-color: var(--orange);
    }

    .green {
        background-color: var(--green);
    }

    .object span {
        font-size: 4em;
        font-weight: bold;
        color: white;
        pointer-events: none;
    }

    .sp-header {
        display: none;
    }

    #cancerboard,
    #consultation,
    #surgery,
    #chemotherapy,
    #radiation-therapy,
    #palliative-care,
    #genome-testing,
    #medical-achievements,
    #second-opinion,
    #cancer-information-service,
    #procedure {
        padding-top: 150px;
        margin-top: -150px;
    }
}

/* ==========================================================================
   タブレット横向き・小型ノートPC（1024px以上）
   ========================================================================== */
@media (max-width: 1024px) {
    .container {
        max-width: 960px;
        margin: 0 auto;
        position: relative;
    }

    header nav {
        padding: 0;
    }

    nav ul li a {
        padding: 0;
    }
}

/* ==========================================================================
   タブレット縦向き（768px以上）
   ========================================================================== */
@media (max-width: 768px) {
    .container {
        max-width: 720px;
        margin: 0 auto;
        position: relative;
    }

    .header-nav {
        display: none;
    }

    .sp-header {
        display: block;
    }

    .flex-column-s {
        flex-direction: column;
    }

    .sp-nav {
        width: 100%;
        position: fixed;
        z-index: 999;
        padding: 0 clamp(1.25rem, 0.179rem + 5.36vw, 5rem);
        bottom: 0;
        box-sizing: border-box;
    }

    .sp-header-inner {
        height: 100vh;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .sp-nav ul {
        list-style: none;
    }

    .back-to-top {
        bottom: 100px;
        right: 10px;

    }

    .facility-list li {
        flex: 1 1 100%;
        /* スマホ：1列 */
    }

    section {
        margin: clamp(3.75rem, 2.196rem + 6.63vw, 7.5rem) 0;
    }

    .cooperative-inner img {
        width: 100%;
        display: block;
        margin: 0 auto;
    }

    .animation {
        display: none;
    }

    .about-title::after {
        display: none;
    }

    .greeting-title::before {
        display: none;
    }

    .news-title::before {
        display: none;
    }

    .patient-title::before {
        display: none;
    }

    .info-title::before {
        display: none;
    }
}

/* ==========================================================================
   小型スマートフォン横向き・大型スマートフォン縦向き（480px以上）
   ========================================================================== */
@media (max-width: 480px) {

    .container {
        padding: 0 20px;
    }
}