/* ============================================
   LOGIN PAGE - Turbacz OAuth
   ============================================
   Requires: common.css
   ============================================ */

body {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* ============================================
   ANIMATED BACKGROUND
   ============================================ */

.background {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
    animation: float 20s ease-in-out infinite;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--color-primary) 0%, transparent 70%);
    top: -100px;
    left: -100px;
    animation-delay: 0s;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--color-primary-dark) 0%, transparent 70%);
    bottom: -150px;
    right: -150px;
    animation-delay: 7s;
}

.orb-3 {
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, #3b82f6 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-delay: 14s;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(50px, -50px) scale(1.1);
    }

    66% {
        transform: translate(-50px, 50px) scale(0.9);
    }
}

/* ============================================
   LOGIN CONTAINER
   ============================================ */

.login-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 450px;
    padding: var(--spacing-xl);
    animation: slideUp 0.8s ease-out;
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-box {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: var(--spacing-2xl) 2.5rem;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.login-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
            transparent 0%,
            var(--color-primary) 50%,
            transparent 100%);
}

/* ============================================
   LOGO SECTION
   ============================================ */

.logo-section {
    text-align: center;
    margin-bottom: 2.5rem;
}

.logo-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
    animation: pulse 3s ease-in-out infinite;
}

.logo-icon img {
    width: 50px;
    height: 50px;
    filter: brightness(0) invert(1);
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 10px 30px rgba(102, 126, 234, 0.3);
        transform: scale(1);
    }

    50% {
        box-shadow: 0 15px 40px rgba(102, 126, 234, 0.5);
        transform: scale(1.05);
    }
}

.brand-name {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-xs);
}

.subtitle {
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 500;
}

/* ============================================
   WELCOME MESSAGE
   ============================================ */

.welcome-message {
    text-align: center;
    margin-bottom: 2.5rem;
    padding: 0 1rem;
}

.welcome-message h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
}

.welcome-message p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ============================================
   GOOGLE SIGN IN BUTTON
   ============================================ */

.google-signin-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-md);
    width: 100%;
    padding: 1rem 2rem;
    background: white;
    color: #1f2937;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.1),
        0 0 0 0 rgba(66, 133, 244, 0);
    position: relative;
    overflow: hidden;
}

.google-signin-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(66, 133, 244, 0.1), transparent);
    transition: left 0.5s ease;
}

.google-signin-button:hover::before {
    left: 100%;
}

.google-signin-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.15),
        0 0 0 4px rgba(66, 133, 244, 0.1);
    border-color: rgba(66, 133, 244, 0.2);
}

.google-signin-button:active {
    transform: translateY(0);
    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.1),
        0 0 0 2px rgba(66, 133, 244, 0.1);
}

.google-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

/* Loading state */
.google-signin-button.loading {
    pointer-events: none;
    opacity: 0.7;
}

.google-signin-button.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(66, 133, 244, 0.2);
    border-top-color: #4285F4;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ============================================
   INFO TEXT
   ============================================ */

.info-text {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--glass-border);
}

.info-text p {
    color: var(--text-muted);
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.info-text p::before {
    content: '🔒';
    font-size: 1rem;
}

/* ============================================
   DECORATIVE ELEMENTS
   ============================================ */

.decorative-dots {
    display: flex;
    justify-content: center;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-xl);
}

.decorative-dots span {
    width: 8px;
    height: 8px;
    background: var(--color-primary);
    border-radius: 50%;
    opacity: 0.3;
    animation: dotPulse 2s ease-in-out infinite;
}

.decorative-dots span:nth-child(2) {
    animation-delay: 0.3s;
}

.decorative-dots span:nth-child(3) {
    animation-delay: 0.6s;
}

@keyframes dotPulse {

    0%,
    100% {
        opacity: 0.3;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.2);
    }
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .login-container {
        padding: var(--spacing-lg);
    }

    .login-box {
        padding: var(--spacing-xl) var(--spacing-lg);
    }

    .brand-name {
        font-size: 2rem;
    }

    .logo-icon {
        width: 60px;
        height: 60px;
    }

    .logo-icon img {
        width: 36px;
        height: 36px;
    }

    .welcome-message h2 {
        font-size: 1.3rem;
    }

    .welcome-message p {
        font-size: 0.9rem;
    }

    .google-signin-button {
        padding: 0.9rem 1.5rem;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: var(--spacing-md);
    }

    .login-box {
        padding: var(--spacing-lg) var(--spacing-md);
    }

    .brand-name {
        font-size: 1.8rem;
    }

    .welcome-message {
        margin-bottom: var(--spacing-xl);
    }

    .welcome-message h2 {
        font-size: 1.2rem;
    }
}

@media (max-width: 360px) {
    .logo-section {
        margin-bottom: var(--spacing-xl);
    }

    .brand-name {
        font-size: 1.6rem;
    }

    .google-signin-button {
        padding: 0.8rem 1rem;
        font-size: 0.9rem;
    }

    .google-icon {
        width: 20px;
        height: 20px;
    }
}