* {
    box-sizing: border-box;
    font-family: 'Segoe UI', Arial, sans-serif;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Segoe UI', Arial, sans-serif;

    /* Fondo con imagen Unsplash */
    background:
        linear-gradient(rgba(11, 60, 111, 0.88), rgba(31, 157, 255, 0.88)),
        url("https://images.unsplash.com/photo-1522202176988-66273c2fd55f?auto=format&fit=crop&w=1920&q=80")
        center / cover no-repeat fixed;

    display: flex;
    justify-content: center;
    align-items: center;
}

.container {
    background: #ffffff;
    width: 420px;
    padding: 35px;
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0,0,0,.25);
    text-align: center;
}

.container h2, h3 {
    margin-bottom: 20px;
    color: #0b3c6f;
}

label {
    text-align: left;
    display: block;
    margin-top: 15px;
    color: #333;
}

input {
    width: 100%;
    padding: 12px;
    margin-top: 8px;
    border-radius: 8px;
    border: 1px solid #ccc;
}

button, .btn-download, .btn-logout {
    margin-top: 20px;
    width: 100%;
    padding: 12px;
    background: #1f9dff;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 16px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

button:hover,
.btn-download:hover {
    background: #0b7dda;
}

.btn-logout {
    background: #999;
}

.btn-logout:hover {
    background: #666;
}

.alert {
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.alert.error {
    background: #ffe5e5;
    color: #b30000;
}

ul {
    text-align: left;
    margin-top: 15px;
}
/* Botón logout esquina superior */
.top-right {
    position: fixed;
    top: 20px;
    right: 20px;
    width: auto;
    padding: 10px 16px;
    font-size: 14px;
    z-index: 999;
    box-shadow: 0 8px 20px rgba(0,0,0,.25);
}

.top-right:hover {
    background: #666;
}

/* ===== RESULT VIEW ===== */

.result-card {
    width: 100%;
    max-width: 520px;
    background: #ffffff;
    border-radius: 20px;
    padding: 35px;
    box-shadow: 0 30px 60px rgba(0,0,0,.25);
    text-align: center;
}

/* Animación de entrada */
.animate-in {
    animation: fadeUp .6s ease-out;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header éxito */
.result-header {
    margin-bottom: 25px;
}

.result-header.success {
    color: #0b7dda;
}

.result-header .icon {
    font-size: 48px;
    display: block;
    margin-bottom: 10px;
}

.result-header h3 {
    margin: 10px 0 5px;
}

.result-header p {
    color: #555;
    font-size: 15px;
}

/* Errores */
.result-errors {
    background: #fff6e5;
    border-left: 5px solid #f4a000;
    padding: 15px 20px;
    border-radius: 10px;
    text-align: left;
    margin-bottom: 25px;
}

.result-errors h4 {
    margin-top: 0;
    color: #c77d00;
}

.result-errors ul {
    margin: 10px 0 0;
    padding-left: 20px;
}

.result-errors li {
    font-size: 14px;
    margin-bottom: 5px;
}

/* Acciones */
.result-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.btn-download.big {
    font-size: 18px;
    padding: 14px;
    border-radius: 14px;
    box-shadow: 0 12px 25px rgba(31,157,255,.45);
}

.btn-download.big:hover {
    transform: translateY(-2px);
}

.btn-secondary {
    text-decoration: none;
    color: #0b7dda;
    font-size: 14px;
}

.btn-secondary:hover {
    text-decoration: underline;
}
/* ===== ADMIN PANEL ===== */

.admin-menu {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.admin-card {
    background: #f2f7ff;
    padding: 25px;
    border-radius: 14px;
    text-align: center;
    font-weight: bold;
    text-decoration: none;
    color: #0b3c6f;
    box-shadow: 0 12px 25px rgba(0,0,0,.15);
    transition: .2s;
}

.admin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,.25);
}

.btn-admin {
    display: inline-block;
    margin: 20px 0;
    background: #0b3c6f;
    color: white;
    padding: 12px 18px;
    border-radius: 10px;
    text-decoration: none;
}
.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.btn-cancel {
    background: #e0e0e0;
    color: #333;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: .2s;
}

.btn-cancel:hover {
    background: #cfcfcf;
}
.form-actions-vertical {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 25px;
}

.form-actions-vertical button {
    width: 100%;
}

.btn-cancel {
    display: block;
    text-align: center;
    background: #e0e0e0;
    color: #333;
    padding: 10px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: .2s;
}

.btn-cancel:hover {
    background: #cfcfcf;
}
.container-wide {
    width: 80%;
    max-width: none;
}
.container {
    position: relative;
}

.btn-back-top {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #f0f4ff;
    color: #0b3c6f;
    padding: 8px 14px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: .2s;
}

.btn-back-top:hover {
    background: #dbe7ff;
}
.table {
    margin-left: auto;
    margin-right: auto;
    border-collapse: collapse;
}
