/* common */
.page-sec:first-child {
    padding-top: 12rem;
}
.page-ttl {
    font-size: min(4.5rem, 45px);
    font-weight: 600;
    text-align: center;
}
.page-ttl span {
    font-size: min(2.9rem, 29px);
    display: block;
}
.page-ttl + .txt {
    margin: 4rem 0;
}
.txt + .txt {
    margin-top: 2rem;
}
.txt + .sec-ttl {
    margin-top: 6rem;
}
.txt-l {
    font-size: min(2.8rem, 28px);
}
.txt-b {
    font-weight: 600;
}
.txt-g {
    color: #727272;
}
.line-ttl {
    position: relative;
    width: max-content;
    padding-right: 1rem;
    margin-bottom: 5rem;
}
.line-ttl:before {
    content: "";
    width: 120rem;
    height: 1px;
    background-color: #707070;
    position: absolute;
    top: 100%;
    left: 0;
}
.line-ttl:after {
    content: "";
    background-color: #fff;
    width: 100%;
    height: 1px;
    position: absolute;
    top: 100%;
    left: 0;
}
.bg .line-ttl:after {
    background-color: #F2F0EA;
}
@media (max-width: 899px) {
    .line-ttl:before {
        width: calc(100vw - 16%);
    }
    .txt-l {
        font-size: 3.6rem;
    }
}

/* order */
.order-page .page-sec:not(:first-child) {
    padding: 4rem 0;
}
.order-page .page-ttl {
    margin-bottom: 13rem;
}
.order-page .sec-ttl {
    font-size: min(3.5rem, 35px);
    margin-bottom: 4rem;
}
.order-page .tab.col2-flex {
    column-gap: 2rem;
    align-items: center;
}
.order-page .tab__menu {
    border-bottom: 1px solid #000;
}
.order-page .tab__menu-item {
    cursor: pointer;
    padding: 2rem 4rem;
    border-top: 1px solid #000;
}
.order-page .tab__menu-item.is-active {
    background-color: #fff;
}
.order-page .tab__menu-item .txt {
    font-weight: 600;
}
.order-page .bnr-img + .btn {
    width: 45rem;
    line-height: 6rem;
    margin: 4rem auto 0;
}
.order-page .price-wrap {
    margin-bottom: 16rem;
}
.order-page .btn-simulation {
    margin-bottom: 10rem;
}
.order-page .btn-simulation .btn {
    width: 54.8rem;
    line-height: 6rem;
    margin: auto;
    border-radius: 0;
}
.order-page .btn-order .btn,
.order-page .btn-contact .btn {
    width: 45rem;
    line-height: 6rem;
    margin: 4rem auto 0;
}
.order-page .bx-viewport {
    overflow: visible!important;
}
.order-page .case-slider .txt {
    font-weight: 600;
    margin-top: 1rem;
}
.order-page .btn-contact {
    margin: 12rem 0;
}
.order-page .btn-contact .btn {
    border-radius: 0;
}
@media (max-width: 899px) {
    .order-page .tab.col2-flex {
        grid-template-columns: 1fr;
    }
}

/* template */
.template-page .page-sec {
    padding-bottom: 12rem;
}
.template-page .btn-download .btn {
    width: 52rem;
    line-height: 6rem;
    margin: 4rem auto 0;
}
.template-wrap.col2-flex {
    column-gap: 4rem;
    row-gap: 7rem;
    margin: 6rem 0 0;
}
.template-wrap.col2-flex .img {
    width: 38.7rem;
    margin: 0 auto .5rem;
}
.template-wrap.col2-flex figcaption {
    font-size: min(2.2rem, 28px);
    text-align: center;
    margin: 2rem 0;
}
.template-wrap.col2-flex figcaption span {
    font-size: min(3.5rem, 35px);
}
.template-wrap.col2-flex .btn-wrap {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 1.8rem;
}
.template-wrap.col2-flex .btn-wrap .btn {
    line-height: 6rem;
    border-radius: 3rem;
    font-size: min(2rem, 20px);
}
@media (max-width: 899px) {
    .template-page .btn-download .btn {
        width: 90%;
    }
    .template-wrap.col2-flex {
        grid-template-columns: 1fr;
    }
}

.txt-sec .txt-l {
    font-weight: 600;
    margin: 3rem 0;
}
.txt-sec .txt dt {
    font-weight: 600;
    margin-bottom: 1rem;
}
.txt-sec .txt p + p {
    margin-top: 2rem;
}
.txt-sec .txt + .txt {
    margin-top: 4rem;
}
.txt-sec .txt + .txt-l {
    margin-top: 6rem;
}
.txt-sec .txt a {
    text-decoration: underline;
}

/* price */
.price-page .page-sec {
    padding: 8rem 0 10rem;
}
.price-page .sec-ttl {
    text-align: left;
}
.price-wrap.col3-flex {
    text-align: center;
    column-gap: 3.7rem;
    row-gap: 3rem;
    margin: 5rem 0;
}
.price-wrap.col3-flex .price-ttl {
    font-size: min(3rem, 30px);
    background: linear-gradient(to bottom, #AFA26B, #917C24);
    color: #fff;
    padding: 2rem 0;
    letter-spacing: -.02em;
}
.price-wrap.col3-flex .price-ttl small {
    font-size: min(2.5rem, 25px);
}
.price-wrap.col3-flex .ttl-l {
    font-size: min(7rem, 70px);
    display: block;
}
.price-wrap.col3-flex .ttl-l span {
    font-size: min(4.5rem, 45px);
}
.price-wrap.col3-flex .txt {
    background-color: #fff;
    padding: 1rem 0;
}
.price-page .price-wrap + .btn {
    width: 45rem;
    line-height: 6rem;
    margin: auto;
}
@media (max-width: 899px) {
    .price-wrap.col3-flex {
        grid-template-columns: repeat(2,1fr);
    }
    .price-wrap.col3-flex .ttl-l {
        font-size: 5rem;
    }
}


/* 詳しく見積もる */

.price-page .calc-wrap {
    display: grid;
    grid-template-columns: 69.7rem 48.3rem;
    column-gap: 2rem;
    align-items: flex-start;
    position: relative;
}
.price-page .calc-wrap .side {
    position: sticky;
    top: 11rem;
}
.calc-wrap table {
    font-size: min(1.7rem, 18px);
    line-height: 2.5;
    width: 100%;
    table-layout: fixed;
    margin: 2rem 0;
    border-collapse:collapse;
}
.calc-wrap .bg-box {
    background-color: #F2F0EA;
    padding: 2rem;
}
.calc-wrap .bg-box + .bg-box {
    margin-top: 2rem;
}
.calc-wrap .w-box {
    background-color: #fff;
    cursor: pointer;
}
.calc-wrap .select-wrap .w-box {
    margin: 2rem 0;
    display: flex;
    align-items: flex-start;
}
.calc-wrap .select-wrap .w-box input {
    margin: 2.5rem;
}
.calc-wrap .select-wrap label {
    display: inline-block;
    width: 100%;
    padding: 2rem 3rem 2rem 6rem;
    position: relative;
    cursor: pointer;
}
.calc-wrap .select-wrap input {
    opacity: 0;
    -webkit-appearance: none;
    appearance: none;
    position: absolute;
}
.calc-wrap .select-wrap input[type="radio"] + .txt-b::before,
.calc-wrap .select-wrap input[type="checkbox"] + span::before{
    content: "";
    width: 3rem;
    height: 3rem;
    border: 2px solid #ccc;
    border-radius: 5px;
    position: absolute;
    top: 1.7rem;
    left: 2rem;
}
.calc-wrap .select-wrap input[type="radio"]:checked + .txt-b::before,
.calc-wrap .select-wrap input[type="checkbox"]:checked+ span::before {
    background: url(../img/common/icon-check.svg) center / 2rem 2rem no-repeat;
}
.calc-wrap .select-wrap input[type="radio"]:checked + .txt-b::after {
    content: "";
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    border: 3px solid #FF003B;
}
.calc-wrap .w-box label .txt + .txt {
    margin: 1rem 0 0 2rem;
    display: block;
}
.calc-wrap .w-box + .txt {
    display: block;
    text-align: right;
    text-decoration: underline;
}
.calc-wrap .table-wrap .w-box {
    margin: 2rem 0;
    padding: 1rem 2rem 2rem;
}
.calc-wrap table .img img {
    width: 2.1rem;
}
.calc-wrap table input,
.calc-wrap table select {
    width: 100%;
    cursor: pointer;
}
.calc-wrap table .select-box {
    height: 4rem;
    border: none;
    background-color: #efefef;
    display: block;
    margin: 0;
    padding: 1px 1rem;
    font-size: 1.6rem;
    text-align: center;
}
.calc-wrap table td {
    vertical-align: middle;
}
.calc-wrap table .col2 {
    display: flex;
    width: 100%;
    align-items: center;
    justify-content: center;
    column-gap: .5rem;
    padding: 1.7rem 0;
    margin-left: 1.2rem;
}
.calc-wrap table .txt {
    font-size: 2rem;
    font-weight: 600;
}
.calc-wrap table .txt span {
    font-size: 1.4rem;
    margin-left: 2rem;
}
.calc-wrap table + .txt {
    text-align: center;
}
.calc-wrap button {
    border: none;
    cursor: pointer;
}
.calc-wrap button.add-flavor {
    width: 100%;
    padding: 1rem 2rem;
    position: relative;
    font-weight: bold;
}
.calc-wrap button.add-flavor img {
    width: 2.2rem;
    position: absolute;
    left: 2rem;
    top: 50%;
    transform: translateY(-50%);
}
@media (max-width: 899px) {
    .calc-wrap .select-wrap input[type="radio"] + .txt-b::before,
    .calc-wrap .select-wrap input[type="checkbox"] + span::before{
        top: .8em;
    }
    .price-page .page-sec .inner {
        position: relative;
    }
    .price-page #calc-form + .sp-txt {
        position: absolute;
        top: 2rem;
        right: 0;
        font-size: 2.2rem;
        font-weight: 400;
        color: #595858;
    }
}

/* 見積もり結果 */
.result-box {
    border: 1px solid #000;
    padding: 2rem;
    margin-bottom: 2rem;
}
.result-box table tr:not(.no-border):not(.half-border) {
    border-bottom: 1px solid #000;
}
.result-box table tr.half-border th:nth-child(3),
.result-box table tr.half-border th:nth-child(4),
.result-box table tr.half-border th:nth-child(5){
    border-bottom: 1px solid #000;
}
.result-box .btn-wrap .btn {
    width: 100%;
    line-height: 6rem;
    border-radius: 3rem;
    cursor: pointer;
}
.result-box .btn-wrap .btn-gray {
    background-color: #707070;
    color: #fff;
    margin-top: 1rem;
}
.side .btn-reset input {
    width: 100%;
    border: 1px solid #000;
    border-radius: 3rem;
    background-color: #fff;
    font-size: 2.5rem;
    line-height: 5.3rem;
    cursor: pointer;
}
@media (max-width: 899px) {
    .price-page .calc-wrap {
        grid-template-columns: 1fr;
        row-gap: 2rem;
    }
    .price-page .calc-wrap .side {
        bottom: 1rem;
        top: initial;
        background-color: #fff;
    }
}

.price-page .header-fix {
    position: absolute;
}

/* case-study */
/* main visual */
        .mv {
            position: relative;
            max-height: 600px;
            margin: 0 auto;
            overflow: hidden;
        }
        .mv .img {
            width: 100%;
            height: 100%;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .mv .img img {
            max-height: 600px;
            width: 100%;
            height: auto;
            object-fit: cover;
        }
        .mv .inner {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            color: #fff;
            background-color: rgba(0, 0, 0, 0.5);
            padding: 3rem 4rem;
            /* border-radius: 1rem; */
        }
        .mv .catch {
            font-size: min(2.4rem, 24px);
            margin-bottom: 2rem;
            letter-spacing: 0.1em;
        }
        .mv .main-txt {
            font-size: min(3.6rem, 36px);
            font-weight: 600;
            line-height: 1.3;
        }
        @media (max-width: 899px) {
            .mv {
                height: 50rem;
            }
            .mv .img {
                height: 100%;
                object-fit: cover;
            }
            .mv .img img {
                height: 100%;
                object-fit: cover;
            }
            .mv .catch {
                font-size: 3.2rem;
            }
            .mv .main-txt {
                font-size: 4.8rem;
            }
        }

        /* content sections */
        .content-sec {
            padding: 8rem 0;
        }
        .content-sec .content-body {
            max-width: 100rem;
            margin: 0 auto;
        }
        .content-sec .content-body p {
            margin-bottom: 2rem;
            line-height: 1.6;
        }
        .content-sec .content-img {
            margin: 4rem 0;
            text-align: center;
        }
        .content-sec .content-img img {
            max-width: 80rem;
            height: auto;
            border-radius: 1rem;
        }
        .content-sec h2 {
            font-size: min(3.2rem, 32px);
            font-weight: 600;
            margin: 6rem 0 3rem;
            color: #333;
        }
        .content-sec h2:first-child {
            margin-top: 0;
        }

        /* company info section */
        .content-sec .py-90 {
            padding: 6rem 4rem;
            margin: 4rem 0;
        }
        .content-sec .py-90 .inner {
            max-width: 100rem;
            margin: 0 auto;
            padding: 0;
        }
        .content-sec .py-90 h2 {
            margin-top: 0;
            margin-bottom: 3rem;
            font-size: min(2.8rem, 28px);
            text-align: center;
        }
        
        /* company detail table */
        .content-sec .Detail--table {
            width: 100%;
            max-width: 100rem;
            border-collapse: collapse;
            margin: 0 auto;
            font-size: min(1.6rem, 16px);
            line-height: 1.8;
        }
        .content-sec .Detail--table th,
        .content-sec .Detail--table td {
            text-align: left;
            padding: 1.5rem 2rem;
            border-bottom: 1px solid #ddd;
            vertical-align: middle;
        }
        .content-sec .Detail--table th {
            width: 20%;
            min-width: 12rem;
            color: #333;
            background: #F7F5EF;
            font-weight: 600;
        }
        .content-sec .Detail--table td {
            color: #555;
        }
        .content-sec .Detail--table tr:last-child th,
        .content-sec .Detail--table tr:last-child td {
            border-bottom: none;
        }
        
        @media (max-width: 899px) {
            .content-sec .py-90 {
                padding: 6rem 3%;
                margin: 6rem 0;
            }
            .content-sec .py-90 .inner {
                width: 100%;
            }
            .content-sec .py-90 h2 {
                font-size: 3.6rem;
                margin-bottom: 4rem;
            }
            .content-sec .Detail--table {
                font-size: 2.4rem;
                display: block;
            }
            .content-sec .Detail--table tbody,
            .content-sec .Detail--table tr {
                display: block;
            }
            .content-sec .Detail--table th,
            .content-sec .Detail--table td {
                display: block;
                width: 100%;
                padding: 2rem;
            }
            .content-sec .Detail--table th {
                border-bottom: none;
                padding-bottom: 1rem;
            }
            .content-sec .Detail--table td {
                padding-top: 0;
                padding-bottom: 3rem;
            }
            .content-sec .Detail--table tr:last-child td {
                padding-bottom: 2rem;
            }
        }

        .highlight-box {
            background-color: #f5f5f5;
            padding: 3rem;
            margin: 4rem 0;
            border-left: 5px solid #B99546;
            border-radius: .5rem;
        }
        .highlight-box .highlight-ttl {
            font-size: min(2.4rem, 24px);
            font-weight: 600;
            margin-bottom: 2rem;
            color: #B99546;
        }

        /* design showcase */
        .design-showcase {
            /* background-color: #f8f8f8; */
            padding: 6rem 0;
            text-align: center;
        }
        .design-showcase .sec-ttl {
            margin-bottom: 4rem;
        }
        .design-showcase .design-img {
            max-width: 96rem;
            margin: 0 auto;
        }

        /* case-study col2-flex link module */
        .content-sec a.col2-flex {
            display: grid;
            grid-template-columns: repeat(2,1fr);
            column-gap: 4rem;
            margin: 4rem 0;
            text-decoration: none;
            color: inherit;
            transition: opacity 0.3s;
            border: 1px solid #E0E0E0;
            overflow: hidden;
        }
        .content-sec a.col2-flex:hover {
            opacity: 0.8;
        }
        .content-sec a.col2-flex .img {
            overflow: hidden;
        }
        .content-sec a.col2-flex .img img {
            width: 100%;
            height: auto;
            object-fit: cover;
        }
        .content-sec a.col2-flex .txt-wrap {
            background-color: #fff;
            padding: 2rem;
        }
        .content-sec a.col2-flex .ttl {
            font-size: min(2rem, 20px);
            font-weight: 600;
            margin: 1rem 0;
        }
        .content-sec a.col2-flex .name {
            font-size: min(1.8rem, 18px);
            font-weight: 600;
            color: #B99546;
            margin-bottom: 1rem;
        }
        .content-sec a.col2-flex .txt {
            font-size: min(1.6rem, 16px);
            line-height: 1.6;
            margin-bottom: 1rem;
        }
        .content-sec a.col2-flex .link {
            display: block;
            width: max-content;
            font-size: min(1.8rem, 18px);
            margin-left: auto;
            color: #818181;
        }
        @media (max-width: 899px) {
            .content-sec a.col2-flex {
                grid-template-columns: 1fr;
                row-gap: 2rem;
            }
            .content-sec a.col2-flex .ttl {
                font-size: 2.8rem;
            }
            .content-sec a.col2-flex .name {
                font-size: 2.4rem;
            }
            .content-sec a.col2-flex .txt {
                font-size: 2.4rem;
            }
            .content-sec a.col2-flex .link {
                font-size: 2.4rem;
            }
        }

/* Contact Popup */
.bg-box.table-wrap {
    position: relative;
    overflow: visible;
}

.contact-popup {
    background-color: #fff3cd;
    border: 2px solid #ffc107;
    border-radius: 0.5rem;
    padding: 1.5rem 2rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    animation: slideDown 0.3s ease-out;
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    z-index: 9999;
    margin: 0 auto;
    width: calc(100% - 4rem);
    max-width: 600px;
}

.contact-popup .popup-message {
    color: #856404;
    font-size: 1.6rem;
    font-weight: 600;
    text-align: center;
    margin: 0;
    line-height: 1.5;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media only screen and (max-width: 899px) {
    .contact-popup {
        padding: 1.2rem 1.5rem;
        width: calc(100% - 3rem);
        max-width: none;
    }
    
    .contact-popup .popup-message {
        font-size: 1.4rem;
    }
}

/* Download Toast Notification */
.download-toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.7);
    background: linear-gradient(135deg, #D4AF37 0%, #F4D03F 100%);
    color: #000;
    padding: 2rem 4rem;
    border-radius: 1rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    z-index: 10000;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    font-size: min(1.8rem, 18px);
    font-weight: 600;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    min-width: 320px;
    opacity: 0;
}

.download-toast.show {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.download-toast-icon {
    width: 2.4rem;
    height: 2.4rem;
    flex-shrink: 0;
}

.download-toast-icon svg {
    width: 100%;
    height: 100%;
}

.download-toast-message {
    flex: 1;
}

@media (max-width: 899px) {
    .download-toast {
        min-width: auto;
        width: calc(100% - 4rem);
        max-width: 400px;
        padding: 1.5rem 2.5rem;
        font-size: 1.6rem;
    }
    
    .download-toast-icon {
        width: 2rem;
        height: 2rem;
    }
}