.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 100vh;
    width: 100%;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
}

.auth-container.visible {
    opacity: 1;
}

.auth-image-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 5rem;
    color: var(--foreground);
    overflow: hidden;
    background: url('../img/loginimage.jpg') center/cover;
}

.auth-image-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 10%, rgba(0, 0, 0, 0.1) 80%);
    z-index: 2;
}

.auth-image-panel-content {
    position: relative;
    z-index: 3;
    transform: translateY(20px);
    opacity: 0;
    animation: slideUpFadeIn 1s ease-out 0.5s forwards;
}

.auth-image-panel h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.auth-image-panel p {
    font-size: clamp(1.1rem, 2vw, 1.35rem);
    font-weight: 400;
    max-width: 500px;
    color: var(--muted-foreground);
}

.auth-form-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    background-color: var(--background);
    overflow: hidden;
}

.login-box {
    width: 100%;
    max-width: 420px;
    text-align: center;
    position: relative;
    z-index: 2;
    transform: translateY(20px);
    opacity: 0;
    animation: slideUpFadeIn 1s ease-out 0.7s forwards;
}

.login-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 1rem;
}

.login-header img {
    width: 40px;
    height: 40px;
}

.login-header h2 {
    font-size: clamp(2.25rem, 5vw, 2.75rem);
    font-weight: 800;
    margin: 0;
    color: var(--foreground);
}

.login-header .gold-text {
    background: linear-gradient(145deg, var(--gold-secondary), var(--gold-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-box h3 {
    font-size: clamp(1.6rem, 4vw, 2rem);
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--foreground);
}

.login-box p {
    color: var(--muted-foreground);
    margin-bottom: 32px;
    font-size: clamp(1.1rem, 2.5vw, 1.2rem);
}

.telegram-login-container {
    display: flex;
    justify-content: center;
    min-height: 50px;
    margin-bottom: 2rem;
    transform: scale(1.15);
}

.login-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 1.5rem;
}

.help-link {
    color: var(--muted-foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

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

.powered-by-footer {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: var(--muted-foreground);
    text-align: center;
    width: 100%;
    z-index: 3;
}

.powered-by-footer a {
    color: var(--secondary-foreground);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.powered-by-footer a:hover {
    color: var(--accent);
}

.lang-switcher {
    display: inline-flex;
    background-color: var(--secondary);
    border-radius: 99px;
    padding: 4px;
    position: relative;
}

.lang-slider {
    position: absolute;
    top: 4px;
    height: calc(100% - 8px);
    background-color: var(--accent);
    border-radius: 99px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 2px 10px -3px var(--accent);
}

.lang-switcher button {
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 600;
    color: var(--foreground);
    padding: 6px 16px;
    border-radius: 99px;
    position: relative;
    z-index: 1;
    transition: color 0.3s ease;
}

.lang-switcher button.active {
    color: var(--accent-foreground);
}

.animated-circles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 1;
}

.animated-circles li {
    position: absolute;
    display: block;
    list-style: none;
    width: 20px;
    height: 20px;
    background: rgba(59, 130, 246, 0.15);
    animation: animate-circles 25s linear infinite;
    bottom: 0;
    border-radius: 50%;
}

.animated-circles li:nth-child(1) { left: 25%; width: 80px; height: 80px; animation-delay: 0s; }
.animated-circles li:nth-child(2) { left: 10%; width: 20px; height: 20px; animation-delay: 2s; animation-duration: 12s; }
.animated-circles li:nth-child(3) { left: 70%; width: 20px; height: 20px; animation-delay: 4s; }
.animated-circles li:nth-child(4) { left: 40%; width: 60px; height: 60px; animation-delay: 0s; animation-duration: 18s; }
.animated-circles li:nth-child(5) { left: 65%; width: 20px; height: 20px; animation-delay: 0s; }
.animated-circles li:nth-child(6) { left: 75%; width: 110px; height: 110px; animation-delay: 3s; }
.animated-circles li:nth-child(7) { left: 35%; width: 150px; height: 150px; animation-delay: 7s; }
.animated-circles li:nth-child(8) { left: 50%; width: 25px; height: 25px; animation-delay: 15s; animation-duration: 45s; }
.animated-circles li:nth-child(9) { left: 20%; width: 15px; height: 15px; animation-delay: 2s; animation-duration: 35s; }
.animated-circles li:nth-child(10) { left: 85%; width: 150px; height: 150px; animation-delay: 0s; animation-duration: 11s; }

@keyframes animate-circles {
    0% { transform: translateY(0) rotate(0deg); opacity: 1; bottom: 0; }
    20% { bottom: 50vh; }
    100% { transform: translateY(-1000px) rotate(720deg); opacity: 0; bottom: 100vh; }
}

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

@media (max-width: 900px) {
    .auth-container { grid-template-columns: 1fr; }
    .auth-image-panel { display: none; }
}
