/* Descargas — alineado al design system del index (ce-*) */

.ce-downloads {
    max-width: 820px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.ce-downloads__alert {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    background: #fffaf0;
    border: 1px solid #f3dfb0;
    border-left: 4px solid #d99a00;
    border-radius: 10px;
    padding: 0.85rem 1rem;
    font-size: 0.9rem;
    color: #6c5a2e;
}

.ce-downloads__alert i { color: #d99a00; margin-top: 0.1rem; }

/* Card de producto */
.ce-download-card {
    background: white;
    border: 1px solid #eaecf0;
    border-radius: 14px;
    border-top: 4px solid var(--create-imgs-color);
    padding: 1.75rem;
}

.ce-download-card__header {
    display: flex;
    align-items: flex-start;
    gap: 1.1rem;
    margin-bottom: 1.5rem;
}

.ce-download-card__icon {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gral-brand-color);
    color: white;
    font-size: 1.6rem;
    box-shadow: 0 0 0 3px rgba(91, 16, 172, 0.25);
}

.ce-download-card__header .ce-eyebrow { margin-bottom: 0.3rem; }

.ce-download-card__title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--gral-brand-color);
    margin: 0 0 0.35rem;
}

.ce-download-card__lead {
    font-size: 0.92rem;
    color: #6c757d;
    line-height: 1.6;
    margin: 0;
}

.ce-download-card__version {
    display: inline-block;
    margin-left: 0.35rem;
    padding: 0.05rem 0.55rem;
    border-radius: 999px;
    background: rgba(91, 16, 172, 0.1);
    color: var(--create-imgs-color);
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}

/* Pasos */
.ce-download-step { margin-bottom: 1.4rem; }

.ce-download-step__title {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--gral-brand-color);
    margin: 0 0 0.7rem;
}

.ce-download-step__title span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(91, 16, 172, 0.12);
    color: var(--create-imgs-color);
    font-size: 0.72rem;
}

.ce-download-step--inline {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.ce-download-step--inline .ce-download-step__title { margin: 0; }

/* Selector de sistema operativo */
.ce-os-picker {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
}

.ce-os-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.9rem 1rem;
    border: 2px solid #eaecf0;
    border-radius: 12px;
    background: #fbfbfe;
    color: var(--gral-brand-color);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: border-color 0.18s, background 0.18s, box-shadow 0.18s;
}

.ce-os-option i { font-size: 1.25rem; color: var(--create-imgs-color); }

.ce-os-option:hover:not(:disabled) { border-color: rgba(91, 16, 172, 0.45); }

.ce-os-option.is-selected {
    border-color: var(--create-imgs-color);
    background: rgba(91, 16, 172, 0.06);
    box-shadow: 0 0 0 3px rgba(91, 16, 172, 0.12);
}

.ce-os-option:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

/* Tipos de instalador */
.ce-pkg-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.ce-pkg-list__empty {
    font-size: 0.9rem;
    color: #6c757d;
    margin: 0;
}

.ce-pkg-option {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    width: 100%;
    text-align: left;
    padding: 0.75rem 1rem;
    border: 2px solid #eaecf0;
    border-radius: 12px;
    background: white;
    cursor: pointer;
    transition: border-color 0.18s, background 0.18s;
}

.ce-pkg-option:hover { border-color: rgba(91, 16, 172, 0.45); }

.ce-pkg-option.is-selected {
    border-color: var(--create-imgs-color);
    background: rgba(91, 16, 172, 0.05);
}

.ce-pkg-option__head {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    flex-wrap: wrap;
}

.ce-pkg-option__head strong {
    font-size: 0.93rem;
    color: var(--gral-brand-color);
}

.ce-pkg-option__badge {
    padding: 0.05rem 0.5rem;
    border-radius: 999px;
    background: rgba(16, 172, 127, 0.12);
    color: #0b7d5c;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.ce-pkg-option__size {
    margin-left: auto;
    font-size: 0.78rem;
    color: #8a8fa3;
    font-weight: 600;
}

.ce-pkg-option__detail {
    font-size: 0.85rem;
    color: #6c757d;
    line-height: 1.45;
}

.ce-version-select {
    width: auto;
    min-width: 170px;
    border-radius: 8px;
    font-weight: 600;
    color: var(--gral-brand-color);
}

/* Acción */
.ce-download-card__actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    padding-top: 1.1rem;
    border-top: 1px solid #eaecf0;
}

.ce-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.ce-download-btn.is-disabled {
    opacity: 0.5;
    pointer-events: none;
}

.ce-download-card__file {
    margin: 0;
    font-size: 0.8rem;
    color: #8a8fa3;
    font-family: Consolas, "Cascadia Code", monospace;
    word-break: break-all;
}

.ce-download-card__help {
    margin: 1.1rem 0 0;
    font-size: 0.85rem;
    color: #6c757d;
}

.ce-download-card__help a {
    color: var(--create-imgs-color);
    font-weight: 600;
}

.ce-downloads__empty {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #6c757d;
    font-size: 0.92rem;
}

.ce-downloads__empty i { font-size: 1.5rem; color: var(--create-imgs-color); }
.ce-downloads__empty p { margin: 0; }

@media (max-width: 600px) {
    .ce-download-card { padding: 1.25rem; }
    .ce-download-card__header { flex-direction: column; }
    .ce-os-picker { grid-template-columns: 1fr; }
}
