.ast-separate-container .type-skoleni {
    background-color: transparent !important;
}

div.skoleni {
    padding: var(--padding-l);
    border-radius: var(--radius-l);
    background-color: var(--background-dark);
}

div.skoleni p {
    color: var(--text-negative-secondary, #D2D2D6);
}

div.skoleni p.label {
    color: var(--text-negative-secondary, #D2D2D6);
}

div.skoleni h2,
div.skoleni h3 {
    color: var(--text-negative-primary, #FFFFFF) !important;
}

.skoleni-grid {  
}

.skoleni-grid h3 {
    color: #fff;
}

.skoleni-grid-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    grid-gap: 15px; 
}

.skoleni-grid-item {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
    border-radius: var(--radius-m, 16px);
    transition: filter 0.3s ease, transform 0.3s ease;
    background-color: #005c67;
}

.skoleni-grid-item .wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: flex-end;
    
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    
    overflow: hidden;
    -webkit-mask-image: radial-gradient(#000 99.6%, transparent 100%);
    mask-image: radial-gradient(#000 99.6%, transparent 100%);
    
    color: #fff;
    z-index: 1;
}

.skoleni-grid-item:hover {
    box-shadow: 0px 24px 32px 0px #0000003D;
}

.skoleni-grid-item .wrapper::after {
    content: "";
    position: absolute;
    inset: 0;
    top: auto;
    height: 60%;
    background: linear-gradient(180deg,
        rgba(0,21,28,0) 0%,
        rgba(0,21,28,.72) 42%,
        rgba(0,21,28,.95) 100%);
    pointer-events: none;
    z-index: 2;
}

.skoleni-grid-item a,
.skoleni-grid-item a:hover {
    color: #fff;
    text-decoration: none;
}

.skoleni-grid-item h3 {
    font-weight: 650;
    font-size: 16px;
    line-height: 160%;
    letter-spacing: 0%;
    margin: 0;
    padding: 0;
}

.skoleni-grid-content {
    padding: 20px;
    position: relative;
    z-index: 4;
    width: 100%;
    display: flex;
    align-items: flex-start;
    flex-direction: row;
    justify-content: space-between;
}

.skoleni-grid-content::after {
    content: "";
    position: absolute;
    right: 16px;
    bottom: 16px;
    width: 24px;
    height: 24px;

    background-color: #fff;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.3s ease;

    -webkit-mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5.50004 17.4166L17.4167 5.49996M17.4167 5.49996V16.94M17.4167 5.49996H5.97671' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M5.50004 17.4166L17.4167 5.49996M17.4167 5.49996V16.94M17.4167 5.49996H5.97671' stroke='black' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
}

.skoleni-grid-item:hover .skoleni-grid-content::after {
    transform: rotate(45deg);
    background-color: #00DFEA;
}

.skoleni-grid-info {
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    justify-content: flex-end;
}

.skoleni-grid-title,
.skoleni-grid-title a {
    font-weight: 650;
    font-style: Bold;
    font-size: 1rem;
    leading-trim: NONE;
    line-height: 160%;
}

.skoleni-grid-title a:hover {
    color: var(--text-negative-primary, #FFFFFF) !important;
}

.skoleni-grid-termin {
    font-weight: 500;
    font-style: Medium;
    font-size: .75rem;
    leading-trim: NONE;
    line-height: 160%;
    letter-spacing: 2%;
    color: var(--text-negative-secondary, #D2D2D6);
    margin-top: 4px;
}

.skoleni-grid-cena {
    font-weight: 700;
    font-style: Bold;
    font-size: 1.25rem;
    leading-trim: NONE;
    line-height: 100%;
    margin-top: 4px;
}

.skoleni-grid-akce a.open-href {
    
}

.skoleni-btn {/*
    display: inline-block;
    background-color: #00C1DE;
    color: white !important;
    font-weight: 500;
    padding: 12px 24px;
    border-radius: 5px;
    text-decoration: none !important;
    text-align: center;
    transition: background-color 0.3s;
    border: none;*/
}

/* Informace o školení zdarma v detailu produktu — Figma 2042:38691 */
.skoleni-zdarma-detail {
    display: flex;
    align-items: center;
    gap: var(--spacing-16, 16px);
    margin: 32px 0 0 0;
    padding: var(--padding-24, 24px);
    border: 1px solid var(--border-primary-solid, #E2E2E5);
    border-radius: var(--radius-m, 16px);
}

.skoleni-zdarma-icon {
    flex: 0 0 40px;
    height: 40px;
}

.skoleni-zdarma-icon img {
    width: 40px;
    height: 40px;
}

.skoleni-zdarma-text {
    flex: 1;
    display: flex;
    gap: var(--spacing-16, 16px);
    align-items: center;
    min-width: 0;
}

.skoleni-zdarma-text p {
    flex: 1;
    margin-bottom: 0;
    font-weight: 450;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-positive-secondary, #52525b);
}

.skoleni-more-info {
    display: inline-block;
    flex-shrink: 0;
    white-space: nowrap;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1;
    text-decoration: none;
    color: var(--button-tertiary-tertiary-bglight-default, #008C9D);
}

.skoleni-more-info:hover {
    text-decoration: underline;
}

.skoleni-detail-terminy {
    padding: 64px 0;
}

.skoleni-detail-termin {
    display: flex;
    background: white;
    padding: 16px 24px;
    border-radius: var(--radius-m);
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    color: var(--text-positive-primary, #022930);
}

.skoleni-detail-termin .small {
    font-weight: 500;
    font-style: Medium;
    font-size: .75rem;
    line-height: 160%;
    letter-spacing: 2%;
    vertical-align: middle;
    color: var(--text-positive-secondary, #52525B);
}

.skoleni-detail-termin .big {
    font-weight: 650;
    font-style: Bold;
    font-size: 1rem;
    line-height: 160%;
    letter-spacing: 0%;
    vertical-align: middle;
    color: var(--text-positive-primary, #022930);
}

.skoleni-detail-lektor,
.skoleni-detail-osoba {
    padding-bottom: 32px;
}

.skoleni-detail-podminky {
    padding-bottom: 32px;
}

.skoleni-termin-datum {
    width: 270px;
    padding-right: 32px;
    margin-right: 32px;
    text-align: center;
    border-right: 1px solid var(--border-primary-solid, #E2E2E5)
}

.skoleni-termin-den,
.skoleni-termin-rok {
    font-weight: 450;
    font-style: Regular;
    font-size: 1rem;
    line-height: 160%;
    letter-spacing: 0%;
}

.skoleni-termin-cislo {
    font-weight: 700;
    font-style: Bold;
    font-size: 2rem;
    line-height: 120%;
    letter-spacing: -1%;
    white-space: nowrap;
}

.skoleni-termin-cas,
.skoleni-termin-misto,
.skoleni-termin-cena {
    padding-left: 35px;
    display: flex;
    flex-direction: column;
    background-repeat: no-repeat;
    background-size: 24px 24px;
    background-position: 0 50%;
}

.skoleni-termin-content {
    width: 100%;
    display: flex;
    gap: 32px;
}

.skoleni-termin-content .skoleni-termin-cas,
.skoleni-termin-content .skoleni-termin-misto {
    width: calc(36.91% - 35px);
}

.skoleni-termin-cas {
    background-image: url("data:image/svg+xml;utf8,<svg width='24' height='24' viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'><path d='M12 6L12 12L18 12' stroke='%23022930' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/><path d='M12 22C17.5228 22 22 17.5228 22 12C22 6.47715 17.5228 2 12 2C6.47715 2 2 6.47715 2 12C2 17.5228 6.47715 22 12 22Z' stroke='%23022930' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/></svg>");
}

.skoleni-termin-misto {
    background-image: url("../img/pointer.svg");
}

.skoleni-termin-cena {
    background-image: url("../img/money.svg");
}

a.skoleni-btn.skoleni-prihlasit {
/*    font-weight: 600;
    font-style: SemiBold;
    font-size: 16px;
    line-height: 100%;
    letter-spacing: 0%;
    color: var(--text-positive-primary, #022930) !important;
    background: var(--button-primary-primary-default, #00DFEA);
*/}

/* Modální okno pro školení */
.skoleni-modal {
    max-width: 600px;
    padding: 40px;
    border-radius: 10px;
}

.skoleni-modal h2 {
    font-size: 24px;
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
}

.skoleni-modal p {
    line-height: 1.6;
    margin-bottom: 25px;
}

.skoleni-modal-footer {
    margin-top: 30px;
    text-align: left;
}

.skoleni-button {
    display: inline-block;
    padding: 12px 25px;
    background-color: #4CAF50;
    color: white;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.skoleni-button:hover {
    background-color: #45a049;
    color: white;
}

.ucastnik-container {
    background-color: #F5F7F9;
    border-radius: 5px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
}

.ucastnik-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-gap: 15px;
}

.ucastnik-remove {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 32px;
    height: 32px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #666;
    transition: all 0.2s;
}

.ucastnik-remove:hover {
    background-color: #fee2e2;
    border-color: #fecaca;
    color: #dc2626;
}

.prihlaska-disclaimer {
    background-color: #F5F7F9;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 20px;
    font-size: 14px;
    color: #4B5563;
}

.prihlaska-disclaimer p {
    margin: 0;
}

.prihlaska-disclaimer a {
    color: #00C1DE;
    text-decoration: none;
}

.prihlaska-disclaimer a:hover {
    text-decoration: underline;
}

.prihlaska-souhlas {
    display: flex;
    align-items: flex-start;
    margin-bottom: 20px;
}

.prihlaska-souhlas input[type="checkbox"] {
    margin-top: 3px;
    margin-right: 10px;
}

.prihlaska-souhlas label {
    font-size: 14px;
    color: #4B5563;
}

.prihlaska-submit {
    text-align: center;
}

.prihlaska-btn {
    display: inline-block;
    background-color: #00C1DE;
    color: white;
    font-weight: 500;
    padding: 12px 36px;
    border-radius: 5px;
    text-decoration: none;
    text-align: center;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.prihlaska-btn:hover {
    background-color: #00a3b9;
}

/* --- Animace --- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.prihlaska-overlay {
    animation: fadeIn 0.3s ease-out;
}

.prihlaska-form-wrapper {
    animation: slideIn 0.3s ease-out;
}

/* --- Zprávy --- */
.prihlaska-message {
    padding: 16px;
    border-radius: 5px;
    margin-bottom: 20px;
    font-weight: 500;
}

.prihlaska-message.success {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.prihlaska-message.error {
    background-color: #fee2e2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.prihlaska-message.info {
    background-color: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

/* --- Loader --- */
.prihlaska-loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease infinite;
    margin-right: 10px;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Styly pro lektor sekci */
.skoleni-lektor {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.skoleni-lektor-name {

}

.skoleni-lektor-name h4 {
    font-weight: 650;
    font-style: Bold;
    font-size: 1.25rem;
    line-height: 120%;
    letter-spacing: 0%;
    margin-bottom: 0;
}

.skoleni-lektor-image {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    margin-right: 30px;
    overflow: hidden;
    flex-shrink: 0;
}

.skoleni-lektor-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.skoleni-lektor-info {
    flex-grow: 1;
}

.skoleni-lektor-info h3 {
    font-size: 22px;
    font-weight: 600;
    margin: 0 0 10px 0;
}

.skoleni-lektor-info p {
    margin: 0 0 15px 0;
    color: #4B5563;
}

/* ########################################################################################################### */

/* Úpravy layoutu stránky */
.skoleni-detail-page .ast-container {
    max-width: var(--global-max-width);
}

/* Odstranění přebytečných okrajů a výplní */
.skoleni-detail-page #primary {
    margin: 0;
    padding: 0;
}

.skoleni-detail-page .site-content {
    margin-top: 30px;
}

.skoleni-detail-page .entry-content {
    margin-bottom: 0;
}

/* Speciální úpravy pro obsah detailu školení */
.skoleni-detail {
    margin-bottom: 60px;
}

/* Opravy potenciálních konfliktů s Astra motivem */
.skoleni-detail-page .entry-content p:last-child {
    margin-bottom: 0;
}

.skoleni-detail-page .entry-header {
    display: none;
}

/* Úprava obsahové oblasti (pokud je použit Gutenberg) */
.skoleni-detail-page .wp-block-columns {
    margin-bottom: 0;
}

.skoleni-detail-page .wp-block-column:not(:first-child) {
    margin-left: 32px;
}

.skoleni-detail-header {
    display: flex;
    gap: 32px;
}

.skoleni-detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 138px;
}

.skoleni-detail-individual {
    display: flex;
    border-radius: var(--radius-m);
    border: solid 1px #e2e2e5;
    padding: var(--padding-24); 
    margin-bottom: 20px;
    gap: 16px;

    align-items: center;
    justify-content: space-between;
    flex-direction: row;
}

.skoleni-detail-individual h4 {
    font-family: Plus Jakarta Sans;
    font-weight: 650;
    font-style: Bold;
    font-size: 20px;
    line-height: 120%;
    letter-spacing: 0%;
    margin-bottom: 8px;
}

.skoleni-detail-image {
    max-width: 604px;*/
    text-align: right;
}

.skoleni-detail-image img {
    max-width: inherit;
    border-radius: var(--radius-l);
}

.skoleni-detail-description {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Styly pro formulář registrace na školení */
#skoleni-registrace-form {
    max-width: 600px;
    margin: 0 auto;
}

#skoleni-registrace-form h3 {
    margin-top: 20px;
    margin-bottom: 15px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
}

#skoleni-registrace-form footer {
    display: flex;
    justify-content: space-between;
}

.participant {
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 15px;
    border: 1px solid #eee;
}

.participant-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    align-items: center;
}

.participant-header span {
    font-weight: bold;
}

.remove-participant {
    font-family: Plus Jakarta Sans;
    font-weight: 600;
    font-style: SemiBold;
    font-size: 1rem;
    line-height: 100%;
    letter-spacing: 0%;

    cursor: pointer;
    padding: 0 30px 0 0;
    color: var(--delete, #AF0009);

    min-height: 22px;

    background-color: transparent;
    background-repeat: no-repeat;
    background-position: 100% 50%;
    background-size: 22px 22px;
    background-image: url("data:image/svg+xml,<svg width='22' height='22' viewBox='0 0 22 22' fill='none' xmlns='http://www.w3.org/2000/svg'><path d='M18.3333 8.25065L16.5046 18.6514C16.3505 19.528 15.589 20.1673 14.699 20.1673H7.30101C6.41097 20.1673 5.64951 19.528 5.49538 18.6514L3.66667 8.25065M19.25 5.50065H14.0938M14.0938 5.50065V3.66732C14.0938 2.6548 13.273 1.83398 12.2604 1.83398H9.73958C8.72706 1.83398 7.90625 2.6548 7.90625 3.66732V5.50065M14.0938 5.50065H7.90625M2.75 5.50065H7.90625' stroke='%23AF0009' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/></svg>");
}

.remove-participant:hover {
    background-color: transparent;
    color: var(--delete, #AF0009);
}

#add-participant {
    background: none;
    border: none;
    color: var(--button-tertiary-tertiary-bglight-default, #008C9D);

    cursor: pointer;
    padding: 0 0 0 30px;
    margin-bottom: 20px;
    font-weight: bold;
    display: block;

    min-height: 22px;

    background-color: transparent;
    background-repeat: no-repeat;
    background-position: 0% 50%;
    background-size: 22px 22px;
    background-image: url("data:image/svg+xml,<svg width='22' height='22' viewBox='0 0 22 22' fill='none' xmlns='http://www.w3.org/2000/svg'><path d='M15.5832 9.16602H18.3332M18.3332 9.16602H21.0832M18.3332 9.16602V6.41602M18.3332 9.16602V11.916M0.916504 18.3327V17.416C0.916504 13.8722 3.78934 10.9993 7.33317 10.9993M13.7498 18.3327V17.416C13.7498 13.8722 10.877 10.9993 7.33317 10.9993M7.33317 10.9993C9.35822 10.9993 10.9998 9.35773 10.9998 7.33268C10.9998 5.30764 9.35822 3.66602 7.33317 3.66602C5.30813 3.66602 3.6665 5.30764 3.6665 7.33268C3.6665 9.35773 5.30813 10.9993 7.33317 10.9993Z' stroke='%23008C9D' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/></svg>");
}

#add-participant:hover {
    background-color: transparent;
    color: var(--button-tertiary-tertiary-bglight-default, #008C9D);
}

/* Základní badge pro "Nabídka školení" */
.skoleni-counter {
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-width:20px;
    height:20px;
    padding:0 6px;
    margin-left:8px;
    border-radius:999px;

    font-weight: 700;
    font-style: Bold;
    font-size: 12px;
    line-height: 160%;
    letter-spacing: 2%;

    vertical-align:middle;
    transform:translateY(-1px);
    color: var(--badge-green-text, #166533);
    background: var(--badge-green-fill, #BBF7D1);
}

/* Pro patičkové menu (Astra) můžeš doladit spacing/velikost) */
.site-footer .menu .skoleni-counter{
    margin-left:.4em;
    min-width:18px;
    height:18px;
    font-size:11px;
}

.single-skoleni .vice-informaci {
    padding: var(--padding-24);
    border: 1px solid var(--border-primary-solid, #E2E2E5);
    border-radius: var(--radius-m);
    display: flex;
    flex-direction: row;
    align-items: center;
}

.single-skoleni .vice-informaci h4 {
    font-weight: 650;
    font-style: Bold;
    font-size: 20px;
    line-height: 120%;
    letter-spacing: 0%;
    margin-bottom: 8px;
}

.single-skoleni .vice-informaci .wp-block-button a {
    padding-left: 27px;
    white-space: nowrap;
}

.skoleni-karusel {
    padding: 64px 0;
    clear: both;
}

.skoleni-karusel header h3 {
    font-weight: 700;
    font-style: Bold;
    font-size: 2rem;
    line-height: 120%;
    letter-spacing: -1%;
}

.skoleni-karusel header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 48px;
}

.skoleni-grid-item .skoleni-grid-item {
    overflow: inherit;
}

.osobni-udaje {
    font-weight: 500;
    font-size: .75rem;
    line-height: 160%;
    letter-spacing: 2%;
}

.souhlas {
    display: flex;
    align-items: center;
    gap: 8px;
}

.souhlas span {
    font-weight: 500;
    font-size: .75rem;
    line-height: 160%;
    letter-spacing: 2%;
}

#skoleni-registrace-result,
.skoleni-modal-result-inner {
    text-align: center;
}

.skoleni-modal-result.is-success #skoleni-registrace-back {
    display: none;
}

.skoleni-modal-result.is-success .skoleni-modal-result-icon {
    background-image: url(../img/form-sended.png);
    background-repeat: no-repeat;
    height: 200px;
    background-position: 50% 0;
}

.skoleni-badge {
    font-weight: 600;
    font-size: .75rem;
    line-height: 20xp;
    letter-spacing: 0%;
    color: var(--badge-green-text, #166533);


    padding-right: var(--padding-4);
    padding-left: var(--padding-4);
    background: var(--badge-green-fill, #BBF7D1);
    border-radius: var(--radius-xxs);

    position: absolute;
    top: 16px;
    left: 16px;
}

#skoleni-individual-modal {
    min-height: 300px; /* Zabrání zhroucení výšky při přepínání obsahu */
}

/* Ujistíme se, že výsledek je vidět */
#skoleni-individual-result {
    text-align: center;
    padding: 20px;
}

/* Styly pro CF7 v modálním okně školení */
#skoleni-individual-modal .wpcf7-form p {
    margin-bottom: 15px;
}

#skoleni-individual-modal .wpcf7-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--text-positive-primary, #022930);
}

#skoleni-individual-modal .wpcf7-form input[type="text"],
#skoleni-individual-modal .wpcf7-form input[type="email"],
#skoleni-individual-modal .wpcf7-form input[type="tel"],
#skoleni-individual-modal .wpcf7-form textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box; /* Důležité, aby padding nerozbil šířku */
}

#skoleni-individual-modal .wpcf7-submit {
    display: inline-block;
    background-color: #00C1DE; /* Vaše barva tlačítka */
    color: white;
    font-weight: 500;
    padding: 12px 36px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
    margin-top: 10px;
}

#skoleni-individual-modal .wpcf7-submit:hover {
    background-color: #00a3b9;
}

/* Spinner u CF7 */
#skoleni-individual-modal .wpcf7-spinner {
    position: absolute;
    margin-top: 15px;
}

/* Responzivní úpravy */
@media (max-width: 921px) {
    .skoleni-detail-page .ast-container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .skoleni-detail-page .site-content {
        margin-top: 20px;
    }

    .skoleni-grid-wrapper {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 781px) {
    .skoleni-detail-page .wp-block-column:not(:only-child) {
        margin-left: 0;
    }
}

@media (max-width: 767px) {
    .skoleni-termin {
        flex-direction: column;
        align-items: flex-start;
        padding: 16px;
    }
    
    .skoleni-termin-datum {
        width: 100%;
        margin-right: 0;
        margin-bottom: 16px;
        flex-direction: row;
        justify-content: space-between;
    }
    
    .skoleni-termin-info {
        width: 100%;
        padding-right: 0;
        margin-bottom: 16px;
    }
    
    .skoleni-termin-akce {
        width: 100%;
    }

    .skoleni-termin-akce {
        display: flex;
    }
    
    .skoleni-termin-akce .skoleni-btn {
        width: 100%;
    }
    
    .ucastnik-fields {
        grid-template-columns: 1fr;
    }
    .skoleni-lektor {
        padding: 0;
        gap: 16px;

        display: flex;
        flex-direction: row;
        justify-content: flex-start;
        align-items: center;
        text-align: center;
    }
    
    .skoleni-lektor-image {
        margin-right: 0;
        margin-bottom: 0;
    }

    .skoleni-grid-wrapper {
        grid-template-columns: 1fr;
    }

    .skoleni-detail-image {
        max-width: 100%;
    }

    .skoleni-termin-content {
        flex-direction: column;
        gap: 0;
    }

    .skoleni-termin-content .skoleni-termin-cas,
    .skoleni-termin-content .skoleni-termin-misto {
        width: auto;
    }
}

/* ==========================================================================
   Fade + prosvítající 3. řada gridu školení (Figma 3953:40658 / 40679).
   2 řady plně, 3. řada prosvítá pod gradientem (144px, celá šířka k hraně tmavé
   sekce), na něm tlačítko „Další kurzy". Klik → rozbalí (JS) + AJAX donačte.
   ========================================================================== */
.skoleni-grid-viewport {
    overflow: hidden;
}

/* Pozicovací kontext pro fade = přímo .skoleni-grid (obsahuje nadpis + viewport;
   fade je absolutní, mimo flow, takže spodek .skoleni-grid = spodek ořezaného
   viewportu → fade bottom:0 sedí přesně na ořezu). Šířka = šířka gridu; 48px
   padding sekce po stranách je stejně prázdná tmavá plocha, takže „k okraji"
   vypadá identicky a nemusíme sahat do zanořených Gutenberg groupů. */
.skoleni-grid.is-peeking {
    position: relative;
}

/* Peeking: gradientový overlay přes prosvítající 3. řadu + tlačítko na něm.
   Třídu is-peeking přidává JS jen když existuje další řada k prosvítání (víc než
   `data-rows` řad) — jinak (např. 2 řady na homepage) by fade zbytečně
   zakrýval spodek poslední řady. */
.skoleni-grid.is-peeking .skoleni-grid-fade {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    /* z-index nad kartami: .skoleni-grid-item .wrapper má z-index:1, takže bez
       tohoto by pozicované karty překreslily fade i tlačítko (mizely). Boční
       posun left/right na hranu tmavého boxu dopočítává JS (collapse). */
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 144px;
    background: linear-gradient(
        180deg,
        rgba(2, 41, 48, 0) 0%,
        var(--background-dark, #022930) 100%
    );
    pointer-events: none;
}

.skoleni-grid.is-peeking .skoleni-grid-fade .skoleni-btn {
    pointer-events: auto;
}

/* Bez peeku (málo řad / po rozbalení): tlačítko v normálním flow pod gridem. */
.skoleni-grid:not(.is-peeking) .skoleni-grid-fade {
    display: flex;
    justify-content: center;
    margin: 2.5rem 0 1rem;
}
/* ===========================================================================
   ŠKOLENÍ — tablet listing (page-id-177) + detail (skoleni-detail-page)
   KONSOLIDACE fáze A: přesunuto verbatim z audit-fixes.css (sekce 26).
   Vše !important + body-scope (vysoká specificita) → jediný zdroj,
   order-independent. Test: /skoleni-a-seminare/terminy-a-prihlaska/,
   /skoleni/frosio-certifikovany-kurz/ (tablet 768–921).
   ========================================================================== */
.skoleni-detail-content {
    align-items: start !important;
}

.single-skoleni .vice-informaci {
    align-self: start !important;
    height: auto !important;
}

@media (min-width: 768px) and (max-width: 921.98px) {
    body.page-id-177 .entry-content > .wp-block-group.skoleni {
        width: calc(100% + 64px) !important;
        max-width: none !important;
        margin-right: -32px !important;
        margin-left: -32px !important;
        padding-right: 32px !important;
        padding-left: 32px !important;
    }

    body.page-id-177 .entry-content > .wp-block-group.skoleni > .wp-block-group__inner-container {
        width: 100% !important;
        max-width: none !important;
        padding-right: 0 !important;
        padding-left: 0 !important;
    }

    body.page-id-177 .skoleni-grid-wrapper {
        width: 100% !important;
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 32px !important;
    }

    body.page-id-177 .entry-content > .wp-block-columns:first-of-type {
        flex-wrap: nowrap !important;
        gap: 32px !important;
        padding-right: 0 !important;
        padding-left: 0 !important;
    }

    body.page-id-177 .entry-content > .wp-block-columns:first-of-type > .wp-block-column,
    body.page-id-177 .entry-content > .wp-block-columns:first-of-type:not(.is-not-stacked-on-mobile) > .wp-block-column {
        flex-basis: calc(50% - 16px) !important;
        width: calc(50% - 16px) !important;
        min-width: 0 !important;
    }

    body.page-id-177 .entry-content > .wp-block-group.pt-64.pb-64,
    body.page-id-177 .entry-content > .wp-block-group.odbornici {
        padding-right: 0 !important;
        padding-left: 0 !important;
    }

    body.page-id-177 .entry-content > .wp-block-group.pt-64.pb-64 > .wp-block-group__inner-container,
    body.page-id-177 .entry-content > .wp-block-group.odbornici > .wp-block-group__inner-container {
        width: 100% !important;
        max-width: none !important;
        padding-right: 0 !important;
        padding-left: 0 !important;
    }

    body.page-id-177 .entry-content > .wp-block-group.pt-64.pb-64 .wp-block-columns {
        width: 100% !important;
        flex-wrap: nowrap !important;
        gap: 32px !important;
        padding-right: 0 !important;
        padding-left: 0 !important;
    }

    body.page-id-177 .entry-content > .wp-block-group.pt-64.pb-64 .wp-block-columns > .wp-block-column,
    body.page-id-177 .entry-content > .wp-block-group.pt-64.pb-64 .wp-block-columns:not(.is-not-stacked-on-mobile) > .wp-block-column {
        flex-basis: calc(50% - 16px) !important;
        width: calc(50% - 16px) !important;
        min-width: 0 !important;
    }

    body.page-id-177 .odbornici-carousel {
        width: 100% !important;
    }

    body.page-id-177 .odbornici-carousel .owl-stage-outer {
        width: 100% !important;
    }

    body.page-id-177 .odbornici h3 {
        color: #022930 !important;
        font-weight: 700 !important;
        letter-spacing: -0.01em !important;
    }

    body.page-id-177 .odbornici-carousel .owl-stage {
        margin-left: -40px !important;
    }

    body.skoleni-detail-page .ast-container {
        max-width: none !important;
        padding-right: 32px !important;
        padding-left: 32px !important;
    }

    body.skoleni-detail-page .skoleni-detail,
    body.skoleni-detail-page .skoleni-detail-header,
    body.skoleni-detail-page .skoleni-detail-description,
    body.skoleni-detail-page .skoleni-detail-image,
    body.skoleni-detail-page .skoleni-detail-image img,
    body.skoleni-detail-page .skoleni-detail-terminy,
    body.skoleni-detail-page .skoleni-detail-content {
        width: 100% !important;
        max-width: none !important;
    }

    body.skoleni-detail-page .skoleni-detail-image img {
        height: auto !important;
        object-fit: cover !important;
    }

    body.skoleni-detail-page .skoleni-detail-termin {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 16px !important;
        padding: 24px !important;
        align-items: start !important;
        justify-content: stretch !important;
    }

    body.skoleni-detail-page .skoleni-termin-datum {
        width: 100% !important;
        margin-right: 0 !important;
        padding-right: 0 !important;
        padding-bottom: 16px !important;
        border-right: 0 !important;
        border-bottom: 1px solid var(--border-primary-solid, #E2E2E5) !important;
        text-align: left !important;
    }

    body.skoleni-detail-page .skoleni-termin-content {
        width: 100% !important;
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        gap: 24px !important;
    }

    body.skoleni-detail-page .skoleni-termin-content .skoleni-termin-cas,
    body.skoleni-detail-page .skoleni-termin-content .skoleni-termin-misto,
    body.skoleni-detail-page .skoleni-termin-content .skoleni-termin-cena {
        width: auto !important;
        min-width: 0 !important;
    }

    body.skoleni-detail-page .skoleni-termin-akce {
        width: 100% !important;
        display: flex !important;
        justify-content: flex-start !important;
    }

    /* Fallback pro .skoleni-detail-content mimo detail stránku (shortcode
       [skoleni id=…] na běžné stránce): 2 sloupce místo base gap 138px.
       Přesun z audit-fixes (2026-09-08). Na detailu ho přebije 1fr!important níž. */
    .skoleni-detail-content {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 24px;
    }

    body.skoleni-detail-page .skoleni-detail-content {
        grid-template-columns: 1fr !important;
        gap: 32px !important;
    }
}

/* ===========================================================================
   ŠKOLENÍ — listing base overridy (desktop)
   KONSOLIDACE fáze B: přesunuto verbatim z audit-fixes.css (sekce 5).
   #17 gap, #18/#33 badge, #19/#35 div.skoleni fade gradient, #34 grid-item
   hover shadow. Přebíjí base výše (append za base = shodné pořadí jako dřív),
   order-independent. Test: /skoleni-a-seminare/ (desktop).
   ========================================================================== */
/* #17 — Školení: gap mezi kartami ~15px místo 32px
   Figma: gap 32px | Dev: ~15px
   Závažnost: Střední */
.skoleni-grid-wrapper {
    grid-gap: 32px !important;
    gap: 32px !important;
}

/* #18 + #33 — Školení: badge "Vypsaný termín" má špatný padding
   Figma: padding 4px 8px | Dev: 0px 4px
   Závažnost: Střední */
.skoleni-badge,
.skoleni-grid-item .badge,
.skoleni-grid-content .badge {
    padding: 4px 8px;
    border-radius: var(--radius-xxs, 4px);
}

/* #19 + #35 — Školení: chybějící fade gradient overlay
   Figma: gradient rgba(2,41,48,0)→rgba(2,41,48,0.86)→#022930
   Dev: žádný gradient
   Závažnost: Střední */
div.skoleni {
    position: relative;
    overflow: hidden;
}

div.skoleni::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 280px;
    background: linear-gradient(
        to bottom,
        rgba(2, 41, 48, 0) 0%,
        rgba(2, 41, 48, 0.86) 50%,
        #022930 100%
    );
    pointer-events: none;
    z-index: 1;
}

div.skoleni .wp-block-group__inner-container {
    position: relative;
    z-index: 2;
}

/* #34 — Školení: karta kurzu chybí hover efekt a shadow
   Figma Card/Event Hover (Shadow/Elevation-2): 0px 24px 32px 0px rgba(0,0,0,0.24)
   Závažnost: Střední */
.skoleni-grid-item {
    transition: box-shadow 0.2s ease;
    overflow: hidden;
}

.skoleni-grid-item:hover {
    /* Figma Shadow/Elevation-2 */
    box-shadow: 0px 24px 32px 0px rgba(0, 0, 0, 0.24);
}

/* ===========================================================================
   ŠKOLENÍ — detail MOBIL (≤768px)
   KONSOLIDACE fáze C: přesunuto z responsive.css. Dřív tyto pravidla
   vyhrávala pořadím (responsive.css po skoleni.css); teď jsou za @media(767)
   níže = shodné pořadí, order-independent. Test: /skoleni/...frosio... (mobil).
   ========================================================================== */
@media (max-width: 768px) {
    .skoleni-detail-header,
    .skoleni-detail-individual,
    .single-skoleni .vice-informaci {
        flex-direction: column;
        text-align: left;
        align-items: flex-start;
    }

    .skoleni-termin-datum {
        padding: 0 0 16px 0;
        margin: 0 0 16px 0;

        display: flex;
        justify-content: center;
        align-items: center;
        gap: 16px;

        border-right: 0;
        border-bottom: 1px solid var(--border-primary-solid, #E2E2E5);
    }

    .skoleni-termin-cas,
    .skoleni-termin-misto,
    .skoleni-termin-cena {
        margin: 0 0 16px 0;
    }

    .skoleni-detail-content {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .skoleni-detail-termin {
        flex-direction: column;
        align-items: flex-start;
    }

    #skoleni-registrace-form footer {
        padding: 0;
    }
}

/* #51 — Mobile: .skoleni-grid-wrapper horizontální padding 16px (Figma).
   Přesunuto z audit-fixes.css (konsolidace 2026-09-08). Za bázi (@1303 gap-only),
   žádný pozdější konkurent na padding v responsive.css. */
@media (max-width: 767.98px) {
    .skoleni-grid-wrapper {
        padding-left: 16px;
        padding-right: 16px;
    }
}
