/* ===========================================================================
   ZS Grójec — style shortcode'ów (zamiennik Shortcode Ultimate)
   Odwzorowanie wyglądu z Joomli 3 po migracji na Joomlę 6.
   =========================================================================== */

/* --- Galeria w zakładkach: [tabs][tab][photo_panel] --- */
.zsg-sc-tabs {
    margin: 18px 0 26px;
}

.zsg-sc-tabs__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 2px;
    border-bottom: 2px solid #9c2a28;
}

.zsg-sc-tabs__radio {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.zsg-sc-tabs__label {
    padding: 7px 14px;
    background: #f0f0f0;
    color: #444;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    border-radius: 3px 3px 0 0;
    transition: background .2s, color .2s;
    margin: 0;
}

.zsg-sc-tabs__label:hover {
    background: #e2e2e2;
}

.zsg-sc-tabs__panes > .zsg-sc-tabs__pane {
    display: none;
    padding: 16px 0 0;
}

/* Powiązanie radio → panel: n-ty zaznaczony przycisk pokazuje n-ty panel. */
.zsg-sc-tabs__radio:nth-of-type(1):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(1),
.zsg-sc-tabs__radio:nth-of-type(2):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(2),
.zsg-sc-tabs__radio:nth-of-type(3):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(3),
.zsg-sc-tabs__radio:nth-of-type(4):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(4),
.zsg-sc-tabs__radio:nth-of-type(5):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(5),
.zsg-sc-tabs__radio:nth-of-type(6):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(6),
.zsg-sc-tabs__radio:nth-of-type(7):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(7),
.zsg-sc-tabs__radio:nth-of-type(8):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(8),
.zsg-sc-tabs__radio:nth-of-type(9):checked  ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(9),
.zsg-sc-tabs__radio:nth-of-type(10):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(10),
.zsg-sc-tabs__radio:nth-of-type(11):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(11),
.zsg-sc-tabs__radio:nth-of-type(12):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(12),
.zsg-sc-tabs__radio:nth-of-type(13):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(13),
.zsg-sc-tabs__radio:nth-of-type(14):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(14),
.zsg-sc-tabs__radio:nth-of-type(15):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(15),
.zsg-sc-tabs__radio:nth-of-type(16):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(16),
.zsg-sc-tabs__radio:nth-of-type(17):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(17),
.zsg-sc-tabs__radio:nth-of-type(18):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(18),
.zsg-sc-tabs__radio:nth-of-type(19):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(19),
.zsg-sc-tabs__radio:nth-of-type(20):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(20),
.zsg-sc-tabs__radio:nth-of-type(21):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(21),
.zsg-sc-tabs__radio:nth-of-type(22):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(22),
.zsg-sc-tabs__radio:nth-of-type(23):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(23),
.zsg-sc-tabs__radio:nth-of-type(24):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(24),
.zsg-sc-tabs__radio:nth-of-type(25):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(25),
.zsg-sc-tabs__radio:nth-of-type(26):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(26),
.zsg-sc-tabs__radio:nth-of-type(27):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(27),
.zsg-sc-tabs__radio:nth-of-type(28):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(28),
.zsg-sc-tabs__radio:nth-of-type(29):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(29),
.zsg-sc-tabs__radio:nth-of-type(30):checked ~ .zsg-sc-tabs__panes > .zsg-sc-tabs__pane:nth-child(30) {
    display: block;
}

/* Podświetlenie aktywnej zakładki */
.zsg-sc-tabs__radio:nth-of-type(1):checked  ~ .zsg-sc-tabs__nav .zsg-sc-tabs__label:nth-of-type(1),
.zsg-sc-tabs__radio:nth-of-type(2):checked  ~ .zsg-sc-tabs__nav .zsg-sc-tabs__label:nth-of-type(2),
.zsg-sc-tabs__radio:nth-of-type(3):checked  ~ .zsg-sc-tabs__nav .zsg-sc-tabs__label:nth-of-type(3) {
    background: #9c2a28;
    color: #fff;
}

/* --- Zdjęcie: [photo_panel] --- */
.zsg-sc-photo {
    margin: 0;
    text-align: center;
}

.zsg-sc-photo img {
    max-width: 100%;
    height: auto;
    display: inline-block;
    border: 1px solid #ddd;
    border-radius: 3px;
}

.zsg-sc-photo figcaption {
    font-size: 13px;
    color: #666;
    padding-top: 6px;
}

/* --- Pozostałe --- */
.zsg-sc-button {
    display: inline-block;
    padding: 9px 20px;
    background: #9c2a28;
    color: #fff;
    border-radius: 3px;
    font-weight: 600;
    text-decoration: none;
    margin: 4px 0;
}

.zsg-sc-button:hover {
    filter: brightness(1.12);
    color: #fff;
}

.zsg-sc-heading {
    margin: 18px 0 10px;
    font-weight: 700;
}

.zsg-sc-quote {
    border-left: 4px solid #9c2a28;
    padding: 8px 0 8px 16px;
    margin: 16px 0;
    font-style: italic;
    color: #444;
}

.zsg-sc-quote cite {
    display: block;
    margin-top: 6px;
    font-style: normal;
    font-weight: 600;
    font-size: 13px;
}

.zsg-sc-note,
.zsg-sc-panel {
    padding: 14px 18px;
    border-radius: 4px;
    margin: 14px 0;
    background: #f5f5f5;
}

.zsg-sc-box {
    border: 2px solid #9c2a28;
    margin: 16px 0;
    overflow: hidden;
}

.zsg-sc-box__title {
    padding: 8px 14px;
    color: #fff;
    font-weight: 700;
}

.zsg-sc-box__body {
    padding: 14px;
}

.zsg-sc-list {
    margin: 10px 0;
}

.zsg-sc-listitem {
    padding: 5px 0;
}

.zsg-sc-listitem i {
    color: #9c2a28;
    margin-right: 6px;
}

.zsg-sc-embed {
    position: relative;
    padding-top: 56.25%;
    margin: 16px 0;
}

.zsg-sc-embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.zsg-sc-embed--doc {
    padding-top: 0;
}

.zsg-sc-embed--doc iframe {
    position: static;
    height: 100%;
}

.zsg-sc-video,
.zsg-sc-audio {
    max-width: 100%;
    margin: 14px 0;
}

.zsg-sc-doc a {
    display: inline-block;
    padding: 8px 16px;
    background: #f0f0f0;
    border-radius: 3px;
    color: #9c2a28;
    font-weight: 600;
}

@media (max-width: 767px) {
    .zsg-sc-tabs__label {
        padding: 6px 10px;
        font-size: 13px;
    }
}
