.ds-frontend {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    max-width: 560px;
    margin: 32px auto;
    padding: 0 16px;
}

.ds-login-box {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.08);
    padding: 40px 36px;
}

.ds-login-header {
    text-align: center;
    margin-bottom: 28px;
}

.ds-login-icon {
    font-size: 40px;
    margin-bottom: 12px;
}

.ds-login-header h2 {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 700;
    color: #1a1a1a;
}

.ds-login-header p {
    color: #666;
    font-size: 14px;
    margin: 0;
    line-height: 1.5;
}

.ds-alert {
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.4;
}

.ds-alert-error {
    background: #fdf2f2;
    border: 1px solid #fbd5d5;
    color: #c81e1e;
}

.ds-alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #15803d;
}

.ds-login-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.ds-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ds-field label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    letter-spacing: 0.01em;
}

.ds-field input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #d1d5db;
    border-radius: 7px;
    font-size: 15px;
    color: #1a1a1a;
    background: #fafafa;
    transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
    box-sizing: border-box;
    outline: none;
    -webkit-appearance: none;
}

.ds-field input:focus {
    border-color: #0073aa;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.12);
}

.ds-btn-primary {
    margin-top: 8px;
    padding: 12px 20px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: background 0.15s, transform 0.1s;
    letter-spacing: 0.01em;
}

.ds-btn-primary:hover {
    background: #005f8a;
}

.ds-btn-primary:active {
    transform: scale(0.99);
}

.ds-help-text {
    text-align: center;
    font-size: 12px;
    color: #9ca3af;
    margin: 20px 0 0;
}

.ds-area-documenti {
    max-width: 700px;
}

.ds-documenti-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f0f0f0;
    flex-wrap: wrap;
    gap: 12px;
}

.ds-benvenuto {
    display: flex;
    align-items: center;
    gap: 14px;
}

.ds-icon-doc {
    font-size: 36px;
    flex-shrink: 0;
}

.ds-benvenuto h2 {
    margin: 0 0 4px;
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
}

.ds-benvenuto p {
    margin: 0;
    font-size: 14px;
    color: #666;
}

.ds-btn-secondary {
    padding: 8px 16px;
    background: #fff;
    color: #555;
    border: 1.5px solid #d1d5db;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s;
    white-space: nowrap;
}

.ds-btn-secondary:hover {
    background: #f5f5f5;
    border-color: #bbb;
    color: #333;
    text-decoration: none;
}

.ds-empty-state {
    text-align: center;
    padding: 48px 20px;
    color: #888;
}

.ds-empty-icon {
    font-size: 48px;
    display: block;
    margin-bottom: 12px;
    opacity: 0.5;
}

.ds-empty-state p {
    margin: 0 0 6px;
    font-size: 15px;
}

.ds-empty-state .ds-sub {
    font-size: 13px;
    color: #aaa;
}

.ds-file-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ds-file-item {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 14px 16px;
    transition: box-shadow 0.15s, border-color 0.15s;
}

.ds-file-item:hover {
    border-color: #0073aa;
    box-shadow: 0 2px 12px rgba(0, 115, 170, 0.1);
}

.ds-file-icon {
    font-size: 28px;
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f4f7fa;
    border-radius: 8px;
}

.ds-file-info {
    flex: 1;
    min-width: 0;
}

.ds-file-name {
    font-weight: 600;
    font-size: 14px;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 2px;
}

.ds-file-desc {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ds-file-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.ds-badge-ext {
    display: inline-block;
    padding: 1px 7px;
    background: #e0f2fe;
    color: #0369a1;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.ds-file-size,
.ds-file-date {
    font-size: 11px;
    color: #9ca3af;
}

.ds-btn-download {
    flex-shrink: 0;
    padding: 8px 14px;
    background: #0073aa;
    color: #fff !important;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none !important;
    transition: background 0.15s;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.ds-btn-download:hover {
    background: #005f8a;
    color: #fff !important;
    text-decoration: none !important;
}

.ds-footer-note {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #f0f0f0;
    font-size: 11px;
    color: #aaa;
    text-align: center;
}

@media (max-width: 480px) {
    .ds-login-box {
        padding: 28px 20px;
    }
    .ds-file-item {
        flex-wrap: wrap;
    }
    .ds-btn-download {
        width: 100%;
        justify-content: center;
    }
    .ds-documenti-header {
        flex-direction: column;
        align-items: flex-start;
    }
}
