@charset "UTF-8";

/* ==========================================================================
   Page: FAQ
   ========================================================================== */

/* --------------------------------------------------------------------------
   Layout Common
   -------------------------------------------------------------------------- */
main {
    padding-bottom: 100px;
}

@media screen and (max-width: 767px) {
    main {
        padding-bottom: 60px;
    }
}

/* --------------------------------------------------------------------------
   p-faq-hero
   -------------------------------------------------------------------------- */
.p-faq-hero {
    text-align: center;
    padding: 80px 0 60px;
}

.p-faq-hero__inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.p-faq-hero__title {
    font-family: var(--font-shippori);
    font-size: 32px;
    letter-spacing: 0.1em;
    margin-bottom: 10px;
    font-weight: 500;
}

.p-faq-hero__subtitle {
    display: block;
    font-family: var(--font-gothic);
    font-size: 14px;
    color: var(--color-accent);
    letter-spacing: 0.1em;
    font-weight: 500;
}

@media screen and (max-width: 767px) {
    .p-faq-hero {
        padding: 50px 0 40px;
    }

    .p-faq-hero__title {
        font-size: 24px;
    }
}

/* --------------------------------------------------------------------------
   p-faq-list
   -------------------------------------------------------------------------- */
.p-faq-list {
    background-color: none;
    max-width: 1100px;
    margin: 0 auto;
    padding: 60px;
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
    margin-bottom: 120px;
    /* Add space before products */
}

.p-faq-list__inner {
    display: flex;
    flex-direction: column;
}

/* --- Tabs --- */
.p-faq-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 40px;
}

.p-faq-tabs__btn {
    background: transparent;
    border: 1px solid #ccc;
    padding: 10px 0;
    font-family: var(--font-gothic);
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    color: #999;
    width: 250px;
    text-align: center;
}

.p-faq-tabs__btn.is-active {
    background-color: var(--color-accent);
    border-color: var(--color-accent);
    color: #fff;
}

.p-faq-panel {
    display: none;
    animation: fadeIn 0.5s ease;
}

.p-faq-panel.is-active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

/* --- Accordion Items --- */
.p-faq-item {
    border-bottom: 1px solid #eee;
}

.p-faq-item:last-child {
    border-bottom: none;
}

/* Question */
.p-faq-item__question {
    display: flex;
    align-items: center;
    /* Center vertically including toggle */
    width: 100%;
    background: transparent;
    border: none;
    text-align: left;
    cursor: pointer;
    padding: 20px 0;
    gap: 20px;
    position: relative;
    padding-right: 40px;
    /* Space for toggle */
}

.p-faq-item__q-mark {
    font-family: var(--font-mincho);
    font-size: 40px;
    color: var(--color-accent);
    line-height: 1;
    flex-shrink: 0;
}

.p-faq-item__q-text {
    font-family: var(--font-shippori);
    font-size: 18px;
    font-weight: 500;
    line-height: 1.6;
}

/* Toggle Icon (+/-) */
.p-faq-item__toggle {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
}

.p-faq-item__toggle::before,
.p-faq-item__toggle::after {
    content: '';
    position: absolute;
    background-color: #ccc;
    transition: transform 0.3s;
}

.p-faq-item__toggle::before {
    width: 100%;
    height: 2px;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
}

.p-faq-item__toggle::after {
    width: 2px;
    height: 100%;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
}

/* Open State for Toggle */
.p-faq-item.is-open .p-faq-item__toggle::after {
    transform: translateX(-50%) rotate(90deg);
    /* Turn into minus */
    opacity: 0;
    /* Or just rotate to align with horizontal */
}

/* Re-thinking toggle animation */
.p-faq-item.is-open .p-faq-item__toggle::before {
    transform: translateY(-50%) rotate(180deg);
}

/* Answer */
.p-faq-item__answer {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease-out;
    padding: 0;
}

.p-faq-item__answer-inner {
    overflow: hidden;
    display: flex;
    align-items: baseline;
    gap: 20px;
    padding: 0 20px 0 0;
    /* Inner padding only */
    opacity: 0;
    transition: opacity 0.3s;
}

/* Open State for Answer */
.p-faq-item.is-open .p-faq-item__answer {
    grid-template-rows: 1fr;
    padding-bottom: 20px;
    /* Space after answer */
}

.p-faq-item.is-open .p-faq-item__answer-inner {
    opacity: 1;
}


.p-faq-item__a-mark {
    font-family: var(--font-mincho);
    font-size: 40px;
    color: #ccc;
    line-height: 1;
    flex-shrink: 0;
}

.p-faq-item__a-text {
    font-family: var(--font-gothic);
    font-size: 15px;
    line-height: 1.8;
    color: #666;
}

/* --------------------------------------------------------------------------
   p-products (Copied from index.css for FAQ page)
   -------------------------------------------------------------------------- */
.p-products {
    padding: 0 0 100px;
}

.p-products__inner {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

.p-products__heading {
    text-align: center;
    font-size: 24px;
    font-weight: 500;
    letter-spacing: 0.2em;
    margin-bottom: 60px;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.p-products__heading::after {
    content: '';
    display: block;
    width: 40px;
    height: 1px;
    background-color: #333;
    margin: 15px auto 0;
}

.p-products__list {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.c-product-card {
    text-align: center;
    font-family: var(--font-gothic);
}

.c-product-card__img:hover {
    opacity: 0.8;
}

.c-product-card__name {
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 5px;
}

.c-product-card__price {
    font-size: 13px;
    color: #666;
}

/* Responsive */
@media screen and (max-width: 1024px) {
    .p-products__list {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 767px) {
    .p-faq-list {
        padding: 40px 20px;
        margin: 0 20px;
        margin-bottom: 80px;
    }

    .p-faq-item__question {
        padding: 15px 0;
        gap: 15px;
        padding-right: 30px;
    }

    .p-faq-item__q-mark,
    .p-faq-item__a-mark {
        font-size: 16px;
    }

    .p-faq-item__q-text {
        font-size: 14px;
    }

    .p-faq-item__a-text {
        font-size: 14px;
    }

    .p-faq-tabs {
        gap: 10px;
        display: block;
    }

    .p-faq-tabs__btn {
        padding: 8px 0;
        font-size: 14px;
        width: 48%;
        margin-bottom: 10px;
        /* Adjust for mobile */
    }
}

@media screen and (max-width: 590px) {
    .p-products__list {
        grid-template-columns: 1fr;
    }

    .c-product-card__img img {
        width: 100%;
    }
}