/* Estilização do Carrossel - Safari Compatible */
.enap-carousel-container {
    background-color: #02333A;
    color: white;
    padding: 60px 20px; 
    position: relative;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

.enap-carousel-inner {
    overflow: hidden;
    max-width: 1142px;
    margin: 0 auto; 
    width: 100%;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
}

.enap-carousel-header {
    margin-bottom: 40px;
    max-width: 700px;
}

.enap-carousel-header p {
    color: white;
}

.enap-carousel-title{
    color: white;
}

.enap-carousel-title p {
    font-size: 32px;
    margin-bottom: 10px;
    line-height: 1.2;
    color: white;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.enap-carousel-subtitle p{
    font-size: 16px;
    margin-top: 0;
    color: white;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.enap-carousel-subtitle{
    color: white;
}

.enap-carousel-content {
    position: relative;
    overflow: hidden;
    width: 100%;
}

.enap-carousel-wrapper {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: stretch;
    -ms-flex-align: stretch;
    align-items: stretch;
    -webkit-transition: -webkit-transform 0.4s ease;
    transition: -webkit-transform 0.4s ease;
    -o-transition: transform 0.4s ease;
    transition: transform 0.4s ease;
    transition: transform 0.4s ease, -webkit-transform 0.4s ease;
    width: 100%;
    will-change: transform;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

.enap-carousel-card {
    -webkit-box-flex: 0;
    -ms-flex: 0 0 25%;
    flex: 0 0 25%;
    width: 25%;
    padding: 0 10px;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    min-width: 0;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
}

.enap-carousel-card-inner {
    background-color: white;
    border-radius: 20px;
    -webkit-border-radius: 20px;
    -moz-border-radius: 20px;
    overflow: hidden;
    height: 100%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
}

.enap-carousel-card-content {
    padding: 15px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    height: 100%;
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
}

.enap-carousel-image {
    width: 100%;
    height: 140px;
    min-height: 140px;
    max-height: 140px;
    -o-object-fit: cover;
    object-fit: cover;
    -o-object-position: top;
    object-position: top;
    border-radius: 20px;
    -webkit-border-radius: 20px;
    -moz-border-radius: 20px;
    display: block;
    -webkit-box-flex: 0;
    -ms-flex: 0 0 auto;
    flex: 0 0 auto;
}

/* Fallback para Safari sem object-fit */
@supports not (object-fit: cover) {
    .enap-carousel-image {
        background-size: cover;
        background-position: top center;
        background-repeat: no-repeat;
        font-family: 'object-fit: cover;';
    }
}

.enap-carousel-image-placeholder {
    width: 100%;
    height: 140px;
    min-height: 140px;
    max-height: 140px;
    background-color: #eee;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    border-radius: 20px;
    -webkit-border-radius: 20px;
    -moz-border-radius: 20px;
    -webkit-box-flex: 0;
    -ms-flex: 0 0 auto;
    flex: 0 0 auto;
}

.enap-carousel-text-container {
    height: 100%;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
    min-height: 0;
}

.enap-carousel-card-title {
    line-height: 1.2;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 15px 0 10px;
    color: #434A54;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.enap-carousel-card-description {
    font-size: 0.95rem;
    color: #434A54;
    margin-bottom: 20px;
    overflow: hidden;
    line-height: 1.5;
}

.enap-carousel-card-description p {
    color: #434A54;
}

.enap-carousel-card-link {
    color: #007D7A;
    font-weight: 500;
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    text-decoration: none;
    -webkit-transition: color 0.2s ease;
    -o-transition: color 0.2s ease;
    transition: color 0.2s ease;
    -webkit-box-flex: 0;
    -ms-flex: 0 0 auto;
    flex: 0 0 auto;
}

.enap-carousel-card-link:hover {
    color: #005d5a;
}

.enap-carousel-card-link-icon {
    margin-left: 5px;
}

.enap-carousel-prev-btn,
.enap-carousel-next-btn {
    position: absolute;
    top: 50%;
    -webkit-transform: translateY(-50%);
    -ms-transform: translateY(-50%);
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background-color: transparent;
    border: none;
    z-index: 10;
    cursor: pointer;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-transition: opacity 0.2s ease;
    -o-transition: opacity 0.2s ease;
    transition: opacity 0.2s ease;
}

.enap-carousel-prev-btn {
    left: 140px;
}

.enap-carousel-next-btn {
    right: 140px;
}

.enap-carousel-btn-image {
    width: 40px;
    height: 40px;
    display: block;
}

.enap-carousel-indicators {
    display: none;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    margin-top: 20px;
}

.enap-carousel-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    -webkit-border-radius: 50%;
    -moz-border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    -webkit-transition: background-color 0.2s ease;
    -o-transition: background-color 0.2s ease;
    transition: background-color 0.2s ease;
}

.enap-carousel-indicator.active {
    background-color: white;
}

.enap-carousel-indicator:not(.active) {
    background-color: rgba(255, 255, 255, 0.5);
}

/* Estilização para cards de demonstração */
.enap-carousel-demo-image {
    width: 100%;
    height: 200px;
    background-color: #eee;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    border-radius: 20px;
    -webkit-border-radius: 20px;
    -moz-border-radius: 20px;
}

.enap-carousel-demo-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 15px 0 10px;
    color: #333;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.enap-carousel-demo-description {
    font-size: 0.95rem;
    margin-bottom: 20px;
    color: #555;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.enap-carousel-demo-link {
    color: #0B8457;
    font-weight: 500;
    display: -webkit-inline-box;
    display: -ms-inline-flexbox;
    display: inline-flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    text-decoration: none;
    -webkit-transition: color 0.2s ease;
    -o-transition: color 0.2s ease;
    transition: color 0.2s ease;
}

.enap-carousel-demo-link:hover {
    color: #086b42;
}

/* Tablet e Desktop médio (992px-1023px) */
@media (max-width: 991px) {
    .enap-carousel-container {
        padding: 40px 15px;
    }
    
    .enap-carousel-title p {
        font-size: 34px;
    }
    
    .enap-carousel-subtitle p{
        font-size: 15px;
    }
    
    .enap-carousel-card {
        -webkit-box-flex: 0;
        -ms-flex: 0 0 50%;
        flex: 0 0 50%;
        width: 50%;
        padding: 0 8px;
    }
    
    .enap-carousel-card-inner {
        min-height: 400px;
    }
    
    .enap-carousel-card-description {
        -webkit-line-clamp: 3;
    }
    
    .enap-carousel-card-title {
        font-size: 1.1rem;
    }
    
    .enap-carousel-card-description {
        font-size: 0.9rem;
    }
    
    .enap-carousel-prev-btn,
    .enap-carousel-next-btn {
        width: 45px;
        height: 45px;
    }
    
    .enap-carousel-prev-btn {
        left: 0;
    }
    
    .enap-carousel-next-btn {
        right: 0;
    }
}

/* Mobile (481px-767px) */
@media (max-width: 767px) {
    .enap-carousel-container {
        padding: 30px 10px;
    }
    
    .enap-carousel-header {
        margin-bottom: 30px;
        text-align: center;
    }
    
    .enap-carousel-title p{
        font-size: 32px;
        line-height: 1.3;
    }
    
    .enap-carousel-subtitle p{
        font-size: 14px;
    }
    
    .enap-carousel-card {
        -webkit-box-flex: 0;
        -ms-flex: 0 0 100%;
        flex: 0 0 100%;
        width: 100%;
        padding: 0 5px;
    }
    
    .enap-carousel-card-inner {
        max-width: 400px;
        min-height: 380px;
        margin: 0 auto;
        border-radius: 16px;
        -webkit-border-radius: 16px;
        -moz-border-radius: 16px;
    }
    
    .enap-carousel-image,
    .enap-carousel-image-placeholder {
        height: 180px;
        min-height: 180px;
        max-height: 180px;
        border-radius: 16px;
        -webkit-border-radius: 16px;
        -moz-border-radius: 16px;
    }
    
    .enap-carousel-text-container {
        padding: 20px 0;
    }
    
    .enap-carousel-card-title {
        font-size: 1.25rem;
    }
    
    .enap-carousel-card-description {
        font-size: 0.95rem;
        line-height: 1.6;
    }
    
    .enap-carousel-card-link {
        font-size: 1rem;
        font-weight: 600;
    }
    
    /* Mostra indicadores e oculta botões */
    .enap-carousel-indicators {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
    }
    
    .enap-carousel-prev-btn,
    .enap-carousel-next-btn {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
    }

    .enap-carousel-btn-image {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
    }
}

/* Mobile pequeno (até 480px) */
@media (max-width: 480px) {
    .enap-carousel-container {
        padding: 25px 8px;
    }
    
    .enap-carousel-title p{
        font-size: 30px;
    }
    
    .enap-carousel-subtitle p{
        font-size: 13px;
    }
    
    .enap-carousel-card-inner {
        max-width: 330px;
        min-height: 360px;
        border-radius: 14px;
        -webkit-border-radius: 14px;
        -moz-border-radius: 14px;
    }
    
    .enap-carousel-image,
    .enap-carousel-image-placeholder {
        height: 160px;
        min-height: 160px;
        max-height: 160px;
        border-radius: 14px;
        -webkit-border-radius: 14px;
        -moz-border-radius: 14px;
    }
    
    .enap-carousel-text-container {
        padding: 16px 0;
    }
    
    .enap-carousel-card-title {
        font-size: 1.1rem;
    }
    
    .enap-carousel-card-description {
        font-size: 0.9rem;
    }
    
    .enap-carousel-indicator {
        width: 10px;
        height: 10px;
    }
}

/* Suporte para touch/swipe - Safari */
@media (max-width: 767px) {
    .enap-carousel-wrapper {
        -ms-touch-action: pan-x;
        touch-action: pan-x;
        -webkit-overflow-scrolling: touch;
    }
    
    .enap-carousel-content {
        overflow: hidden;
        -webkit-overflow-scrolling: touch;
    }
}

/* Otimizações específicas para Safari */
.enap-carousel-wrapper {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

.enap-carousel-card-inner {
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}

/* Melhor performance de animação no Safari */
@media (-webkit-min-device-pixel-ratio: 1) {
    .enap-carousel-wrapper {
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
        -webkit-perspective: 1000px;
        perspective: 1000px;
    }
}