:root {
    --primary-dark: #1a2744;
    --primary: #2c3e50;
    --accent-gold: #c9a962;
    --accent-gold-hover: #b8954d;
    --text-dark: #1f2937;
    --text-muted: #6b7280;
    --bg-light: #f8f9fa;
    --white: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cdefs%3E%3Cpattern id='grain' width='100' height='100' patternUnits='userSpaceOnUse'%3E%3Ccircle cx='25' cy='25' r='1' fill='rgba(255,255,255,0.03)'/%3E%3Ccircle cx='75' cy='75' r='1' fill='rgba(255,255,255,0.03)'/%3E%3C/pattern%3E%3C/defs%3E%3Crect width='100' height='100' fill='url(%23grain)'/%3E%3C/svg%3E");
    pointer-events: none;
}

.login-container {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    width: 100%;
    max-width: 500px;
    position: relative;
    z-index: 1;
    animation: slideUp 0.6s ease-out;
}

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

.login-form-header {
    background: linear-gradient(135deg, var(--primary-dark) 0%, #2d4a6f 100%);
    padding: 2rem;
    text-align: center;
}

.logo-icon {
    width: 56px;
    height: 56px;
    background: var(--accent-gold);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 0.75rem;
    box-shadow: 0 4px 12px rgba(201, 169, 98, 0.3);
}

.logo-icon svg {
    width: 32px;
    height: 32px;
    fill: var(--primary-dark);
}

.login-form-header h1 {
    font-family: 'Playfair Display', Georgia, serif;
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.login-form-header p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.85rem;
}

.login-form-body {
    padding: 2rem;
}

.alert-custom {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
}

.alert-custom.error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

.alert-custom svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    margin-top: 2px;
}

.welcome-text {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    color: var(--text-dark);
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 0.4rem;
}

.form-control-custom {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all 0.2s ease;
}

.form-control-custom:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 4px rgba(201, 169, 98, 0.1);
}

.form-control-custom::placeholder {
    color: #9ca3af;
}

.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper svg {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    color: #9ca3af;
}

.input-icon-wrapper:focus-within svg {
    color: var(--accent-gold);
}

.input-icon-wrapper .form-control-custom {
    padding-left: 2.75rem;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
}

.checkbox-custom {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-custom input {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-gold);
}

.checkbox-custom span {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.forgot-link {
    color: var(--accent-gold);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
}

.forgot-link:hover {
    color: var(--accent-gold-hover);
}

.btn-login {
    width: 100%;
    padding: 0.875rem;
    background: linear-gradient(135deg, var(--accent-gold) 0%, var(--accent-gold-hover) 100%);
    color: var(--primary-dark);
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(201, 169, 98, 0.4);
}

.divider {
    display: flex;
    align-items: center;
    margin: 1.25rem 0;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e5e7eb;
}

.divider span {
    padding: 0 0.75rem;
    color: var(--text-muted);
    font-size: 0.75rem;
}

.back-home {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    color: var(--text-muted);
    font-size: 0.85rem;
    text-decoration: none;
}

.back-home:hover {
    color: var(--primary-dark);
}

.back-home svg {
    width: 14px;
    height: 14px;
}

.login-form-footer {
    text-align: center;
    padding: 1.25rem 2rem;
    background: var(--bg-light);
    border-top: 1px solid #e5e7eb;
}

.login-form-footer p {
    color: var(--text-muted);
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
}

.login-form-footer a {
    color: var(--accent-gold);
    text-decoration: none;
    font-weight: 500;
}

@media (max-width: 576px) {
    body { padding: 1rem; }
    .login-container { border-radius: 12px; }
    .login-form-header { padding: 1.5rem; }
    .login-form-body { padding: 1.5rem; }
}
