/* ══════════════════════════════════════════════════════════════════════════
   Flamingo Collections — Frontend Styles
══════════════════════════════════════════════════════════════════════════ */

:root {
    --fc-pink:       #c9a9a0;
    --fc-dark:       #3a3330;
    --fc-mid:        #666e76;
    --fc-light-bg:   #f7f4f1;
    --fc-border:     #e0d9d4;
    --fc-text:       #555050;
    --fc-rust:       #a35c3d;
    --fc-navy:       #4a5872;
    --fc-max:        1425px;
    --fc-pad:        0px;
}

/* ── Reset within plugin scope ────────────────────────────────────────── */
.flamingo-single *, .flamingo-archive * { box-sizing: border-box; }
.flamingo-single img { display: block; max-width: 100%; }

/* ══ ARCHIVE GRID ════════════════════════════════════════════════════════ */
.flamingo-archive {
    max-width: var(--fc-max);
    margin: 0 auto;
    padding: 60px var(--fc-pad);
}
.flamingo-archive__heading {
    font-size: 2rem;
    color: var(--fc-dark);
    margin: 0 0 8px;
}
.flamingo-archive__sub {
    font-size: 18px;
    color: var(--fc-text);
    margin: 0 0 48px;
    max-width: 580px;
    line-height: 1.6;
}

.flamingo-grid {
    display: grid;
    gap: 28px;
}
.flamingo-grid--3col { grid-template-columns: repeat(3, 1fr); }
.flamingo-grid--2col { grid-template-columns: repeat(2, 1fr); }
.flamingo-grid--4col { grid-template-columns: repeat(4, 1fr); }

.flamingo-grid__item {
    display: block;
    text-decoration: none;
    color: inherit;
}
.flamingo-grid__img {
    width: 100%;
    height: 0;
    padding-bottom: 66.67%; /* fallback 3:2 ratio if no inline ratio is passed */
    position: relative;
    overflow: hidden;
    border-radius: 10px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transition: opacity .25s;
}
.flamingo-grid__item:hover .flamingo-grid__img { opacity: .88; }
.flamingo-grid__title {
    display: block;
    margin-top: 14px;
    font-size: 1rem;
    color: var(--fc-mid);
    font-weight: 500;
    letter-spacing: .01em;
}

/* ══ SINGLE PAGE ═════════════════════════════════════════════════════════ */
.flamingo-single {
    color: var(--fc-text);
    font-size: 18px;
    line-height: 1.65;
}

/* ── 1. Hero ─────────────────────────────────────────────────────────── */
.fc-hero-wrap {
    max-width: var(--fc-max);
    margin: 0 auto;
    padding: 0 var(--fc-pad);
}
.fc-hero {
    width: 100%;
    overflow: hidden;
    border-radius: 16px;
}
.fc-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.fc-hero--auto img {
    height: auto;
    object-fit: initial;
}

/* ── 2. Info Section ─────────────────────────────────────────────────── */
/* All direct children (title+desc, trust icons, swatches, actions) are inset
   from the left by ~25% of the container and stay flush with the container's
   right edge — matching the PDF mockup. Collapses to full width on mobile
   via the media query below. */
.fc-info {
    max-width: var(--fc-max);
    margin: 0 auto;
    padding: 52px var(--fc-pad) 0;
    display: grid;
    grid-template-columns: 1fr 3fr;
}
.fc-info > * {
    grid-column: 2;
}

.fc-info__inner {
    margin-bottom: 32px;
}

.fc-title {
    font-size: 3rem;
    font-weight: 400;
    color: var(--fc-navy);
    margin: 0 0 16px;
    line-height: 1.15;
    font-family: "minerva-modern", sans-serif;
}
.fc-desc {
    font-size: 18px;
    color: var(--fc-text);
    line-height: 1.75;
    max-width: 100%;
}
.fc-desc p {
    margin: 0;
    color: var(--fc-mid);
}

/* Trust icons — single horizontal row, large icons */
.fc-trust {
    display: flex;
    flex-wrap: wrap;
    gap: 56px;
    padding: 28px 0 24px;
    border-bottom: 1px solid #909090;
    margin-bottom: 0;
}
.fc-trust__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    font-size: 14px;
    color: var(--fc-mid);
    line-height: 1.35;
    min-width: 80px;
    max-width: 140px;
}
.fc-trust__item img {
    width: 100%;
    height: 64px;
    object-fit: contain;
}

/* Colour swatches */
.fc-swatches {
    padding: 24px 0 20px;
    border-bottom: 1px solid #909090;
}
.fc-swatches__label {
    font-family: "minerva-modern", sans-serif;
    font-style: normal;
    font-size: 20px;
    font-weight: 400;
    color: var(--fc-navy);
    margin: 0 0 18px;
    padding: 0;
    letter-spacing: .01em;
}
.fc-swatches__row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px 28px;
    align-items: flex-start;
}
.fc-swatch {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}
.fc-swatch__dot {
    display: block;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,.6);
    box-shadow: 0 0 0 1px rgba(0,0,0,.12), inset 0 1px 3px rgba(255,255,255,.3);
    background-color: var(--fc-light-bg);
    background-size: auto;
    background-position: center;
    background-repeat: no-repeat;
}
.fc-swatch__name {
    font-size: 16px;
    color: var(-fc-navy);
    text-align: center;
    max-width: 140px;
    line-height: 1.3;
    font-style: normal;
    font-family: 'League Spartan';
    font-weight: 400;
}

/* Download + contact links */
.fc-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0;
    padding: 16px 0 20px;
    border-bottom: 1px solid #909090;
}
.fc-action-link {
    font-size: 20px;
    color: #404a54;
    text-decoration: none;
    transition: opacity .2s;
    white-space: nowrap;
    padding: 4px 0;
}
.fc-action-link:hover { opacity: .7; }
.fc-action-sep {
    display: inline-block;
    padding: 0 24px;
    color: #909090;
    font-size: 1rem;
    user-select: none;
}

/* ── 3. Items Slider ─────────────────────────────────────────────────── */
.fc-items-section {
    background: #f4f6f5;
    padding: 100px 0 40px;
    margin-top: 36px;
}
.fc-items-section__head {
    max-width: var(--fc-max);
    margin: 0 auto 28px;
    padding: 0 var(--fc-pad);
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}
.fc-items-section__title {
    font-family: "minerva-modern", sans-serif;
    font-size: 2.5rem;
    font-weight: 400;
    color: var(--fc-navy);
    margin: 0 0 12px;
}
.fc-items-section__sub {
    font-size: 18px;
    color: var(--fc-mid);
    margin: 0;
}

/* Nav buttons (top-right arrow style like PDF) */
.fc-items-nav,
.fc-related-nav {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
    margin-top: 4px;
}
.fc-nav-btn.fc-nav-btn.fc-nav-btn {
    border-radius: 50% !important;
}
.fc-nav-btn {
    width: 44px;
    height: 44px;
    border: 1px solid #c2c2c2;
    background: transparent;
    color: #a3a3a3;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s, color .2s, border-color .2s;
    line-height: 1;
}
.fc-nav-btn svg {
    width: 36px;
    height: 36px;
    display: block;
}
.fc-nav-btn:hover {
    background: var(--fc-dark);
    color: #fff;
    border-color: var(--fc-dark);
}

/* Slider overflow wrapper — full-bleed to the right edge of the screen,
   left edge stays aligned with the section heading above it */
.fc-items-slider,
.fc-related-slider {
    overflow: hidden;
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: 0;
    padding-left: max(var(--fc-pad), calc((100vw - var(--fc-max)) / 2 + var(--fc-pad)));
    padding-right: 0;
}

/* Item slide card */
.fc-item-slide {
    background: transparent;
    overflow: visible;
}
.fc-item-slide__img {
    border-radius: 16px;
    overflow: hidden;
}
.fc-item-slide__img img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}
.fc-item-slide__body {
    padding: 22px 0 0;
}
.fc-item-slide__title {
    font-family: 'League Spartan' !important;
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--fc-mid);
    margin: 0 0 24px;
}
.fc-item-slide__desc {
    font-size: 18px;
    color: var(--fc-text);
    line-height: 1.65;
    margin: 0;
    max-width: 32em;
}

/* ── 4. Related Collections Slider ──────────────────────────────────── */
.fc-related-section {
    padding: 100px 0 0;
    background: #fff;
}
.fc-related-section__head {
    max-width: var(--fc-max);
    margin: 0 auto 28px;
    padding: 0 var(--fc-pad);
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
}
.fc-related-section__title {
    font-family: "minerva-modern", sans-serif;
    font-size: 2.5rem;
    font-weight: 400;
    color: var(--fc-navy);
    margin: 0 0 12px;
}
.fc-related-section__sub {
    font-size: 18px;
    color: var(--fc-mid);
    max-width: 820px;
    line-height: 1.2;
    margin: 0;
}

/* Related slide — text left, full-height image right */
.fc-related-slide {
    display: flex;
    align-items: stretch;
    background: #f5f6f7;
    border-radius: 16px;
    overflow: hidden;
    min-height: 480px;
}
.fc-related-slide__body {
    order: 1;
    flex: 0 0 28%;
    max-width: 28%;
    padding: 28px 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;
    align-items: flex-start;
}
.fc-related-slide__img {
    order: 2;
    flex: 1 1 72%;
    position: relative;
    overflow: hidden;
    display: block;
}
.fc-related-slide__img img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.fc-related-slide__title {
    font-family: "minerva-modern", sans-serif;
    font-size: 2rem;
    font-weight: 400;
    color: var(--fc-navy);
    margin: 0 0 24px;
    line-height: 1;
}
.fc-related-slide__title-link {
    color: inherit;
    text-decoration: none;
}
.fc-related-slide__title-link:hover {
    color: var(--fc-rust);
}
.fc-related-slide__desc {
    font-size: 18px;
    color: var(--fc-navy);
    line-height: 1.3;
    margin: 0 0 24px;
}
.fc-see-collection {
    display: inline-flex;
    font-family: "minerva-modern", sans-serif;
    align-items: center;
    gap: 6px;
    font-size: 16px;
    color: var(--fc-navy);
    text-decoration: none;
    font-weight: 400;
    padding-bottom: 1px;
    align-self: flex-start;
    transition: color .2s, border-color .2s;
}
.fc-see-collection:hover {
    color: var(--fc-dark);
    border-color: var(--fc-dark);
}
.fc-arrow { font-size: 1em; }

@media (max-width: 700px) {
    .fc-related-slide { flex-direction: column; min-height: 0; }
    .fc-related-slide__body { flex: none; max-width: 100%; padding: 22px 20px; }
    .fc-related-slide__img { aspect-ratio: 4 / 3; }
    .fc-related-slide__img img { position: static; }
}

/* ══ RESPONSIVE ══════════════════════════════════════════════════════════ */
@media (max-width: 1440px) {
    :root { --fc-max: 1100px; }
}
@media (max-width: 960px) {
    :root { --fc-pad: 24px; }
    .fc-info { grid-template-columns: 1fr; }
    .fc-info > * { grid-column: 1; }
    .fc-trust { grid-template-columns: repeat(4, auto); justify-content: start; }
    .flamingo-grid--3col { grid-template-columns: repeat(2, 1fr); }
    .flamingo-grid--4col { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    :root { --fc-pad: 20px; }
    .fc-hero:not(.fc-hero--auto) img { height: 260px; }
    .fc-title { font-size: 1.35rem; }
    .fc-trust { grid-template-columns: repeat(2, auto); }
    .fc-actions { flex-direction: column; align-items: flex-start; gap: 10px; }
    .fc-action-sep { display: none; }
    .flamingo-grid--3col,
    .flamingo-grid--2col { grid-template-columns: 1fr; }
    .fc-items-section__head,
    .fc-related-section__head { flex-direction: column; }
}

/* ══ ADMIN META BOX IMPROVEMENTS ════════════════════════════════════════ */
.flamingo-trust-row {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    padding: 8px;
    background: #f9f9f9;
    border: 1px solid #e5e5e5;
    border-radius: 3px;
    margin-bottom: 8px !important;
}
.flamingo-trust-row .flamingo-media-preview {
    border-radius: 3px;
    border: 1px solid #ddd;
}