/* ============================================
   ?? DEPOSITOS DISTRITO - DISEÑO MODERNO
   ============================================ */
:root {
    --dd-primary: #7c3aed;
    --dd-primary-dark: #6d28d9;
    --dd-primary-light: #a78bfa;
    --dd-secondary: #10b981;
    --dd-secondary-dark: #059669;
    --dd-white: #ffffff;
    --dd-gray: #64748b;
    --dd-gray-light: #94a3b8;
    --dd-gray-lighter: #cbd5e1;
    --dd-bg: #f8fafc;
    --dd-border: #e2e8f0;
    --dd-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    --dd-shadow-md: 0 6px 16px rgba(0, 0, 0, 0.12);
    --dd-shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.15);
}

/* ============================================
   ?? CONTENEDOR PRINCIPAL
   ============================================ */
.depositosdistrito-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    min-height: 100vh;
    background: var(--dd-bg);
}

/* ============================================
   ?? ENCABEZADO
   ============================================ */
.depositosdistrito-header {
    background: linear-gradient(135deg, var(--dd-primary) 0%, var(--dd-primary-dark) 100%);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: var(--dd-shadow-lg);
    margin-bottom: 2.5rem;
    animation: fadeInDown 0.6s ease-out;
}

.depositosdistrito-header-content {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.depositosdistrito-header-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.depositosdistrito-header-text {
    flex: 1;
}

.depositosdistrito-title {
    font-size: 2rem;
    font-weight: 800;
    color: white;
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.5px;
}

.depositosdistrito-subtitle {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.depositosdistrito-subtitle strong {
    font-weight: 700;
    color: white;
}

/* ============================================
   ?? TARJETA DEL FORMULARIO
   ============================================ */
.depositosdistrito-form-card {
    background: var(--dd-white);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: var(--dd-shadow);
    animation: fadeInUp 0.6s ease-out;
}

/* ============================================
   ?? SECCIONES DEL FORMULARIO
   ============================================ */
.depositosdistrito-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--dd-border);
}

.depositosdistrito-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.depositosdistrito-section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--dd-primary);
    margin: 0 0 1.75rem 0;
}

.depositosdistrito-section-title svg {
    flex-shrink: 0;
}

.depositosdistrito-section-periodo {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.05), rgba(167, 139, 250, 0.05));
    padding: 2rem;
    border-radius: 16px;
    border: 2px solid var(--dd-border);
}

/* ============================================
   ?? GRUPOS DE FORMULARIO
   ============================================ */
.depositosdistrito-form-group {
    margin-bottom: 1.5rem;
}

.depositosdistrito-form-group:last-child {
    margin-bottom: 0;
}

.depositosdistrito-form-group-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.depositosdistrito-form-group-flex {
    display: flex;
    flex-direction: column;
}

.depositosdistrito-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--dd-gray);
    margin-bottom: 0.625rem;
}

.depositosdistrito-label-icon {
    width: 18px;
    height: 18px;
    color: var(--dd-primary);
    flex-shrink: 0;
}

.depositosdistrito-label-small {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--dd-gray);
    margin-bottom: 0.5rem;
}

/* ============================================
   ?? INPUTS Y SELECTS
   ============================================ */
.depositosdistrito-input,
.depositosdistrito-select,
.depositosdistrito-select-small,
.depositosdistrito-textarea {
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    border: 2px solid var(--dd-border);
    border-radius: 12px;
    background: var(--dd-white);
    color: #1e293b;
    transition: all 0.3s ease;
    outline: none;
    font-family: inherit;
}

.depositosdistrito-input:focus,
.depositosdistrito-select:focus,
.depositosdistrito-select-small:focus,
.depositosdistrito-textarea:focus {
    border-color: var(--dd-primary);
    box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.1);
}

.depositosdistrito-input::placeholder,
.depositosdistrito-textarea::placeholder {
    color: var(--dd-gray-light);
}

.depositosdistrito-input-readonly {
    background: var(--dd-bg);
    color: var(--dd-gray);
    cursor: not-allowed;
}

.depositosdistrito-select,
.depositosdistrito-select-small {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%237c3aed' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.depositosdistrito-select-small {
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
}

.depositosdistrito-textarea {
    resize: vertical;
    min-height: 100px;
    line-height: 1.6;
}

/* ============================================
   ?? INPUT DE MONTO
   ============================================ */
.depositosdistrito-input-currency {
    position: relative;
    display: flex;
    align-items: center;
}

.depositosdistrito-currency-symbol {
    position: absolute;
    left: 1rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--dd-primary);
    z-index: 1;
}

.depositosdistrito-input-amount {
    padding-left: 2.5rem;
    font-size: 1.125rem;
    font-weight: 600;
}

/* ============================================
   ?? INPUT DE ARCHIVO
   ============================================ */
.depositosdistrito-file-input-wrapper {
    position: relative;
}

.depositosdistrito-file-input {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
    z-index: 2;
}

.depositosdistrito-file-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2rem;
    border: 2px dashed var(--dd-border);
    border-radius: 12px;
    background: var(--dd-bg);
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.depositosdistrito-file-input-wrapper:hover .depositosdistrito-file-label,
.depositosdistrito-file-input:focus + .depositosdistrito-file-label {
    border-color: var(--dd-primary);
    background: rgba(124, 58, 237, 0.05);
}

.depositosdistrito-file-label svg {
    color: var(--dd-primary);
}

.depositosdistrito-file-label span {
    font-size: 0.9375rem;
    color: var(--dd-gray);
}

/* Estado cuando se ha subido un archivo */
.depositosdistrito-file-label.uploaded {
    border-color: var(--dd-secondary);
    border-style: solid;
    background: rgba(16, 185, 129, 0.05);
}

.depositosdistrito-file-label.uploaded svg {
    color: var(--dd-secondary);
}

.depositosdistrito-file-label.uploaded span {
    color: var(--dd-secondary-dark);
    font-weight: 600;
}

.depositosdistrito-file-success-icon {
    width: 32px;
    height: 32px;
    background: var(--dd-secondary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    animation: scaleIn 0.4s ease-out;
}

.depositosdistrito-file-name {
    font-size: 0.875rem;
    color: var(--dd-gray);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 0.5rem 1rem;
    background: white;
    border-radius: 8px;
    margin-top: 0.5rem;
}

@keyframes scaleIn {
    from {
        transform: scale(0);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* ============================================
   ?? GRUPO DE INPUT CON BOTÓN
   ============================================ */
.depositosdistrito-input-group {
    display: flex;
    gap: 0.75rem;
    align-items: flex-end;
}

.depositosdistrito-input-group .depositosdistrito-select {
    flex: 1;
}

.depositosdistrito-btn-icon {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 12px;
    background: var(--dd-primary);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.depositosdistrito-btn-icon:hover {
    background: var(--dd-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--dd-shadow-md);
}

/* ============================================
   ?? GRID DE PERIODO
   ============================================ */
.depositosdistrito-periodo-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}

/* ============================================
   ?? BOTÓN DE ENVÍO
   ============================================ */
.depositosdistrito-form-actions {
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 2px solid var(--dd-border);
}

.depositosdistrito-btn-submit {
    width: 100%;
    padding: 1.25rem 2rem;
    font-size: 1.125rem;
    font-weight: 700;
    color: white;
    background: linear-gradient(135deg, var(--dd-secondary), var(--dd-secondary-dark));
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
}

.depositosdistrito-btn-submit:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
}

.depositosdistrito-btn-submit:active {
    transform: translateY(-1px);
}

/* ============================================
   ?? MODAL DE INSCRIPCIÓN
   ============================================ */
.depositosdistrito-modal {
    border-radius: 20px;
    overflow: hidden;
}

.depositosdistrito-modal-header {
    background: linear-gradient(135deg, var(--dd-primary), var(--dd-primary-dark));
    color: white;
    padding: 1.75rem 2rem;
    border-bottom: none;
}

.depositosdistrito-modal-header .modal-title {
    display: flex;
    align-items: center;
    font-weight: 700;
    font-size: 1.25rem;
}

.depositosdistrito-modal-header .btn-close {
    filter: brightness(0) invert(1);
    opacity: 0.8;
}

.depositosdistrito-modal-header .btn-close:hover {
    opacity: 1;
}

.depositosdistrito-modal-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.depositosdistrito-modal-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.depositosdistrito-modal-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--dd-gray);
}

.depositosdistrito-modal-input {
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 2px solid var(--dd-border);
    border-radius: 10px;
    outline: none;
    transition: all 0.3s ease;
}

.depositosdistrito-modal-input:focus {
    border-color: var(--dd-primary);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1);
}

.depositosdistrito-modal-total {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.1), rgba(167, 139, 250, 0.1));
    padding: 1.5rem;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.depositosdistrito-modal-total label {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--dd-primary);
    margin: 0;
}

.depositosdistrito-modal-total-amount {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--dd-primary);
}

/* ============================================
   ?? ANIMACIONES
   ============================================ */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   ?? RESPONSIVE - TABLETS
   ============================================ */
@media (max-width: 768px) {
    .depositosdistrito-container {
        padding: 1.5rem 1rem;
    }

    .depositosdistrito-header {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }

    .depositosdistrito-header-content {
        gap: 1rem;
    }

    .depositosdistrito-header-icon {
        width: 60px;
        height: 60px;
    }

    .depositosdistrito-header-icon svg {
        width: 30px;
        height: 30px;
    }

    .depositosdistrito-title {
        font-size: 1.5rem;
    }

    .depositosdistrito-subtitle {
        font-size: 1rem;
    }

    .depositosdistrito-form-card {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }

    .depositosdistrito-section-title {
        font-size: 1.25rem;
    }

    .depositosdistrito-periodo-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .depositosdistrito-modal-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .depositosdistrito-btn-submit {
        padding: 1rem 1.5rem;
        font-size: 1rem;
    }
}

/* ============================================
   ?? RESPONSIVE - MÓVILES
   ============================================ */
@media (max-width: 480px) {
    .depositosdistrito-container {
        padding: 1rem 0.75rem;
    }

    .depositosdistrito-header {
        padding: 1.5rem 1rem;
        margin-bottom: 1.5rem;
    }

    .depositosdistrito-header-content {
        flex-direction: column;
        text-align: center;
    }

    .depositosdistrito-title {
        font-size: 1.375rem;
    }

    .depositosdistrito-subtitle {
        font-size: 0.9375rem;
    }

    .depositosdistrito-form-card {
        padding: 1.5rem 1rem;
    }

    .depositosdistrito-section {
        margin-bottom: 2rem;
        padding-bottom: 1.5rem;
    }

    .depositosdistrito-section-title {
        font-size: 1.125rem;
        gap: 0.5rem;
    }

    .depositosdistrito-section-title svg {
        width: 18px;
        height: 18px;
    }

    .depositosdistrito-label {
        font-size: 0.875rem;
    }

    .depositosdistrito-input,
    .depositosdistrito-select,
    .depositosdistrito-textarea {
        padding: 0.75rem 0.875rem;
        font-size: 0.9375rem;
    }

    .depositosdistrito-file-label {
        padding: 1.5rem 1rem;
    }

    .depositosdistrito-btn-submit {
        padding: 0.875rem 1.25rem;
        font-size: 0.9375rem;
    }

    .depositosdistrito-modal-total {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }

    .depositosdistrito-modal-total-amount {
        font-size: 1.5rem;
    }
}

/* ============================================
   ? ACCESIBILIDAD
   ============================================ */
.depositosdistrito-input:focus,
.depositosdistrito-select:focus,
.depositosdistrito-btn-submit:focus,
.depositosdistrito-btn-icon:focus {
    outline: 3px solid var(--dd-primary);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
