/* AI Test Center page styles (follows the AI Omakase Plan / pricing page design) */

/* Smooth in-page jumps from the operation tags to their detail cards */
html {
    scroll-behavior: smooth;
}

/* Base */
section.tc-page {
    background: #fff;
    padding: 0;
    font-family: 'Hiragino Sans', sans-serif;
}

.tc-page * {
    box-sizing: border-box;
}

.tc-intro {
    position: relative;
    isolation: isolate;
    padding-bottom: 48px;
}

.tc-intro::before {
    content: "";
    position: absolute;
    inset: 0 calc(50% - 50vw);
    z-index: -1;
    background: linear-gradient(#fff, #ededf3);
}

/* Header */
.tc-header {
    text-align: center;
    margin-bottom: 24px;
}

.tc-title {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.container.container_topicpath_real-device-test-center {
    display: none;
}

/* Line break shown only on narrow screens (toggled in the responsive rules) */
.tc-br-sp {
    display: none;
}

/* In-page nav: links to the operation detail cards below */
.tc-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px 0px;
    max-width: 960px;
    margin: 0 auto;
    padding: 8px 0px;
    list-style: none;
    border-radius: 999px;
}

.tc-tags li {
    display: flex;
}

.tc-tags a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 12px;
    border-radius: 100px;
    font-size: 10px;
    font-weight: 600;
    color: var(--main-color-1);
    background: #f5faf7;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.2s ease;
}

/* Operation icon (same asset as the detail cards below) to the left of the text */
.tc-tag-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    object-fit: contain;
    opacity: 0.9;
}

/* Down-chevron after each link (inline SVG data URI so it never depends on a file path) */
.tc-tags a::after {
    content: "";
    width: 12px;
    height: 12px;
    flex-shrink: 0;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M6 9l6 6 6-6' stroke='%233EA85B' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat center;
    background-size: contain;
}

.tc-tags a:hover {
    background: #e6f1ea;
}

/* Shared section */
.tc-section {
    max-width: 960px;
    margin: 100px auto;
}

.section-title {
    font-size: 27px;
    font-weight: 700;
    color: #2a3037;
    text-align: center;
    line-height: 1.5;
    margin: 0 0 32px;
}

/* Flow */
.tc-flow-note {
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    line-height: 1.6;
    margin: -16px 0 40px 0;
    text-wrap: pretty;
}

.tc-flow {
    display: flex;
    align-items: stretch;
    justify-content: center;
    gap: 12px;
}

.tc-flow-step {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #fafafa;
    border-radius: 12px;
    padding: 24px 16px;
    text-align: center;
}

.tc-flow-num {
    width: 32px;
    height: 32px;
    background: var(--main-color-1);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 12px;
}

.tc-flow-img {
    display: block;
    width: 100%;
    max-width: 180px;
    height: auto;
    margin: 0 auto 16px;
    border-radius: 8px;
    /* Monochrome, like the operation illustrations below: green is kept for actions. */
    filter: grayscale(1);
}

.tc-flow-step p {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    line-height: 1.6;
    margin: 0;
}

/* Arrow between flow steps */
.tc-flow-arrow {
    flex-shrink: 0;
    align-self: center;
    width: 0;
    height: 0;
    border-top: 14px solid transparent;
    border-bottom: 14px solid transparent;
    border-left: 16px solid rgba(11, 163, 96, 0.54);
}

/* Highlighter-style emphasis; keep the product name from breaking mid-word */
.tc-highlight {
    --tc-marker: rgba(11, 163, 96, 0.3);
    background: linear-gradient(transparent 60%, var(--tc-marker) 60%) no-repeat;
    background-size: 100% 100%;
    white-space: nowrap;
}

.tc-highlight--gray {
    --tc-marker: #d2d2db;
}

.fade-in-up .tc-highlight {
    background-size: 0% 100%;
    transition: background-size 0.8s ease-out 0.5s;
}

.fade-in-up.visible .tc-highlight {
    background-size: 100% 100%;
}

/* Reasons to choose */
.tc-reasons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.tc-reason-card {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 16px;
    row-gap: 10px;
    align-items: center;
    border: 6px solid #fafafa;
    border-radius: 12px;
    padding: 24px;
}

.tc-reason-num {
    width: 40px;
    height: 40px;
    background: var(--main-color-1);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 600;
}

.tc-reason-card h3 {
    grid-column: 2;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    line-height: 1.5;
    margin: 0;
}

/* Span the full width so the text isn't indented by the number column */
.tc-reason-card p {
    grid-column: 1 / -1;
    font-size: 15px;
    color: #666;
    line-height: 1.7;
    margin: 0;
}

/* Supported operations */
.tc-ops {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.tc-op-card {
    background: #fafafa;
    border-radius: 12px;
    padding: 24px 20px;
    text-align: center;
    /* Offset so the sticky header doesn't cover the card when jumped to */
    scroll-margin-top: 100px;
}

.tc-op-img {
    display: block;
    width: 42px;
    height: 42px;
    margin: 0 auto 8px;
    opacity: 1;
}

.tc-op-card h3 {
    font-size: 17px;
    font-weight: 600;
    color: #333;
    line-height: 1.5;
    margin: 0 0 8px;
}

.tc-op-card p {
    font-size: 14px;
    color: #666;
    line-height: 1.7;
    margin: 0;
    text-align: left;
}

.tc-ops-note {
    text-align: center;
    font-size: 15px;
    color: #333;
    margin: 32px 0 0;
}

/* CTA: reuses the global .btn.btn-wide button (same as the AI Omakase Plan page) */
.tc-cta {
    text-align: center;
    margin-top: 32px;
}

/* Q&A */
.faq-section {
    max-width: 960px;
    margin: 0 auto;
}

.faq-list {
    background: #FAFAFA;
    border-radius: 12px;
    padding: 24px 32px;
}

.faq-item {
    margin-bottom: 16px;
}

.faq-item:last-child {
    margin-bottom: 0;
}

.faq-question {
    display: flex;
    align-items: center;
    gap: 16px;
    cursor: pointer;
}

.faq-icon {
    flex-shrink: 0;
    width: 39px;
    padding: 4px 10px;
    background: var(--main-color-1);
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.faq-question h3 {
    flex: 1;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.faq-toggle {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    display: inline-block;
    transition: transform 0.3s ease;
}

.faq-item.is-open .faq-toggle {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    padding: 0 16px;
    background: #fff;
    border-radius: 6px;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s ease-out, opacity 0.4s ease-out, padding 0.4s ease-out, margin-top 0.4s ease-out;
}

.faq-item.is-open .faq-answer {
    max-height: 1000px;
    margin-top: 16px;
    padding: 16px;
    opacity: 1;
}

.faq-answer p {
    font-size: 16px;
    color: #333;
    line-height: 1.6;
    margin: 0 0 1.5em;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

/* ==========================================
   Responsive
   ========================================== */

/* PC (>= 960px): lay the 14 tags out as an even 7 × 2 grid */
@media screen and (min-width: 960px) {
    .tc-tags {
        display: grid;
        grid-template-columns: repeat(7, minmax(0, 1fr));
        justify-content: center;
        column-gap: 6px;
        row-gap: 8px;
    }

    .tc-tags li {
        justify-content: center;
        width: 100%;
    }

    .tc-tags a {
        width: 100%;
        padding: 8px 6px 8px 1px;
        gap: 2px;
        font-size: 12px;
    }

    .tc-tags .tc-tag-icon {
        width: 14px;
        height: 14px;
    }

    .tc-tags a::after {
        display: none;
    }
}

/* Tablet (<= 959px) */
@media screen and (max-width: 959px) {
    .tc-page {
        padding: 75px 0;
    }

    /* Tighten the big desktop vertical rhythm */
    .tc-section {
        margin: 64px auto;
    }

    .tc-br-sp {
        display: block;
    }

    .tc-tags {
        gap: 12px 24px;
        padding: 18px 16px;
    }

    .tc-ops {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Q&A */
    .faq-list {
        padding: 24px 16px;
    }

    .faq-question {
        gap: 8px;
    }

    .faq-icon {
        font-size: 16px;
    }

    .faq-question h3 {
        font-size: 14px;
    }

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

/* Smartphone (<= 767px) */
@media screen and (max-width: 767px) {
    .tc-section {
        margin: 48px auto;
    }

    .section-title {
        font-size: 19px;
    }

    /* Smartphone: lay the tags out as an even 3-per-row grid */
    .tc-tags {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 8px;
        max-width: 100%;
        padding: 12px 8px;
    }

    .tc-tags li {
        width: 100%;
    }

    .tc-tags a {
        width: 100%;
        min-height: 40px;
        padding: 6px 6px;
        gap: 4px;
        font-size: 12px;
        line-height: 1.25;
        text-align: center;
        white-space: normal;
        word-break: keep-all;
    }

    .tc-tags a::after {
        display: none;
    }

    .tc-tag-icon {
        width: 16px;
        height: 16px;
    }

    .tc-flow {
        flex-direction: column;
        gap: 12px;
    }

    .tc-flow-arrow {
        display: none;
    }

    .tc-reasons {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .tc-reason-card {
        padding: 20px 16px;
    }

    .tc-reason-card h3 {
        font-size: 16px;
    }

    .tc-ops {
        grid-template-columns: 1fr;
        gap: 12px;
    }
}

/* Small phones (<= 480px) — prevent the nav links and headings from cramping */
@media screen and (max-width: 480px) {
    .tc-section {
        margin: 40px auto;
    }

    .tc-tags {
        gap: 6px;
        padding: 12px 6px;
    }

    .tc-tags a {
        gap: 3px;
        padding: 7px 4px;
        font-size: 11px;
    }

    .tc-tag-icon {
        width: 15px;
        height: 15px;
    }

    .tc-op-card {
        padding: 20px 16px;
    }

    .faq-list {
        padding: 20px 12px;
    }
}

/* ==========================================
   Accessibility
   ========================================== */

/* Visible keyboard focus for the interactive elements */
.tc-tags a:focus-visible,
.faq-question:focus-visible {
    outline: 2px solid var(--main-color-1);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .tc-tags a,
    .faq-toggle,
    .faq-answer {
        transition: none;
    }

    .fade-in-up .tc-highlight {
        background-size: 100% 100%;
        transition: none;
    }
}


/* ============================================================
   Enterprise restyle, matching the top, pricing and features pages.
   This file is only loaded when %{CCD}/eq/real-device-test-center, so no
   scoping is needed. Kept at the end of the file to override the rules above.
   Green drops from base colour to accent and is kept for the CTA only.
   ============================================================ */

.tc-page h1,
.tc-page h2,
.tc-page h3 {
    color: #2a3037;
}

/* Cards: the blue-grey surface and 8px radius used across the site,
   replacing the warm #FAFAFA and 12px corners. */
.tc-flow-step,
.tc-op-card,
.faq-list {
    background: #f8f8fc;
    border-radius: 8px;
}

/* This card draws its surface with a thick border rather than a fill. */
.tc-reason-card {
    border: 6px solid #f8f8fc;
    border-radius: 8px;
}

/* Numbered badges. Green now means "act", so decorative numbers go
   near-black like the top page section labels. */
.tc-reason-num,
.tc-flow-num {
    background: #2a3037;
}

/* Q&A. The Q badge was green; the rest matches the pricing page Q&A. */
.faq-icon {
    background: #2a3037;
    /* Q has a descender and sits low, so the padding is flipped to offset it */
    padding: 3px 10px 5px;
}

.faq-question h3 {
    color: #2a3037;
}

.faq-answer {
    border-radius: 3px;
}

/* Primary CTA, matching the top page CTA band button
   (a.btn-common.btn-common202512): flat green, 3px radius, 17px/600 and a white
   arrow circle. The markup here is a plain <a class="btn"> with no .allow-box
   element, so the circle is drawn with ::after. */
.tc-page a.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 57px;
    padding: 15px 65px 15px 40px;
    border-radius: 3px;
    font-size: 17px;
    font-weight: 600;
    line-height: 1.4;
    box-shadow: none;
}

.tc-page a.btn::after {
    content: "\f061";
    /* font shorthand resets font-size, so the size is set after it */
    font: var(--fa-font-solid);
    font-size: 17px;
    color: var(--main-color-d1);
    background: #fff;
    width: 35px;
    height: 35px;
    border-radius: 99px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    transition: transform .3s;
}

@media (any-hover:hover) {
    .tc-page a.btn:hover::after {
        transform: translateY(-50%) translateX(4px);
    }
}


/* Supported-operations icons. Green read as loud as the CTA, so they are
   desaturated like the top page illustrations and dropped back slightly. */
.tc-op-img {
    filter: grayscale(1);
    opacity: .75;
}

/* In-page tag nav. Green reads as "act" now, so the chips move onto the same
   blue-grey surface as the cards and the icons lose their colour with them. */
.tc-tags a {
    color: #2a3037;
    background: #fff;
}

.tc-tags a:hover {
    background: #edeef4;
}

.tc-tag-icon {
    filter: grayscale(1);
}

/* Only the stroke colour changes; no-repeat, centring and sizing stay with the
   base rule, so this sets background-image rather than the shorthand. */
.tc-tags a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M6 9l6 6 6-6' stroke='%232a3037' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* Connector between the flow steps: the site's border grey, so it reads as a
   divider rather than an accent. */
.tc-flow-arrow {
    border-left-color: #d5d5dc;
}


/* 100vw includes the classic scrollbar, so the full-bleed band below would overflow
   by its width. Clip rather than hide: clip does not make these a scroll container,
   so sticky and fixed descendants still behave. Scoped to this page. */
html:has(body.real-device-test-center__body),
body.real-device-test-center__body {
    overflow-x: clip;
}

.tc-hero-visual {
    box-sizing: border-box;
    width: 100vw;
    margin-inline: calc(50% - 50vw);
    margin-top: 24px;
}

.tc-hero-img {
    display: block;
    width: 100%;
    max-width: 980px;
    height: auto;
    margin: 0 auto;
    animation: tc-hero-in 0.6s ease-out both;
}

@keyframes tc-hero-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .tc-hero-img {
        animation: none;
    }
}

@media screen and (max-width: 767px) {
    .tc-hero-img {
        max-width: 100%;
    }
}
