/* Estilos compartidos por las pantallas públicas (inicio, login, admin).
   Antes estaban duplicados dentro de index.php y de login.php. */

:root {
    --primary-color: #3b82f6;
    --hover-color: #2563eb;
    --bg-color: #0f172a;
    --text-color: #f8fafc;
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

body {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--bg-color);
    background-image:
        radial-gradient(at 0% 0%, hsla(253, 16%, 7%, 1) 0, transparent 50%),
        radial-gradient(at 50% 0%, hsla(225, 39%, 30%, 1) 0, transparent 50%),
        radial-gradient(at 100% 0%, hsla(339, 49%, 30%, 1) 0, transparent 50%);
    background-size: 200% 200%;
    animation: gradientBG 15s ease infinite;
    color: var(--text-color);
    overflow-x: hidden;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.container {
    text-align: center;
    padding: 2.5rem 2rem;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    max-width: 90%;
    width: 380px;
}

@keyframes slideUp {
    0% { transform: translateY(50px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    font-weight: 300;
    letter-spacing: 3px;
    opacity: 0.9;
}

.church-name {
    font-size: 1.8rem;
    font-weight: 300;
    letter-spacing: 3px;
    margin-bottom: 0.3rem;
}

.subtitle {
    font-size: 0.85rem;
    opacity: 0.45;
    margin-bottom: 1.8rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.church-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.church-btn {
    display: block;
    background: rgba(255, 255, 255, 0.08);
    color: white;
    text-decoration: none;
    padding: 0.9rem 1.5rem;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.12);
    letter-spacing: 0.5px;
}

.church-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.4);
    background: linear-gradient(135deg, var(--primary-color), var(--hover-color));
    border-color: rgba(255, 255, 255, 0.2);
}

.church-btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.no-churches {
    opacity: 0.5;
    font-size: 0.95rem;
    padding: 1rem;
}

.admin-link {
    position: absolute;
    top: 2rem;
    right: 2rem;
    color: rgba(255, 255, 255, 0.4);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 1px solid transparent;
}

.admin-link:hover {
    color: white;
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

/* Formularios */
input[type="password"],
input[type="text"] {
    width: 100%;
    padding: 0.9rem 1.2rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 14px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: all 0.25s ease;
    text-align: center;
    letter-spacing: 1px;
    margin-bottom: 0.6rem;
}

input[type="password"]:focus,
input[type="text"]:focus {
    border-color: rgba(59, 130, 246, 0.6);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.15);
}

input::placeholder {
    color: rgba(255, 255, 255, 0.3);
    letter-spacing: 1px;
}

.btn-enter {
    display: block;
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.9rem;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s ease;
    letter-spacing: 0.5px;
}

.btn-enter:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.4);
}

.btn-enter:active { transform: translateY(1px); }

.error-msg {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #fca5a5;
    padding: 0.6rem 1rem;
    border-radius: 10px;
    font-size: 0.85rem;
    margin-bottom: 1.2rem;
}

.info-msg {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.35);
    color: #bfdbfe;
    padding: 0.6rem 1rem;
    border-radius: 10px;
    font-size: 0.85rem;
    margin-bottom: 1.2rem;
}

.back-link {
    display: inline-block;
    margin-top: 1.5rem;
    color: rgba(255, 255, 255, 0.35);
    text-decoration: none;
    font-size: 0.8rem;
    transition: color 0.2s;
}

.back-link:hover { color: rgba(255, 255, 255, 0.7); }

/* Adornos de fondo */
.circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    z-index: -1;
    opacity: 0.4;
}

.c1 {
    width: 300px;
    height: 300px;
    background: #4f46e5;
    top: -100px;
    left: -100px;
    animation: float 8s infinite alternate;
}

.c2 {
    width: 200px;
    height: 200px;
    background: #ec4899;
    bottom: -50px;
    right: -50px;
    animation: float 10s infinite alternate-reverse;
}

@keyframes float {
    0% { transform: translate(0, 0); }
    100% { transform: translate(30px, 30px); }
}
