/*
 * CartonsPro public-page harmonization.
 * Extends the homepage and professional-offer visual language without changing
 * any catalogue, estimator, delivery, or authentication behaviour.
 */
:root {
    --cp2-navy: #102d50;
    --cp2-navy-deep: #08264f;
    --cp2-red: #e41414;
    --cp2-red-dark: #bd1010;
    --cp2-orange: #f45b22;
    --cp2-ink: #18304d;
    --cp2-muted: #617386;
    --cp2-soft: #f4f7fa;
    --cp2-line: #dce3ea;
    --cp2-radius: 14px;
    --cp2-shadow: 0 12px 30px rgba(16, 45, 80, .08);
}

.page-harmonized {
    background: #fff;
}

.page-harmonized .eyebrow {
    color: var(--cp2-red);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .11em;
    text-transform: uppercase;
}

.page-harmonized h1,
.page-harmonized h2,
.page-harmonized h3 {
    color: var(--cp2-navy);
    letter-spacing: -.035em;
}

.page-harmonized .btn {
    min-height: 46px;
    border-radius: 7px;
    box-shadow: none;
}

.page-harmonized .btn-primary {
    border-color: var(--cp2-red);
    background: var(--cp2-red);
}

.page-harmonized .btn-primary:hover {
    border-color: var(--cp2-red-dark);
    background: var(--cp2-red-dark);
}

.page-harmonized .btn-secondary,
.page-harmonized .btn-ghost {
    border-color: #cbd6e1;
    color: var(--cp2-navy);
    background: #fff;
}

.page-harmonized :is(a, button, input, summary):focus-visible {
    outline: 3px solid rgba(228, 20, 20, .34);
    outline-offset: 3px;
}

/* Shared compact editorial hero: the red rail references a shipping label. */
.content-hub,
.seo-content-page,
.estimator-shell {
    width: min(1200px, calc(100% - 48px));
}

.content-hub {
    padding: 32px 0 64px;
}

.content-hub-hero,
.seo-content-hero,
.estimator-header {
    position: relative;
    overflow: hidden;
    border: 0;
    border-radius: var(--cp2-radius);
    color: #fff;
    background:
        linear-gradient(100deg, rgba(8, 38, 79, .99), rgba(16, 45, 80, .94) 68%, rgba(22, 70, 112, .9)),
        url('../images/kartoon/hero-logistique-france.webp') center 56% / cover;
    box-shadow: none;
}

.content-hub-hero::before,
.seo-content-hero::before,
.estimator-header::before {
    position: absolute;
    inset: 0 auto 0 0;
    width: 6px;
    background: var(--cp2-red);
    content: "";
}

.content-hub-hero::after,
.seo-content-hero::after,
.estimator-header::after {
    position: absolute;
    inset: auto 26px 22px auto;
    width: 82px;
    height: 10px;
    border-block: 2px solid rgba(255, 255, 255, .24);
    border-radius: 0;
    content: "";
}

.content-hub-hero {
    min-height: 270px;
    display: grid;
    align-content: center;
    padding: 42px 48px;
}

.content-hub-hero h1,
.seo-content-hero h1,
.estimator-header h1 {
    position: relative;
    z-index: 1;
    max-width: 820px;
    margin: 8px 0 14px;
    color: #fff;
    font-size: clamp(2.3rem, 4.2vw, 3.75rem);
    line-height: 1.01;
    letter-spacing: -.052em;
}

.content-hub-hero > p:last-child,
.seo-content-hero > div > p:last-child,
.estimator-header > div > p:last-child {
    position: relative;
    z-index: 1;
    max-width: 700px;
    margin: 0;
    color: rgba(255, 255, 255, .78);
    font-size: 15px;
    line-height: 1.6;
}

.content-hub-hero .eyebrow,
.seo-content-hero .eyebrow,
.estimator-header .eyebrow {
    position: relative;
    z-index: 1;
    color: #ff8c8c;
}

/* Guides and FAQ */
.guides-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 30px;
    margin-top: 34px;
    border-top: 1px solid var(--cp2-line);
}

.guide-card {
    position: relative;
    gap: 16px;
    min-height: 170px;
    padding: 25px 0;
    border: 0;
    border-bottom: 1px solid var(--cp2-line);
    border-radius: 0;
    box-shadow: none;
}

.guide-card > span {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: var(--cp2-red);
    font-size: 11px;
    letter-spacing: 0;
}

.guide-card h2 {
    font-size: 21px;
}

.guide-card p {
    margin-top: 8px;
    color: var(--cp2-muted);
    font-size: 14px;
}

.guide-card a:last-child {
    color: var(--cp2-navy);
    font-size: 13px;
}

.guide-card:hover h2 a,
.guide-card:focus-within h2 a {
    color: var(--cp2-red);
}

.guides-estimator-cta {
    margin-top: 30px;
    padding: 27px 30px;
    border: 1px solid #dbe4ed;
    border-radius: var(--cp2-radius);
    background: var(--cp2-soft);
}

.content-hub-layout {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 48px;
    margin-top: 34px;
}

.faq-list {
    border-top-color: var(--cp2-line);
}

.faq-item {
    border-bottom-color: var(--cp2-line);
}

.faq-item summary {
    min-height: 64px;
    padding: 17px 0;
    color: var(--cp2-navy);
    font-size: 16px;
}

.faq-item summary span {
    border: 1px solid #d8e1ea;
    background: #fff;
}

.faq-item summary span::before,
.faq-item summary span::after {
    background: var(--cp2-red);
}

.faq-answer {
    color: var(--cp2-muted);
    font-size: 14px;
}

.content-help-card {
    top: 154px;
    padding: 25px;
    border: 0;
    border-radius: var(--cp2-radius);
    color: #fff;
    background: var(--cp2-navy);
    box-shadow: none;
}

.content-help-card h2,
.content-help-card p,
.content-help-card > a:last-child {
    color: #fff;
}

.content-help-card p {
    color: rgba(255, 255, 255, .72);
    font-size: 14px;
}

.content-help-card .eyebrow {
    color: #ff8c8c;
}

/* Delivery and other SEO content pages */
.seo-content-page {
    padding: 24px 0 64px;
}

.seo-content-hero {
    grid-template-columns: minmax(0, 1fr) 290px;
    gap: 40px;
    min-height: 310px;
    padding: 42px 48px;
}

.seo-content-hero aside {
    position: relative;
    z-index: 1;
    padding: 22px;
    border-color: rgba(255, 255, 255, .2);
    border-radius: 10px;
    background: rgba(255, 255, 255, .1);
    backdrop-filter: blur(8px);
}

.seo-content-body {
    max-width: 900px;
    margin-top: 36px;
}

.guide-content-section {
    padding-block: 27px;
    border-bottom: 1px solid var(--cp2-line);
}

.guide-content-section h2 {
    font-size: clamp(1.55rem, 2.4vw, 2rem);
}

.seo-content-products,
.seo-content-faq {
    margin-top: 46px;
}

.seo-content-links a {
    border-radius: 7px;
}

/* Estimator */
.estimator-v2 {
    max-width: 1100px;
    padding-top: 24px;
}

.estimator-back {
    margin-bottom: 18px;
    color: var(--cp2-navy);
    font-size: 13px;
}

.estimator-header {
    min-height: 250px;
    align-items: center;
    margin-bottom: 18px;
    padding: 38px 44px;
}

.estimator-header > span {
    position: relative;
    z-index: 1;
    border: 1px solid rgba(255, 255, 255, .22);
    color: #fff;
    background: rgba(255, 255, 255, .1);
}

.estimator-flow,
.estimator-result {
    border-color: var(--cp2-line);
    border-radius: var(--cp2-radius);
    box-shadow: var(--cp2-shadow);
}

.estimator-flow {
    padding: clamp(24px, 4vw, 38px);
}

.estimator-progress > div {
    height: 5px;
}

.estimator-progress > div > span {
    background: linear-gradient(90deg, var(--cp2-navy), var(--cp2-red));
}

.estimator-housing-options label,
.estimator-content-questions > div {
    border-radius: 9px;
    background: #fff;
}

.estimator-housing-options label:has(input:checked) {
    border-color: var(--cp2-navy);
    background: #f0f4f8;
    box-shadow: inset 5px 0 0 var(--cp2-red);
}

.estimator-result-summary {
    background: var(--cp2-navy);
}

.estimator-selection {
    border-radius: 10px;
}

/* Authentication pages follow the professional-offer composition. */
.pro-register-shell,
.pro-login-shell {
    width: min(1200px, calc(100% - 48px));
    margin: 28px auto 60px;
    gap: 0;
    overflow: hidden;
    border: 1px solid var(--cp2-line);
    border-radius: var(--cp2-radius);
    background: #fff;
    box-shadow: var(--cp2-shadow);
}

.pro-register-shell {
    grid-template-columns: minmax(310px, .78fr) minmax(0, 1.22fr);
}

.pro-register-aside,
.pro-register-form,
.pro-login-benefits,
.pro-login-panel {
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.pro-register-aside {
    min-height: 100%;
    padding: 42px 36px;
    background:
        linear-gradient(180deg, rgba(8, 38, 79, .3), rgba(8, 38, 79, .96)),
        url('../images/kartoon/hero-logistique-france.webp') center / cover;
}

.pro-register-aside::before {
    display: none;
}

.pro-register-aside h1,
.pro-login-benefits h1 {
    color: #fff;
    font-size: clamp(2.25rem, 3.3vw, 3.4rem);
    line-height: 1;
    letter-spacing: -.052em;
}

.pro-proof-grid {
    grid-template-columns: 1fr;
    gap: 7px;
    margin-top: 8px;
}

.pro-proof-grid span {
    min-height: 42px;
    place-items: center start;
    padding-inline: 13px;
    border-radius: 7px;
    font-size: 12px;
}

.pro-proof-grid span::before {
    margin-right: 8px;
    color: #ff8c8c;
    content: "✓";
}

.pro-register-form {
    padding: 34px;
    background: #fff;
}

.form-section {
    gap: 13px;
    padding: 20px 0;
    border: 0;
    border-bottom: 1px solid var(--cp2-line);
    border-radius: 0;
    background: transparent;
}

.form-section:hover {
    border-color: var(--cp2-line);
    box-shadow: none;
    transform: none;
}

.form-section h3 {
    color: var(--cp2-navy);
}

.pro-register-form input,
.pro-login-panel input:not([type='checkbox']) {
    border-radius: 7px;
    background: #fbfcfd;
}

.pro-login-shell {
    grid-template-columns: minmax(0, 1.08fr) minmax(360px, .72fr);
    max-width: 1080px;
}

.pro-login-benefits {
    min-height: 500px;
    padding: 42px;
    background:
        linear-gradient(125deg, rgba(8, 38, 79, .98), rgba(16, 45, 80, .9)),
        url('../images/kartoon/hero-logistique-france.webp') center / cover;
}

.pro-login-benefit-list article {
    border-radius: 7px;
}

.pro-login-benefit-list article > b {
    color: #ff8c8c;
}

.pro-login-panel {
    padding: 38px;
}

/* Boutique cards: compact and aligned to a common height within each row. */
.page-shop .product-grid {
    align-items: stretch;
}

.page-shop .product-card-decision,
.page-shop .product-grid-particular .product-card-decision {
    grid-template-rows: 170px auto auto auto;
    height: 100%;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 7px 20px rgba(16, 45, 80, .07);
}

.page-shop .product-card-decision .product-media,
.page-shop .product-grid-particular .product-card-decision .product-media {
    box-sizing: border-box;
    height: 170px;
    min-height: 170px;
    padding: 10px;
}

.page-shop .product-card-decision .product-media img {
    padding: 0;
}

.page-shop .product-card-heading {
    gap: 6px;
    padding: 14px 14px 10px;
}

.page-shop .product-card-heading .product-meta {
    min-height: 24px;
}

.page-shop .product-card-heading h2,
.page-shop .product-grid-particular .product-card-heading h2 {
    display: -webkit-box;
    overflow: hidden;
    font-size: 1rem;
    line-height: 1.25;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.page-shop .product-card-dimensions {
    margin-top: 3px;
    font-size: 12px;
}

.page-shop .product-card-decision .product-body,
.page-shop .product-grid-particular .product-card-decision .product-body {
    gap: 9px;
    padding: 10px 14px 12px;
}

.page-shop .product-card-decision .product-ideal-for p {
    display: -webkit-box;
    overflow: hidden;
    font-size: 12px;
    line-height: 1.4;
    -webkit-box-orient: vertical;
    text-overflow: ellipsis;
    white-space: normal;
    -webkit-line-clamp: 2;
}

.page-shop .product-characteristics {
    max-height: 27px;
    overflow: hidden;
    gap: 5px;
}

.page-shop .product-characteristics li {
    padding: 5px 7px;
    font-size: 10px;
}

.page-shop .product-card-kit-contents {
    padding: 10px;
}

.page-shop .product-card-kit-contents li:nth-child(n + 3) {
    display: none;
}

.page-shop .product-card-decision .product-price-row strong,
.page-shop .product-grid-particular .product-card-decision .product-price-row strong {
    font-size: 1.3rem;
}

.page-shop .product-card-purchase,
.page-shop .product-grid-particular .product-card-purchase {
    min-height: 0;
    gap: 7px;
    padding: 0 14px 14px;
}

.page-shop .product-card-purchase-controls {
    grid-template-columns: 108px minmax(0, 1fr);
    gap: 7px;
}

.page-shop .product-card-purchase-controls .btn,
.page-shop .product-grid-particular .product-card .product-card-purchase-controls > .btn {
    height: 41px;
    min-height: 41px;
    padding-inline: 9px;
    font-size: 11px;
}

@media (max-width: 900px) {
    .content-hub-layout {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .content-help-card {
        position: static;
    }

    .pro-register-shell,
    .pro-login-shell {
        grid-template-columns: 1fr;
    }

    .pro-register-form,
    .pro-login-panel {
        grid-row: 1;
    }

    .pro-register-aside,
    .pro-login-benefits {
        grid-row: 2;
        min-height: 0;
        padding: 28px;
    }

    .pro-register-aside h1,
    .pro-login-benefits h1 {
        font-size: 2rem;
    }

    .pro-login-benefit-list {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .pro-login-benefit-list article {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .content-hub,
    .seo-content-page,
    .estimator-shell,
    .pro-register-shell,
    .pro-login-shell {
        width: min(100% - 28px, 1200px);
    }

    .content-hub {
        padding-top: 18px;
    }

    .content-hub-hero,
    .seo-content-hero,
    .estimator-header {
        min-height: 0;
        padding: 30px 24px;
    }

    .content-hub-hero h1,
    .seo-content-hero h1,
    .estimator-header h1 {
        font-size: clamp(2rem, 9.5vw, 2.75rem);
    }

    .seo-content-hero {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .guides-grid {
        grid-template-columns: 1fr;
    }

    .guide-card {
        min-height: 0;
    }

    .guides-estimator-cta,
    .estimator-header,
    .estimator-result-summary {
        align-items: flex-start;
        flex-direction: column;
    }

    .estimator-header > span {
        margin-top: 18px;
    }

    .estimator-housing-options {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .pro-register-shell,
    .pro-login-shell {
        margin-top: 16px;
        margin-bottom: 40px;
    }

    .pro-register-form,
    .pro-login-panel {
        padding: 24px 20px;
    }

    .pro-login-benefit-list {
        grid-template-columns: 1fr;
    }

    .pro-register-aside > p:not(.eyebrow),
    .pro-login-benefits > p:not(.eyebrow) {
        font-size: 13px;
    }

    .page-shop .product-card-decision,
    .page-shop .product-grid-particular .product-card-decision {
        grid-template-rows: 160px auto auto auto;
    }

    .page-shop .product-card-decision .product-media,
    .page-shop .product-grid-particular .product-card-decision .product-media {
        height: 160px;
        min-height: 160px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .page-harmonized *,
    .page-shop .product-card {
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
    }
}
