:root {
    --bg-color: #030014;
    --text-primary: #f5f5f7;
    --text-secondary: #86868b;
    --primary: #6366f1;
    --primary-glow: rgba(99, 102, 241, 0.15);
    --secondary: #a855f7;
    --accent: #06b6d4;
    --card-bg: rgba(255, 255, 255, 0.03);
    --card-border: rgba(255, 255, 255, 0.08);
    --card-border-active: rgba(99, 102, 241, 0.4);
    --success: #10b981;
    --error: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Gradientes Decorativos de Fondo */
.gradient-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
}

.g1, .g2 {
    position: absolute;
    border-radius: 50%;
    filter: blur(140px);
    opacity: 0.45;
}

.g1 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--primary) 0%, transparent 80%);
    top: -10%;
    right: 10%;
    animation: pulse 12s infinite alternate;
}

.g2 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--secondary) 0%, transparent 80%);
    bottom: 20%;
    left: -10%;
    animation: pulse 15s infinite alternate-reverse;
}

@keyframes pulse {
    0% { transform: scale(1) translate(0, 0); }
    100% { transform: scale(1.2) translate(50px, 30px); }
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 5%;
    border-bottom: 1px solid var(--card-border);
    backdrop-filter: blur(20px);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo-icon {
    font-size: 1.8rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.logo-text {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--text-primary);
}

/* Contenedor Principal */
.main-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

/* Hero Section */
.hero {
    text-align: center;
    margin-bottom: 4rem;
}

.hero-title {
    font-family: 'Outfit', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #ffffff, #a8a8af);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Glass Card */
.glass-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 24px;
    padding: 2.5rem;
    backdrop-filter: blur(16px);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    margin-bottom: 3rem;
}

.card-header {
    margin-bottom: 2rem;
}

.card-header h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.card-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Formulario */
.grid-form {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2.5rem;
}

.form-inputs {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.input-group input, 
.input-group select, 
.input-group textarea {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 0.85rem 1rem;
    color: var(--text-primary);
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s;
}

.input-group input:focus, 
.input-group select:focus, 
.input-group textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 10px var(--primary-glow);
}

.input-group textarea {
    resize: none;
}

.input-group select option {
    background: var(--bg-color);
    color: var(--text-primary);
}

/* Zona de Carga de Archivos */
.upload-zone-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.upload-zone-container > label {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.upload-dropzone {
    flex: 1;
    border: 2px dashed var(--card-border);
    border-radius: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.01);
    transition: all 0.3s ease;
    position: relative;
    min-height: 200px;
}

.upload-dropzone.dragover {
    border-color: var(--primary);
    background: var(--primary-glow);
    transform: scale(1.02);
}

.dropzone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.8rem;
    pointer-events: none;
}

.upload-icon {
    font-size: 2.5rem;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.primary-text {
    font-size: 1rem;
    font-weight: 500;
}

.primary-text span {
    color: var(--primary);
    text-decoration: underline;
}

.secondary-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
    max-width: 250px;
}

.file-hidden {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0;
    cursor: pointer;
}

/* Caja de previsualización del Hash */
.hash-preview-box {
    background: rgba(99, 102, 241, 0.05);
    border: 1px solid var(--card-border-active);
    border-radius: 16px;
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    animation: fadeIn 0.4s ease-out;
}

.hash-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 0.5rem;
}

.file-name {
    font-weight: 600;
    color: var(--text-primary);
    word-break: break-all;
}

.file-size {
    font-size: 0.85rem;
    color: var(--text-secondary);
    flex-shrink: 0;
}

.hash-body {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.hash-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--accent);
}

.hash-code {
    font-family: monospace;
    font-size: 0.85rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.6rem;
    border-radius: 8px;
    word-break: break-all;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.btn-remove {
    background: none;
    border: none;
    color: var(--error);
    cursor: pointer;
    font-size: 0.85rem;
    align-self: flex-start;
    padding: 0.2rem 0;
    transition: opacity 0.3s;
}

.btn-remove:hover {
    opacity: 0.8;
}

/* Acciones Formulario */
.form-actions {
    grid-column: span 2;
    margin-top: 1.5rem;
}

/* Botones */
.btn {
    padding: 0.85rem 1.8rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid var(--card-border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
}

.btn-block {
    display: block;
    width: 100%;
}

/* Tabla de Registros */
.table-container {
    overflow-x: auto;
    margin-top: 1rem;
}

.records-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.records-table th {
    padding: 1rem;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--card-border);
}

.records-table td {
    padding: 1.2rem 1rem;
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.table-title {
    font-weight: 600;
}

.hash-short {
    font-family: monospace;
    background: rgba(255, 255, 255, 0.04);
    padding: 0.3rem 0.5rem;
    border-radius: 6px;
    font-size: 0.8rem;
}

.badge {
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-blue { background: rgba(59, 130, 246, 0.15); color: #60a5fa; }
.badge-purple { background: rgba(168, 85, 247, 0.15); color: #c084fc; }
.badge-success { background: rgba(16, 185, 129, 0.15); color: #34d399; }

/* Utilidades */
.hidden {
    display: none !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Footer */
.footer {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-secondary);
    font-size: 0.85rem;
    border-top: 1px solid var(--card-border);
}

/* Adaptabilidad Móvil */
@media (max-width: 768px) {
    .grid-form {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        grid-column: 1;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .navbar {
        flex-direction: column;
        gap: 1rem;
        padding: 1rem;
    }
}
