.eyebrow {
    font-size:.7rem;
    font-weight:750;
    letter-spacing:.17em;
    color:#65758c;
    margin-bottom:12px
}
.portfolio-heading {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:24px
}
.portfolio-heading h1 {
    font-weight:750;
    letter-spacing:-.04em
}
.portfolio-stats {
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:16px;
    margin:28px 0
}
.portfolio-stats>div {
    padding:22px;
    background:#f4f7fb;
    border:1px solid #e5eaf0;
    border-radius:14px
}
.portfolio-stats strong {
    display:block;
    font-size:2rem;
    color:#183969
}
.portfolio-stats span {
    font-size:.85rem;
    color:#65758c
}
.portfolio-tabs {
    display:flex;
    gap:6px;
    flex-wrap:wrap;
    border-bottom:1px solid #e1e7ee;
    padding-bottom:10px
}
.portfolio-tabs a {
    padding:9px 16px;
    border-radius:8px;
    color:#4c5b70;
    text-decoration:none
}
.portfolio-tabs a[aria-current] {
    background:#173d73;
    color:white
}
.portfolio-help {
    background:#f8fafc;
    border-radius:10px;
    padding:14px 18px;
    color:#526174
}
.portfolio-help summary {
    cursor:pointer;
    font-weight:650
}
.portfolio-help p {
    margin:12px 0 0;
    font-size:.9rem
}
.portfolio-table th {
    font-size:.75rem;
    color:#6b7788;
    text-transform:uppercase;
    letter-spacing:.04em
}
.portfolio-table td {
    padding:16px 8px
}
.rule-badge {
    border-radius:6px;
    background:#eef0f3;
    color:#727c8b;
    padding:4px 10px
}
.rule-badge.yes {
    background:#e4f5eb;
    color:#237244
}
.management-thumb {
    width:58px;
    height:40px;
    object-fit:contain
}
.portfolio-edit {
    max-width:760px
}
.portfolio-edit label {
    display:block;
    font-weight:600;
    margin-bottom:8px
}
.portfolio-edit .form-check-input {
    display:block;
    margin-bottom:12px
}
.portfolio-edit #id_segments label {
    font-weight:400
}
.edit-image {
    max-width:240px;
    max-height:150px;
    object-fit:contain
}
.portfolio-dialog {
    width:min(760px,94vw);
    max-height:88vh;
    overflow:auto;
    border:0;
    border-radius:18px;
    padding:28px;
    box-shadow:0 20px 90px #13283b40
}
.portfolio-dialog::backdrop {
    background:#101e38a3;
    backdrop-filter:blur(3px)
}
.segment-showcase {
    padding:38px 0 24px;
    background:radial-gradient(ellipse at 85% 0,#eaf0fb,transparent 55%),#f9fbfd;
    overflow:hidden
}
.segment-heading h1 {
    font-size:clamp(2.4rem,5vw,4.4rem);
    letter-spacing:-.055em;
    line-height:1.05;
    color:#162f52
}
.segment-heading h1 span {
    color:#2462a5
}
.segment-heading p:not(.eyebrow) {
    color:#68788e
}
.segment-image {
    width:170px;
    height:100px;
    object-fit:contain
}
.showcase-caption {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    margin:20px 0
}
.showcase-caption p {
    font-size:.85rem;
    color:#6c7c90;
    margin:0
}
.showcase-caption p strong {
    color:#244469
}
.showcase-caption p span {
    margin:0 10px
}
.brand-wall {
    --brand-tile-width:192px;
    --brand-tile-height:168px;
    padding:4px 0 8px
}
.brand-grid {
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(150px,1fr));
    gap:16px
}
.brand-grid[hidden] {
    display:none
}
.brand-tile {
    display:flex;
    position:relative;
    flex-direction:column;
    justify-content:center;
    align-items:center;
    flex-shrink:0;
    width:192px;
    height:168px;
    padding:13px 22px;
    border:1px solid #e6ecf3;
    border-radius:12px;
    background:white;
    text-decoration:none;
    color:#17375e;
    box-shadow:0 3px 8px #183c6605;
    transition:transform .2s,box-shadow .2s
}
.brand-grid .brand-tile {
    width:100%
}
.brand-tile img {
    width:100%;
    height:105px;
    object-fit:contain;
    transition:transform .2s
}
.brand-wordmark {
    font-weight:800;
    font-size:1.05rem;
    text-align:center;
    line-height:1.1
}
.brand-tile-caption {
    position:absolute;
    bottom:3px;
    right:10px;
    left:10px;
    font-size:.6rem;
    color:#62758c;
    display:flex;
    justify-content:space-between;
    opacity:0;
    transition:opacity .2s
}
.brand-tile:hover,.brand-tile:focus-visible {
    transform:scale(1.06);
    box-shadow:0 5px 18px #17375e18;
    z-index:2
}
.brand-tile:hover img,.brand-tile:focus-visible img {
    transform:scale(1.07)
}
.brand-tile:hover .brand-tile-caption,.brand-tile:focus-visible .brand-tile-caption {
    opacity:1
}
.brand-tile:focus-visible {
    outline:3px solid #2c6ebb;
    outline-offset:2px
}
.marquee-row {
    height:184px;
    display:flex;
    align-items:center;
    overflow:hidden
}
.marquee-track {
    display:flex;
    width:max-content;
    animation:portfolio-drift linear infinite;
    will-change:transform
}
.marquee-group {
    display:flex;
    gap:16px;
    padding-right:16px;
    flex-shrink:0
}
.marquee-row:hover .marquee-track,.marquee-row:focus-within .marquee-track,.motion-paused .marquee-track {
    animation-play-state:paused
}
.showcase-hint {
    font-size:.8rem;
    color:#748398;
    margin:18px 0 0
}
.portfolio-empty {
    padding:65px 24px;
    text-align:center;
    background:#fff;
    border:1px solid #e4eaf2;
    border-radius:20px;
    margin:24px 0
}
.portfolio-empty>span {
    font-size:3rem;
    color:#2770b5
}
.portfolio-empty p {
    color:#6b7a8d
}
.brand-hero {
    display:grid;
    grid-template-columns:260px 1fr;
    gap:42px;
    align-items:center;
    padding:20px 0
}
.brand-logo-large {
    height:210px;
    display:flex;
    align-items:center;
    justify-content:center;
    background:#f7f9fc;
    border:1px solid #edf0f5;
    border-radius:22px;
    padding:32px
}
.brand-logo-large img {
    max-width:100%;
    max-height:100%;
    object-fit:contain
}
.brand-logo-large strong {
    font-size:1.8rem;
    overflow-wrap:anywhere
}
.brand-hero h1 {
    font-weight:750;
    letter-spacing:-.035em
}
.brand-description {
    color:#647185;
    max-width:720px
}
.brand-total {
    margin-top:24px;
    color:#425774
}
.brand-total strong {
    color:#1d5896
}
.segment-breakdown {
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(min(100%,420px),1fr));
    gap:24px;
    margin-top:24px
}
.segment-breakdown-card {
    border:1px solid #e2e9f2;
    border-radius:18px;
    padding:24px
}
.segment-breakdown-card h3 {
    font-size:1.3rem;
    margin:0
}
.segment-breakdown-card h3 a {
    color:#264d79;
    text-decoration:none
}
.sku-total {
    font-size:1.5rem;
    font-weight:750;
    white-space:nowrap
}
.sku-total small,.line-details strong small {
    font-size:.65rem;
    color:#8090a2;
    font-weight:400
}
.line-details {
    border-top:1px solid #edf0f4;
    margin-top:16px;
    padding-top:14px
}
.line-details summary {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
    cursor:pointer;
    font-size:.9rem
}
.line-details summary>span::before {
    content:'＋';
    margin-right:8px;
    color:#5781aa
}
.line-details[open] summary>span::before {
    content:'−'
}
.line-details ul {
    padding:8px 0 0 22px;
    margin:0;
    list-style:none
}
.line-details li {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:14px;
    font-size:.8rem;
    padding:10px 0;
    color:#69798d
}
.line-details li strong {
    white-space:nowrap
}
.taxonomy-thumb {
    width:30px;
    height:25px;
    object-fit:contain;
    margin-right:8px
}
@keyframes portfolio-drift {
    to {
        transform:translateX(-50%)
    }
}
@media(max-width:600px) {
    .portfolio-heading {
        align-items:flex-start;
        flex-direction:column;
        gap:14px
    }
    .portfolio-stats {
        gap:8px
    }
    .portfolio-stats>div {
        padding:12px
    }
    .portfolio-stats strong {
        font-size:1.4rem
    }
    .portfolio-stats span {
        font-size:.7rem
    }
    .segment-showcase {
        padding-top:24px
    }
    .segment-image {
        display:none
    }
    .brand-wall {
        --brand-tile-width:150px;
        --brand-tile-height:132px
    }
    .brand-tile {
        width:150px;
        height:132px;
        padding-inline:15px
    }
    .brand-tile img {
        height:80px
    }
    .marquee-row {
        height:148px
    }
    .showcase-caption {
        align-items:flex-start
    }
    .brand-hero {
        grid-template-columns:1fr;
        gap:22px
    }
    .brand-logo-large {
        height:160px
    }
    .segment-breakdown-card {
        padding:18px
    }
    .segment-breakdown-card .portfolio-heading {
        flex-direction:row
    }
    .portfolio-dialog {
        padding:20px
    }
}
@media(prefers-reduced-motion:reduce) {
    .marquee-track {
        animation:none
    }
    .brand-tile,.brand-tile img {
        transition:none
    }
}
.portfolio-updated-at {
    margin: 2rem 0 0;
    text-align: right;
    font-size: .7rem;
    color: rgba(54, 71, 94, .48);
}
