/*
 * Leverandørtrykk på produktsiden.
 *
 * Strukturen er to nivåer, ikke én lang liste: METODE først (fliser),
 * så UTFØRELSE (antall farger / trykkflate) under den valgte metoden.
 * Flatet man dem ut, ble ti radioknapper av det som egentlig er fire
 * valg — og kunden måtte lese hele lista for å finne fram.
 *
 * Fargene er per butikk (--brand settes i layouten), så filen er
 * merkevarenøytral.
 */

.si {
    --si-line: #e5e7eb;
    --si-muted: #6b7280;
    --si-ink: #111827;
    --si-surface: #f9fafb;
    --si-soft: color-mix(in srgb, var(--brand) 8%, white);
    --si-radius: .75rem;

    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f3f4f6;
}

/* ── Overskrift med valgt verdi til høyre ──────────────────────────── */

.si-label {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    margin: 0 0 .6rem;
    font-size: .92rem;
    font-weight: 700;
    color: var(--si-ink);
}

.si-label .si-value {
    font-weight: 600;
    font-size: .84rem;
    color: var(--si-muted);
}

/* ── Spesifikasjonen fra leverandøren ──────────────────────────────── */

.si-spec {
    display: flex;
    gap: .9rem;
    align-items: flex-start;
    padding: .75rem .9rem;
    margin-bottom: .75rem;
    background: var(--si-surface);
    border: 1px solid var(--si-line);
    border-radius: var(--si-radius);
}

.si-spec img {
    flex: 0 0 auto;
    width: 96px;
    height: 96px;
    object-fit: contain;
    background: #fff;
    border-radius: .375rem;
}

.si-spec dl {
    display: grid;
    gap: .25rem;
    margin: 0;
    min-width: 0;
    font-size: .84rem;
}

.si-spec dl > div { display: flex; gap: .5rem; }
.si-spec dt { flex: 0 0 auto; min-width: 108px; color: var(--si-muted); }
.si-spec dd { margin: 0; font-weight: 600; color: var(--si-ink); }

/* ── Metodefliser ──────────────────────────────────────────────────── */

.si-methods { display: flex; flex-wrap: wrap; gap: .55rem; }

.si-tile {
    flex: 1 1 140px;
    padding: .7rem .8rem;
    text-align: left;
    background: #fff;
    border: 2px solid var(--si-line);
    border-radius: var(--si-radius);
    cursor: pointer;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.si-tile:hover { border-color: var(--si-muted); }

.si-tile.active {
    border-color: var(--brand);
    box-shadow: 0 0 0 2px var(--si-soft);
}

.si-tile strong { display: block; font-size: .9rem; color: var(--si-ink); }
.si-tile small  { display: block; margin-top: .1rem; font-size: .76rem; color: var(--si-muted); }

/* ── Utførelse (antall farger / trykkflate) ────────────────────────── */

.si-variants { display: flex; flex-wrap: wrap; gap: .5rem; }

.si-chip {
    min-width: 46px;
    height: 42px;
    padding: 0 .8rem;
    font-size: .84rem;
    font-weight: 700;
    color: var(--si-ink);
    background: #fff;
    border: 2px solid var(--si-line);
    border-radius: var(--si-radius);
    cursor: pointer;
    transition: border-color .15s ease, color .15s ease;
}

.si-chip:hover { border-color: var(--si-muted); }
.si-chip.active { border-color: var(--brand); color: var(--brand); }

/* ── Filopplasting ─────────────────────────────────────────────────── */

.si-upload {
    margin-top: 1.1rem;
    padding: 1rem 1.1rem;
    background: var(--si-surface);
    border: 2px dashed var(--si-line);
    border-radius: var(--si-radius);
}

.si-upload:hover { border-color: var(--si-muted); }

.si-upload label {
    display: flex;
    align-items: center;
    gap: .55rem;
    font-size: .88rem;
    font-weight: 700;
    color: var(--si-ink);
    cursor: pointer;
}

.si-upload label svg { width: 20px; height: 20px; color: var(--brand); }
.si-upload input[type=file] { margin-top: .45rem; width: 100%; font-size: .84rem; }

.si-note {
    display: block;
    margin-top: .55rem;
    font-size: .78rem;
    color: var(--si-muted);
}

/* ── Prisboksen ────────────────────────────────────────────────────── */

.si-price {
    margin-top: .85rem;
    padding: .75rem .9rem;
    background: var(--si-soft);
    border-radius: var(--si-radius);
    font-size: .92rem;
    line-height: 1.55;
    color: var(--si-ink);
}

.si-price:empty { display: none; }
.si-price small { font-size: .78rem; color: var(--si-muted); }

/* ── Advarsel om minsteopplag ──────────────────────────────────────── */

.si-warning {
    margin-top: .625rem;
    padding: .625rem .8rem;
    background: #fff6e5;
    border: 1px solid #f0d9a8;
    border-radius: var(--si-radius);
    font-size: .84rem;
    color: #7a5300;
}

.si-contact {
    display: block;
    margin-top: .5rem;
    font-size: .78rem;
    color: var(--si-muted);
}

.si-contact a { color: var(--brand); text-decoration: underline; }

@media (max-width: 560px) {
    .si-spec { flex-direction: column; }
    .si-spec img { width: 100%; height: 140px; }
    .si-spec dt { min-width: 92px; }
}
