@import "https://cdn.jsdelivr.net/npm/yakuhanjp@4.1.1/dist/css/yakuhanjp.css";
@import url("https://fonts.googleapis.com/css2?family=Roboto+Condensed:ital,wght@0,100..900;1,100..900&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@100;300;400;500;700&display=swap");

/* =========================
       ルート変数
    ========================= */
:root {
    --color-primary: #44AF35;
    --color-primary-dark: #258a18;
    --color-primary-light: #d8f3d4;
    --color-accent: #ffd900;
    --color-orange: #f48300;
    --color-red: #d43f3a;
    --color-bg: #D8E0E1;
    --color-text: #333;
    --color-teal: #0da4af;
    --color-blue: #0330ac;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 2rem;
    --space-xlg: 3.5rem;

    --kokugo: #ed8599;
    --sugaku: #757cbb;
    --syakai: #f6ae54;
    --rika: #65a9dc;
    --eigo: #A2D13A;
}

/* =========================
       基本スタイル
    ========================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: YakuHanJP, Roboto, "Noto Sans JP", sans-serif;
    color: var(--color-text);
    background: #fff;
    line-height: 1.6;
}

.contents-inner {
    margin: 0 auto;
    width: 1040px;
    padding: 0 20px;
    display: block;
    clear: both;
    position: relative;
}

.attention {
    color: var(--color-red);
}

.highlight {
    background-image: linear-gradient(to bottom, transparent 55%, var(--color-accent) 55%);
}

a.link_df {
    cursor: pointer;
    --tw-text-opacity: 1;
    color: rgb(59 130 246 / var(--tw-text-opacity, 1));
    text-decoration-line: underline;
}

@media screen and (max-width: 1060px) {
    .contents-inner {
        width: 100%;
        box-sizing: border-box;
        -webkit-box-sizing: border-box;
        -moz-box-sizing: border-box;
        -ms-box-sizing: border-box;
        -o-box-sizing: border-box;
        float: none;
        clear: both;
        display: block;
        margin: 0;
        padding: 0 20px;
    }
}

/* =========================
       ヘッダー・ナビゲーション
    ========================= */

.header {
    background: rgba(255, 255, 255, 0.90);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header__container {
    display: grid;
    grid-template-columns: 180px 1fr 100px;
    grid-template-rows: repeat(2, 50px);
    grid-column-gap: 1rem;
    grid-row-gap: 0px;
    /*align-items: center;*/
}

.header__logo {
    grid-area: 1 / 1 / 3 / 2;
}

.header__top {
    grid-area: 1 / 2 / 2 / 3;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 1rem 0;
}

.header__main {
    grid-area: 2 / 2 / 3 / 3;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0;
}

.header__main .h-btn {
    display: none;
}

.header__contact {
    grid-area: 1 / 3 / 3 / 4;
}

.header__contact a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 100%;
    width: 100%;
    color: white;
    font-size: 80%;
    text-decoration: none;
    font-weight: 500;
    background: var(--color-primary);
}

.header__contact a:hover {
    color: var(--color-accent);
}

.header__contact img {
    display: block;
    width: 50px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    height: 100%;
    width: 100%;
}

.logo img {
    width: 150px;
}

.header__actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.header__actions a {
    color: var(--color-text);
    text-decoration: none;
    font-size: 90%;
}

.header__actions a:hover {
    color: var(--color-primary);
}

.header__actions a:first-child::after {
    content: "|";
    margin-left: 1rem;
}

.search-box {
    display: flex;
    align-items: center;
    background: var(--color-bg);
    border-radius: 50px;
    padding: 0.5rem 1rem;
    min-width: 300px;
}

.search-box input {
    border: none;
    background: none;
    outline: none;
    flex: 1;
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
}

.search-box button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--color-text);
    transition: color 0.3s;
}

.search-box button:hover {
    color: var(--color-primary);
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1000;
}

.hamburger__line {
    width: 25px;
    height: 3px;
    background: var(--color-primary);
    transition: all 0.3s;
    border-radius: 2px;
}

.hamburger.active .hamburger__line {
    background: var(--color-primary);
}

.hamburger.active .hamburger__line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger.active .hamburger__line:nth-child(2) {
    opacity: 0;
    transform: translateX(-10px);
}

.hamburger.active .hamburger__line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.nav {
    display: flex;
    gap: 0;
    align-items: center;
}

.nav__item {
    position: relative;
}

.nav__link {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 500;
    padding: 1rem;
    display: block;
    transition: color 0.3s;
}

.nav__link:hover {
    color: var(--color-primary-dark);
}

.nav__dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: #FFF;
    min-width: 260px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s;
    padding: 1rem 0;
}

.nav__item:hover .nav__dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav__dropdown a {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--color-text);
    text-decoration: none;
    transition: all 0.3s;
    font-size: 0.9rem;
}

.nav__dropdown a:hover {
    background: var(--color-bg);
    color: var(--color-primary);
    padding-left: 1.25rem;
}

.h-btn {
    padding: 0.75rem 2rem;
    background: var(--color-primary);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s;
    font-weight: 600;
    position: relative;
    overflow: hidden;
}

.h-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-accent) 100%);
    transition: left 0.3s;
}

.h-btn:hover::before {
    left: 0;
}

.h-btn span {
    position: relative;
    z-index: 1;
}

/* =========================
       ヒーローセクション
    ========================= */
.top-hero {
    /*display: flex;*/
    align-items: center;
    justify-content: space-between;
    padding: 0;
    position: relative;
    background-image: url(/assets/img/opacity.png);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    overflow: hidden;
}

.top-hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("/assets/img/slide_bg.jpg");
    filter: grayscale(100%);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0.7;
    /* 透明度を調整 */
    z-index: -1;
}


.top-hero__content {
    max-width: 610px;
    padding-right: var(--space-lg);
    position: absolute;
    top: var(--space-lg);
    left: 0;
    z-index: 1;
}


.top-hero__title {
    font-size: 2.25rem;
    margin-bottom: var(--space-lg);
    color: var(--color-primary);
    line-height: 1.3;
    letter-spacing: 0.3rem;
    /*text-shadow: 1px 1px 0 #FFF, -1px -1px 0 #FFF,
        -1px 1px 0 #FFF, 1px -1px 0 #FFF,
        0px 1px 0 #FFF, 0-1px 0 #FFF,
        -1px 0 0 #FFF, 1px 0 0 #FFF;*/
}

.top-hero__desc {
    color: var(--color-text);
    font-size: 0.95rem;
    font-weight: 500;
    margin-top: var(--space-md);
    letter-spacing: 0.175rem;
    /*text-shadow: 1px 1px 0 #FFF, -1px -1px 0 #FFF,
        -1px 1px 0 #FFF, 1px -1px 0 #FFF,
        0px 1px 0 #FFF, 0 -1px 0 #FFF,
        -1px 0 0 #FFF, 1px 0 0 #FFF;*/
}

.top-hero__buttons {
    display: flex;
    gap: var(--space-md);
    flex-wrap: wrap;
    margin-top: var(--space-lg);
}

.top-hero__img {
    position: relative;
    width: auto;
    height: 520px;
    text-align: right;
    z-index: 0;
}

/*.top-hero__img:before {
    content: '';
    display: block;
    background: url(/assets/img/dot_green.png);
    background-size: 2px 2px;
    width: 780px;
    height: 100%;
    position: absolute;
    top: 0;
    right: -188px;
    z-index: 2;
}*/

.top-hero__img img {
    position: absolute;
    width: auto;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    right: -180px;
    transition: opacity 1.5s ease;
    filter: sepia(0.15) brightness(1.05)
}

.top-hero__img img.is-active {
    opacity: 1;
    z-index: 1;
}

/* =========================
       ボタン
    ========================= */
.btn_df,
.btn_top {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 2rem;
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: 100vh;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 1.125rem;
    overflow: hidden;
    margin-top: 1rem;
}

.btn_top {
    font-size: 0.9rem;
    padding: 0.475rem 2rem;
    margin-top: 0;
}

.btn_df_sm {
    background-color: var(--color-primary);
    font-weight: normal;
    padding: 0.25rem 1rem;
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    margin: 0 1rem;
    border-radius: 100vh;
}


.btn_df::before,
.btn_top::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
    border-radius: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.btn_df:hover::before,
.btn_top:hover::before {
    animation: shine 0.6s ease-out;
}

@keyframes shine {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }

    100% {
        width: 400px;
        height: 400px;
        opacity: 0;
    }
}

.btn_df__arrow,
.btn_top__arrow {
    transition: transform 0.3s;
}

.btn_df:hover .btn_df__arrow,
.btn_df_sm:hover .btn_df__arrow,
.btn_top:hover .btn_top__arrow {
    transform: translateX(4px);
}

/* =========================
       教材検索セクション
    ========================= */
.top-search {
    background: url(/assets/img/booksearch_bg.jpg);
    padding: var(--space-lg);
    background-size: cover;
    color: #fff;
    text-align: center;
}

.top-search__title {
    font-size: 2rem;
    margin-bottom: var(--space-lg);
    position: relative;
    color: #FFF;
    display: inline-block;
}

.top-search__title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--color-accent);
    margin: var(--space-sm) auto 0;
}

.top-search__input {
    display: flex;
    max-width: 500px;
    margin: 0 auto var(--space-lg);
    gap: 0;
}

.top-search__input input {
    flex: 1;
    padding: 0.75rem var(--space-md);
    border: none;
    border-radius: 4px 0 0 4px;
}

.top-search__input button {
    padding: 0.75rem var(--space-md);
    background: var(--color-primary);
    color: #fff;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    transition: background 0.3s;
}

.top-search__input button:hover {
    background: var(--color-primary-dark);
}

.top-search__categories {

    margin: var(--space-lg) auto 0;
}

.top-search__category {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: var(--space-lg);
    align-items: center;
    margin-bottom: var(--space-lg);
    /*padding-bottom: var(--space-lg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);*/
    justify-content: flex-start;
}

.top-search__category:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.top-search__category-label {
    font-size: 0.95rem;
    font-weight: bold;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.5rem var(--space-md);
    border-radius: 2px;
    text-align: center;
}

.top-search__category-label.es {
    background: #FFAD00;
}

.top-search__category-label.jh {
    background: #2EC4B6;
}

.top-search__category-label.hs {
    background: #3498DB;
}

.top-search__category-links {
    display: flex;
    gap: var(--space-md);
    flex-wrap: wrap;
}

.top-search__category-link {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 0.4rem 1rem;
    border-radius: 2px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    text-decoration: none;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s;
}

.top-search__category-link:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* =========================
       特集セクション
    ========================= */
.top-feature {
    padding: var(--space-lg);
    text-align: center;
    background: #fff;
}

.top-feature__title {
    font-size: 2rem;
    margin-bottom: var(--space-lg);
    position: relative;
    display: inline-block;
}

.top-feature__title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--color-accent);
    margin: var(--space-sm) auto 0;
}

.top-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-lg);
}

.top-card {
    background: var(--color-primary);
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s;
}

.top-card:hover {
    transform: translateY(-5px);
}

.top-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.top-card img:hover {
    opacity: 0.8;
    transition: 0.3s ease-in-out;
    -moz-transition: 0.3s ease-in-out;
    -webkit-transition: 0.3s ease-in-out;
    -ms-transition: 0.3s ease-in-out;
    -o-transition: 0.3s ease-in-out;
}

/* =========================
       関連サイトセクション
    ========================= */
.top-related {
    padding: var(--space-lg);
    text-align: center;
    background: #C4E0C4;
}

.top-related__grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: var(--space-md);
    align-items: stretch;
}

.top-related__title {
    display: inline-block;
    background: var(--color-primary);
    color: #fff;
    padding: 1rem 0.75rem;
    border-radius: 4px;
    position: relative;
    font-weight: 700;
    line-height: 1.5;
    font-size: 1.25rem;
}

.top-related__title::after {
    content: "";
    position: absolute;
    top: 50%;
    right: -10px;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 10px solid transparent;
    border-bottom: 10px solid transparent;
    border-left: 10px solid var(--color-primary);
}

.top-related__banner {
    position: relative;
    overflow: hidden;
    background-color: #FFF;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: var(--space-md) var(--space-sm);
    display: flex;
    align-items: center;
    justify-content: flex-start;
    transition: color 0.3s ease;
}

.top-related__banner::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-accent) 100%);
    transform: translateX(-100%);
    transition: transform 0.45s ease;
    z-index: 0;
}
.top-related__banner:nth-child(2) {
    border-left:8px solid #589239;
}
.top-related__banner:nth-child(3) {
    border-left:8px solid #009144;
}
.top-related__banner:nth-child(4) {
    border-left:8px solid #FE6567;
}
.top-related__banner:nth-child(5) {
    border-left:8px solid #168DC3;
}
.top-related__banner:nth-child(2):before {
    background: #589239;
}
.top-related__banner:nth-child(3):before {
    background: #009144;
}
.top-related__banner:nth-child(4):before {
    background: #FE6567;
}
.top-related__banner:nth-child(5):before {
    background: #168DC3;
}

.top-related__banner:hover::before {
    transform: translateX(0);
}

.top-related__banner a {
    position: relative;
    z-index: 1;
    text-decoration: none;
    color: var(--color-text);
    font-weight: 700;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}
.top-related__banner a span {
    font-size: 0.75rem;
    display: block;
    font-weight: 400;
}

.top-related__banner:hover a {
    color: #fff;
}

.top-related__banner::after {
    content: "";
    display: inline-block;
    width: 0;
    height: 0;
    margin-right: 5px;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 6px solid currentColor;
    transition: transform 0.2s ease;
    transform: translateX(0);
}

.top-related__banner:hover::after {
    transform: translateX(4px);
    color: #FFF;
}

/* 狭い画面では自動フィット（元の挙動）に戻す */
@media screen and (max-width: 1280px) {
    .top-related__grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    }
    .top-related__title::after {
        display: none;
    }
}

/* =========================
       3つの強みセクション
    ========================= */

.top-strength {
    background: url(/assets/img/strongpoint_bg.jpg);
    background-size: cover;
    padding: var(--space-lg);
    text-align: center;
}

.top-strength__title {
    font-size: 1.25rem;
    color: var(--color-primary);
    letter-spacing: 2px;
    display: flex;
    font-weight: 500;
    align-items: center;
    justify-content: center;
}

.top-strength__title::before,
.top-strength__title::after {
    content: '';
    display: block;
    width: 80px;
    height: 1px;
    background: var(--color-primary);
}

.top-strength__title::before {
    margin-right: 0.5em;
}

.top-strength__title::after {
    margin-left: 0.5em;
}

.top-strength__main {
    font-size: 2rem;
    margin-bottom: var(--space-lg);
    color: var(--color-text);
}

.top-strength__main span {
    font-size: 175%;
    color: var(--color-primary);
}

.top-strength__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: var(--space-lg);
    margin-top: var(--space-lg);
}

.top-strength__card {
    /*background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);*/
}

.top-strength__img {
    width: 100%;
    height: 250px;
    position: relative;
}

.top-strength__img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    animation: floaty 4s ease-in-out infinite;
}

.top-strength__card:nth-child(1) .top-strength__img img {
    animation-delay: 0s;
    clip-path: url('#wave1');
}

.top-strength__card:nth-child(2) .top-strength__img img {
    animation-delay: 0.8s;
    clip-path: url('#wave2');
}

.top-strength__card:nth-child(3) .top-strength__img img {
    animation-delay: 1.6s;
    clip-path: url('#wave3');
}

svg:not(:root) {
    overflow: hidden;
}

@keyframes floaty {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0);
    }
}

.top-strength__content {
    padding-top: var(--space-lg);
}

.top-strength__content h3 {
    background: var(--color-primary);
    color: #fff;
    padding: var(--space-sm);
    font-size: 1.25rem;
    font-weight: 400;
}

.top-strength__content p {
    color: var(--color-text);
    margin-top: var(--space-md);
    line-height: 1.6;
    text-align: left;
    font-size: 0.9rem;
}

/* =========================
       お知らせ・最新情報
    ========================= */
.top-news {
    padding: var(--space-lg);
    background: #fff;
}

.top-news__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-lg);
    flex-wrap: wrap;
    gap: var(--space-md);
    position: relative;
}

.top-news__wrap {
    padding-left: 4rem;
    background: url(/assets/img/top_news_icon.svg) no-repeat left center;
}

.news-exam .top-news__wrap {
    background: url(/assets/img/top_exam_icon.svg) no-repeat left center;
}

.top-news__wrap .top-news__title-s {
    color: var(--color-primary);
    font-weight: normal;
    font-size: 0.75rem;
}

.top-news__title {
    font-size: 1.5rem;
    color: var(--color-primary);
    font-weight: bold;
    letter-spacing: 0.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}


.top-news__title span {
    padding-right: var(--space-md);
    background-color: #FFF;
    z-index: 1;
}

.top-news__title::after {
    content: '';
    display: block;
    height: 1px;
    background: var(--color-primary);
    position: absolute;
    bottom: 32%;
    /* adjust this value to position the line correctly */
    left: 4rem;
    right: 0;
    z-index: 0;
}

.top-news .btn_top {
    margin-bottom: 25px;
}

.top-news__list {
    list-style: none;
    margin-left: 4rem;
}

.top-news__item {
    /*display: flex;
    gap: var(--space-md);*/
    margin-bottom: var(--space-md);
    font-size: 0.9rem;
    display: flex;
    align-items: flex-start;

}

.news-exam .top-news__item {
    display: block;

}

.top-news__item a {
    text-decoration: none;
    color: var(--color-text);
    transition: all 0.3s;
    display: inline-block;
    margin-right: 5px;
}

.top-news__item a:hover {
    transform: translateX(5px);
    color: var(--color-primary);
}

.top-news__cat {
    background: var(--color-primary);
    color: #fff;
    padding: 0.3rem 0.6rem;
    border-radius: 3px;
    font-size: 0.75rem;
    min-width: 82px;
    white-space: nowrap;
    display: inline-block;
    text-align: center;
    margin-right: var(--space-md);
}

.top-news__cat.cat-01 {
    background: var(--sugaku);
}

.top-news__cat.cat-02 {
    background: var(--color-teal);
}

.top-news__cat.cat-03 {
    background: var(--color-blue);
}

.top-news__cat.cat-04 {
    background: var(--color-primary-dark);
}

.top-news__cat.cat-05 {
    background: var(--color-primary)
}

.top-news__text {
    flex: 1;
}

/* =========================
       CTAセクション
    ========================= */
.f-contact {
    background-color: var(--color-bg);
    padding: var(--space-md) 0;
}

.f-contact .contents-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-lg);
    margin: var(--space-lg) auto;
    padding: 0 var(--space-md);
}

.f-contact__item {
    position: relative;
    height: 160px;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: #fff;
    letter-spacing: 0.225rem;
    text-decoration: none;
    transition: all 0.3s;
}

.f-contact__item--contact {
    background: url(/assets/img/f_contact.webp) no-repeat center center;
}

.f-contact__item--office {
    background: url(/assets/img/f_company.webp) no-repeat center center;
}

.f-contact__item:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

.f-contact__item>div {
    background-color: rgba(67, 175, 53, 0.85);
    width: 100%;
    text-align: center;
    padding: var(--space-lg) 0;
}

.f-contact__item h3 {
    font-size: 1.25rem;
    font-weight: 500;
    text-align: center;
}

.f-contact__item .btn_top {
    background: #fff;
    color: var(--color-primary);
}

.f-contact__item .btn_top:hover {
    background: #f0f0f0;
}

/* =========================
       フッター
    ========================= */
.footer {
    background: var(--color-primary);
    color: #fff;
    padding: var(--space-lg);
}

.footer__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-lg);
    margin-bottom: var(--space-lg);
}

.footer__section h4 {
    font-size: 1rem;
    margin-bottom: var(--space-md);
    border-bottom: 1px solid rgba(255, 255, 255, 0.4);
}

.footer__section ul {
    list-style: none;
}

.footer__section li {
    margin-bottom: var(--space-sm);
}

.footer__section a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.footer__section a:hover {
    color: #fff;
}

.footer__bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.4);
    padding-top: var(--space-md);
    text-align: center;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

.f-nav ul {
    text-align: center;
    margin-bottom: var(--space-md);
}

.f-nav ul li {
    display: inline-block;
    border-left: 1px solid rgba(255, 255, 255, 0.4);
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    -ms-box-sizing: border-box;
    -o-box-sizing: border-box;
    line-height: 1.2;
}

.f-nav ul li:last-child {
    border-right: 1px solid rgba(255, 255, 255, 0.4);
}

.f-nav ul li a {
    color: rgba(255, 255, 255, 0.8);
    padding: 0 8px 0 11px;
    box-sizing: border-box;
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    -ms-box-sizing: border-box;
    -o-box-sizing: border-box;
    text-decoration: none;
}

.f-nav ul li a:hover {
    color: #fff;
}


/* =========================
       下層ページ
    ========================= */

#main_contents .contents-inner {
    margin: 4rem auto;
}

.page_title {
    background: url(/assets/img/h1_default.jpg) no-repeat center / cover;
    height: 260px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.page_title::before {
    content: '';
    background-color: rgba(0, 0, 0, .7);
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
}

.page_title::after {
    background: url(/assets/img/bg_wave.png) repeat-x center bottom;
    position: absolute;
    content: '';

    right: 0;
    bottom: 0;
    left: 0;
    height: 10px;
}

.page_title .h1 {
    filter: brightness(1);
    width: 1100px;
    max-width: 100%;
    text-align: left;
    font-size: 2.75rem;
    font-weight: bold;
    margin: 0 auto;
    color: #fff;
}

.page_title .h1 span {
    display: block;
    font-size: 1.5rem;
    padding-top: 0.5em;
    color: #FFF;
    font-weight: normal;
}

#main_contents h3 {
    text-align: center;
    background: #8AC46B;
    color: #fff;
    border-radius: 4px;
    padding: 0.75rem 1em;
    position: relative;
    margin: 40px 0;
    font-size: 1.5rem;
}

#main_contents h4 {
    margin: 40px 0 20px;
    padding: 0 0 8px 25px;
    font-size: 1.25rem;
    position: relative;
    color: #231815;
    font-weight: bold;
    background: url(/assets/img/border_dot_green.svg) repeat-x bottom;
    background-size: auto 2px;
}

#main_contents h4::after {
    content: "";
    position: absolute;
    top: 0.4em;
    left: 0;
    display: block;
    width: 10px;
    height: 10px;
    margin: auto;
    border-radius: 50%;
    background-color: var(--color-primary);
    border: var(--color-primary) solid 2px;
}

.contact-phone {
    font-weight: 500;
    font-size: 1rem;
    margin-top: 1rem;
    display: inline-block;
    border: 2px solid var(--color-primary);
    background-color: var(--color-primary-light);
    padding: 0.5rem 1rem;
}

.contact-phone a {
    font-size: 1.25rem;
    margin-left: 0.5rem;
    color: var(--color-text);
    cursor: default;
}


/* =========================
      Table & Form
    ========================= */

table {
    margin: 0 auto;
    border-collapse: collapse;
    border-spacing: 0;
}

td,
th {
    padding: 0;
}

table td,
table th {
    padding: 0.7em 1em;
}

table th {
    text-align: center;
    font-weight: normal;
}

.table_df {
    width: 100%;
    margin: 2rem auto;
    border-collapse: collapse;
    border-spacing: 0;
}

.table_df input[type=text],
.table_df input[type=url],
.table_df input[type=email],
.table_df input[type=tel],
.table_df input[type=date],
.table_df input[type=number],
.table_df select,
.table_df textarea {
    width: 100%;
    max-width: 100%;
    padding: 7px 2%;
    color: #231815;
    margin: 0 0.2em;
    border: 1px solid #cccccc;
    background: #fafafa;
    border-radius: 3px;
    -webkit-appearance: none;
}

.table_df input[type=number] {
    width: 65px;
    text-align: center;
}

.table_df input.postal-code {
    width: 200px;
}

.table_df input.region {
    width: 100px;
}

.table_df input.locality {
    width: 150px;
}

.table_df input.address {
    width: 100%;
}

.table_df .tel-field {
    display: flex;
    justify-content: space-between;
}

.table_df .list-item {
    display: inline-block;
    margin: 0 0 0 1em;
}

.table_df .input_wrap input,
.table_df .input_wrap textarea {
    margin: 0;
}

.table_df .input_wrap input:focus,
.table_df .input_wrap textarea:focus {
    background: #fdf6cd;
    outline: 1px solid #cccccc;
    outline-offset: -1px;
}

.table_df .input_wrap:last-child {
    margin-right: auto;
}

.table_df .btn_submit {
    margin: 1em 0;
    text-align: center;
}

.form_button.btn_submit,
.form_button.btn_back {
    display: inline-block;
    max-width: 240px;
    width: 100%;
    margin: 1rem;
    padding: 1em 1em;
    border: var(--color-primary) solid 2px;
    border-radius: 40px;
    line-height: 1;
    background: var(--color-primary);
    color: white;
    text-align: center;
    text-decoration: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: 0.3s;
    font-size: 1.125rem;
    cursor: pointer;
    font-weight: bold;
}

.form_button.btn_back {
    border: var(--color-text) solid 2px;
    background: var(--color-text);
}

.form_button_wrap {
    display: flex;
    justify-content: center;
    margin: 2rem auto;
}

.form_button_wrap button {
    margin: 0.5em !important;
}

.inquiry_form .table {
    border: none;
}

.inquiry_form .table_df tr:not(:last-of-type) {
    border-bottom: 1px solid #cccccc;
}

.inquiry_form .table_df th {
    background: none;
    border: none;
    text-align: left;
    padding: 1.4em 50px 1.2em 0.5em;
    vertical-align: top;
    font-weight: bold;
    position: relative;
}

.inquiry_form .table_df td {
    background: none;
    border: none;
    padding: 1.2em 0.5em;
}

.inquiry_form .input_wrap {
    display: block;
    margin: 0;
    padding: 0 0.2em;
}

.inquiry_form .table_df th .required {
    color: var(--color-red);
    margin-left: 0.5em;
}

.inquiry_form .formError .formErrorContent {
    color: var(--color-red);
}

.inquiry_form .fixed .formErrorContent {
    background: #ffcdcd;
    border: none
}

@media (max-width: 768px) {
    .inquiry_form .table_df th {
        padding: 1em 0 0;
    }

    .inquiry_form .table_df td {
        padding: 0.5em 0 1em;
    }

    .inquiry_form .input_wrap {
        margin: 0;
    }

    .table_df input[type=text],
    .table_df input[type=url],
    .table_df input[type=email],
    .table_df input[type=tel],
    .table_df input[type=date],
    .table_df input[type=number],
    .table_df select,
    .table_df textarea {
        margin: 0.2em 0;
    }

    .form_button_wrap {
        flex-flow: column;
        justify-content: center;
        align-items: center;
    }
}

@media (min-width: 769px) {

    .table_df input[type=text],
    .table_df input[type=url],
    .table_df input[type=email],
    .table_df input[type=tel],
    .table_df input[type=date],
    .table_df input[type=text],
    .table_df select {
        margin: 0 0.2em;
    }

    .table_df input[type=number] {
        width: 65px;
    }

    .table_df input.postal-code {
        width: 200px;
    }

    .table_df input.region {
        width: 100px;
    }

    .table_df input.locality {
        width: 150px;
    }

    .table_df input.street-address {
        width: 100%;
    }

    .table_df textarea {
        width: 100%;
    }

    .table_df .input_wrap {
        display: block;
        margin: 0 0.2em;
    }

    .table_df .input_wrap input,
    .table_df .input_wrap textarea {
        margin: 0;
    }

    .table_df .input_wrap:last-child {
        margin-right: auto;
    }

    .table_df .submit {
        margin: 60px 0 0;
    }
}

/*@media (min-width: 769px) and (hover: hover) and (min-width: 769px) {
    .inquiry_form .form_button.form_back:hover {
        background: #bfbfbf;
        border-color: #bfbfbf;
        color: #666;
    }
}

@media (min-width: 769px) {
    .inquiry_form .form_button.form_send {
        background: #151c3b;
        border-color: #151c3b;
        color: #fff;
    }
}*/

/* -------------------------------------------------------
   Cookie使用同意ポップアップ
   
---------------------------------------------------------- */
.cookie-consent {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    bottom: 0;
    width: 100%;
    font-size: 12px;
    color: #fff;
    background: rgba(0, 0, 0, .85);
    padding: 25px;
    box-sizing: border-box;
    visibility: hidden;
    z-index: 10000;
}

@media only screen and (min-width: 600px) {
    .cookie-inner {
        width: 600px;
        margin: 0 auto;
        display: flex;
        justify-content: space-between;
    }
}

.cookie-consent.is-show {
    visibility: visible;
}

.cookie-consent a {
    color: #fff !important;
}

.cookie-agree {
    color: #fff;
    font-size: 16px;
    text-align: center;
    background: dodgerblue;
    padding: 7px 25px;
}

.cookie-agree:hover {
    cursor: pointer;
}

.cookie-close {
    position: absolute;
    top: -32px;
    right: 0;
    font-size: 16px;
    color: #fff;
    background: rgba(0, 0, 0, .70);
    padding: 4px 15px;
    cursor: pointer;
    border-radius: 5px 5px 0 0;
}

.cookie-close:hover {
    cursor: pointer;
}

/* パッと消える */
.cc-hide1 {
    display: none;
}

/* ゆっくり消える */
.cc-hide2 {
    animation: hide 1s linear 0s;
    animation-fill-mode: forwards;
}

@keyframes hide {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
        visibility: hidden;
    }
}

@media screen and (max-width: 600px) {
    .cookie-consent {
        flex-direction: column;
    }

    .cookie-text {
        margin-bottom: 1em;
    }
}


/* =========================
       レスポンシブ
    ========================= */
@media (min-width: 768px) and (max-width: 991.98px) {
    .header__container {
        grid-template-columns: 120px 1fr 100px;
    }

    .logo img {
        width: 110px;
    }

    .nav__link {
        padding: 1rem 0 1rem 1rem;
        font-size: 0.9rem;
    }

    .top-strength__grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .page_title {
        height: 220px;
    }

    .page_title .h1 {
        width: 100%;
        max-width: 100%;
        text-align: left;
        margin-left: 1rem;
        font-size: 2rem;
    }

    #main_contents h3 {
        font-size: 1.25rem;
    }

    #main_contents h4 {
        font-size: 1.125rem;
    }

}

@media (min-width: 768.99px) {
    .top-nav__icon {
        display: none;
    }
}

@media (max-width: 768px) {
    .pc-only {
        display: none;
    }

    .header__container {
        display: flex;
        justify-content: space-between;
    }

    .header__contact,
    .header__top,
    .footer__grid {
        display: none;
    }

    .header__top {
        padding: 0.75rem 0;
    }

    .logo {
        padding: 0.75rem 0.5rem;
    }

    .logo img {
        width: 120px;
    }

    .search-box {
        display: none;
    }

    .header__actions {
        gap: 0.5rem;
    }

    .hamburger {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: white;
        flex-direction: column;
        gap: 0;
        align-items: stretch;
        padding-top: 4rem;
        transition: left 0.3s;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
        overflow-y: auto;
    }

    .nav.active {
        left: 0;
    }

    .nav__item {
        border-bottom: 1px solid var(--bg-light);
    }

    .nav__link {
        padding: 1rem 1.5rem;
    }

    .nav__dropdown {
        position: static;
        opacity: 0;
        visibility: hidden;
        max-height: 0;
        overflow: hidden;
        transform: none;
        box-shadow: none;
        border-radius: 0;
        background: var(--bg-light);
        padding: 0;
        transition: max-height 0.3s, opacity 0.3s;
    }

    .nav__item.active .nav__dropdown {
        opacity: 1;
        visibility: visible;
        max-height: 300px;
        padding: 0.5rem 0;
    }

    .nav__dropdown a {
        padding-left: 2.5rem;
    }

    .nav__dropdown a:hover {
        padding-left: 3rem;
    }

    .header__main .h-btn {
        display: block;
    }

    .h-btn {
        padding: 0.6rem 1.2rem;
        font-size: 0.85rem;
        margin: 1.5rem 1rem;
    }

    .top-hero {
        flex-direction: column;
        padding: var(--space-md);
    }

    .top-hero__content {
        padding-right: 0;
        position: relative;
        margin-bottom: var(--space-lg);
    }

    .top-hero__title {
        font-size: 1.5rem;
    }

    .top-hero__img {
        display: none;
    }

    .top-search {
        padding: var(--space-md);
    }

    .top-search__title,
    .top-feature__title {
        font-size: 1.5rem;
        margin-bottom: var(--space-md);
    }

    .top-search__category {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }

    .top-search__category-label {
        margin-bottom: var(--space-sm);
    }

    .f-contact .contents-inner {
        grid-template-columns: 1fr;
        padding: 0 var(--space-md);
    }

    .footer__bottom {
        border: 0;
        padding: 0;
    }

    .f-nav ul li,
    .f-nav ul li:last-child {
        display: block;
        border: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.4);
        padding: var(--space-sm) 0;
    }

    .top-feature {
        padding: var(--space-lg) var(--space-md);
    }

    .top-strength {
        padding: var(--space-lg) var(--space-md);

    }

    .top-strength__main {
        font-size: 1.5rem;
    }

    .top-strength__title::before,
    .top-strength__title::after {
        width: 20px;
    }

    .top-news {
        padding: var(--space-lg) var(--space-md);

    }

    /*.top-news__header {
        flex-direction: column;
        align-items: flex-start;
    }*/

    .top-news__list {
        margin-left: 0;
    }

    .top-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-md);
        margin-top: var(--space-md);
    }

    .top-news__title {
        font-size: 1.25rem;
    }

    .btn_top {
        font-size: 0.85rem;
        padding: 0.6rem 1.2rem;
    }

    .page_title {
        height: 180px;
    }

    .page_title .h1 {
        width: 100%;
        max-width: 100%;
        text-align: left;
        margin-left: 1rem;
        font-size: 1.75rem;
    }

    #main_contents h3 {
        font-size: 1.125rem;
    }

    #main_contents h4 {
        font-size: 1.125rem;
    }

    .contact-phone a {
        display: block;
        font-size: 2rem;
        margin-left: 0rem;
    }

    .table_df,
    .table_df tr,
    .table_df th,
    .table_df td {
        display: block;
    }
}

@media (max-width: 480px) {
    .h-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }

    .top-hero__title {
        font-size: 1.2rem;
    }

    .top-hero__desc {
        font-size: 0.85rem;
    }

    .top-hero__buttons {
        flex-direction: column;
    }

    .btn_top {
        width: 100%;
    }

    .top-search__category-links {
        gap: var(--space-sm);
    }

    .top-search__category-link {
        font-size: 0.75rem;
        padding: 0.3rem 0.6rem;
    }

    .top-strength__grid {
        gap: var(--space-md);
    }

    .top-news__item {
        flex-direction: column;
        gap: var(--space-sm);
        font-size: 0.9rem;
    }

    .top-news__cat {
        align-self: flex-start;
    }
}