/**
 * Carousel Component Styles
 * All styles related to the dynamic carousel functionality
 */

/* --- Início do Código do Carrossel --- */
.incom-dynamic-carousel-container {
    margin: 2rem 0;
}

.incom-dynamic-carousel {
    position: relative;
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 0 auto;
}

.incom-carousel-wrapper {
    flex: 1;
    overflow: hidden;
    border-radius: 8px;
    padding: 30px 0;
}

.incom-carousel-track {
    display: flex;
    transition: transform 350ms ease;
    cursor: grab;
}

.incom-carousel-track:active {
    cursor: grabbing;
}

.incom-carousel-slide {
    flex-shrink: 0;
    padding: 0 8px;
    box-sizing: border-box;
}

/* Carousel Controls */
.incom-carousel-control {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: var(--incom-bg-medium-mix);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--gcid-secondary-color, #333);
    z-index: 10;
    flex-shrink: 0;
}

.incom-carousel-control:hover:not(:disabled) {
    background: var(--gcid-secondary-color, #007cba);
    color: #fff;
    transform: scale(1.05);
}

.incom-carousel-control:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    transform: none;
}

.incom-carousel-control svg {
    width: 24px;
    height: 24px;
}

/* --- Carousel Controls: Mobile Optimization --- */
@media (max-width: 600px) {
  .incom-dynamic-carousel {
    position: relative;
  }
  .incom-carousel-control {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 11;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    font-size: 0.9rem;
    padding: 0;
  }
  .incom-carousel-control svg {
    width: 16px;
    height: 16px;
  }
  .incom-carousel-control--prev {
    left: 4px;
  }
  .incom-carousel-control--next {
    right: 4px;
  }
  /* Prevent controls from pushing carousel content */
  .incom-carousel-wrapper {
    padding-left: 0px;
    padding-right: 0px;
  }
}

/* Carousel Cards */
.incom-carousel-card {
    background: #fff;
    border: none;
    border-radius: 12px;
    overflow: hidden;
    height: 350px;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.incom-carousel-card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    background: var(--incom-bg-medium-mix);
    transform: translateY(-2px);
}

/* Clickable Product Cards */
.incom-carousel-card--clickable {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
    display: block;
}

.incom-carousel-card--clickable:hover {
    text-decoration: none;
    color: inherit;
}

.incom-carousel-card--clickable .carousel-action-btn {
    display: block;
    width: 100%;
    padding: 0.6rem 1rem;
    background: var(--incom-bg-accent-mix);
    border: none;
    color: var(--gcid-secondary-color, #007cba);
    text-align: center;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
}

.incom-carousel-card--clickable:hover .carousel-action-btn {
    background: var(--gcid-secondary-color, #007cba);
    color: #fff;
}

/* Card Header */
.carousel-card-header {
    padding: 1rem 1rem 0.5rem;
    background: var(--incom-bg-light-mix);
}

.carousel-card-header h3 {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--gcid-secondary-color, #333);
    text-align: center;
}

/* Product Cards */
.incom-carousel-card--product .carousel-card-image {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.incom-carousel-card--product .carousel-card-image img {
    max-width: 100%;
    max-height: 120px;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 6px;
}

.incom-carousel-card--product .carousel-card-content {
    padding: 1rem;
    flex-shrink: 0;
}

.carousel-card-title {
    margin: 0 0 0.5rem 0;
    font-size: 0.9rem;
    font-weight: 500;
    padding-bottom: 0;
    color: var(--gcid-secondary-color, #333);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-clamp: 2;
    overflow: hidden;
}

.carousel-card-price {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

/* Advantage Cards */
.incom-carousel-card--advantage .carousel-card-icon {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem 1rem;
}

.carousel-icon {
    width: 50px;
    height: 50px;
}

.incom-carousel-card--advantage .carousel-card-content {
    padding: 0 1rem 1rem;
    text-align: center;
    flex-shrink: 0;
}

.carousel-card-description {
    margin: 0;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}

/* Card Actions */
.carousel-card-action {
    padding: 1rem;
    flex-shrink: 0;
}

.carousel-action-btn {
    display: block;
    width: 100%;
    padding: 0.6rem 1rem;
    background: var(--incom-bg-accent-mix);
    border: none;
    color: var(--gcid-secondary-color, #007cba);
    text-align: center;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.carousel-action-btn:hover {
    background: var(--gcid-secondary-color, #007cba);
    color: #fff;
    text-decoration: none;
}

/* Installments in carousel cards */
.incom-carousel-card .product-installments {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: #28a745;
    font-weight: 500;
}

.incom-carousel-card .product-installments .installment-interest-free {
    font-size: 0.75rem;
    font-weight: 600;
}
