/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Open Sans', sans-serif;
    background-color: #F8F8F8;
    color: #1D1D1B;
    line-height: 1.6;
}

/* Header Styles */
.header {
    background-color: #1A202C;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    position: relative;
    z-index: 100;
}

.logo {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

/* .logo::before {
    content: "THS";
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    font-size: 32px;
    color: white;
    line-height: 1;
    margin-bottom: 4px;
}

.logo::after {
    content: "TRANSPORT HEALTH SAFETY";
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 12px;
    color: white;
    text-transform: uppercase;
    letter-spacing: 1px;
} */

/* Desktop navigation */
.desktop-navigation {
    display: flex;
    align-items: center;
    gap: 30px;
    margin-right: 30px;
}

.nav-item {
    text-decoration: none;
    color: white;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14px;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #E30613;
    transform: translateY(-1px);
}

.nav-item::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: #E30613;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-item:hover::after {
    width: 80%;
}

.contacts {
    display: flex;
    align-items: center;
    gap: 30px;
}

/* Mobile menu toggle button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
    -webkit-tap-highlight-color: transparent;
}

.hamburger-line {
    width: 24px;
    height: 2px;
    background-color: white;
    margin: 3px 0;
    transition: all 0.3s ease;
    transform-origin: center;
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* Mobile menu overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    pointer-events: none; /* Don't block clicks when inactive */
    transition: opacity 0.3s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: auto; /* Enable clicks when menu is open */
}

/* Mobile menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background-color: #1A202C;
    z-index: 999;
    transition: right 0.3s ease;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
    overscroll-behavior: contain; /* Prevent scroll chaining to body */
    touch-action: pan-y; /* Allow vertical swipe scrolling */
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu-content {
    padding: 80px 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.mobile-contacts {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mobile-contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: white;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.mobile-contact-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    padding-left: 10px;
}

.mobile-navigation {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mobile-nav-item {
    display: block;
    text-decoration: none;
    color: white;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 16px;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.mobile-nav-item:hover {
    background-color: rgba(255, 255, 255, 0.1);
    padding-left: 10px;
    color: #E30613;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: white;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14px;
    transition: opacity 0.3s ease;
}

.contact-item:hover {
    opacity: 0.8;
}

.contact-icon {
    width: 16px;
    height: 16px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}



/* Main Page Styles */
.main-page {
    min-height: calc(100vh - 160px);
    display: flex;
    flex-direction: column;
    background-color: #F8F8F8;
    position: relative;
}

.main-page::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #F8F8F8 0%, #F0F0F0 100%);
    z-index: -1;
}

.main-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Hero Section */
.hero-section {
    text-align: center;
    margin-bottom: 60px;
    animation: fadeInUp 0.8s ease-out;
}

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

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}

.main-illustration {
    width: 536px;
    height: 286px;
    background-image: url("/local/templates/ths/images/main-illustration.svg");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    margin-bottom: 20px;
    display: block;
    min-height: 200px;
    background-color: transparent;
}

/* Fallback for mobile devices */
.main-illustration::before {
    content: "";
    display: none;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #E30613 0%, #C5050F 100%);
    border-radius: 8px;
    position: absolute;
    top: 0;
    left: 0;
    z-index: -1;
}

/* Image element styles */
.main-illustration-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    display: none;
}

/* Show image on mobile when background fails */
@media (max-width: 768px) {
    .main-illustration-img {
        display: block;
    }
    
    .main-illustration {
        background-image: none !important;
    }
}

.main-title {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 28px;
    color: #1D1D1B;
    text-align: center;
    line-height: 1.3;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.title-line {
    display: block;
}

/* CTA Section */
.cta-section {
    text-align: center;
    animation: fadeInUp 0.8s ease-out 0.3s both;
}

.action-button {
    display: inline-block;
    background-color: #E30613;
    color: white;
    text-decoration: none;
    padding: 16px 40px;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.3);
    position: relative;
    overflow: hidden;
}

.action-button::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

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

.action-button:hover {
    background-color: #C5050F;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(227, 6, 19, 0.4);
}

.action-button:active {
    transform: translateY(0);
}

.action-button-text {
    display: block;
}

/* Footer Styles */
.footer {
    background-color: #1A202C;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.footer::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 200px;
    height: 1px;
    background-color: white;
}

/* Auth Page Styles */
.auth-page {
    min-height: calc(100vh - 160px);
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #F8F8F8;
    position: relative;
    padding: 40px 20px;
}

.auth-page::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #F8F8F8 0%, #F0F0F0 100%);
    z-index: -1;
}

.auth-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    padding: 50px 40px;
    max-width: 500px;
    width: 100%;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.auth-container::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #E30613 0%, #C5050F 100%);
}

.auth-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #E30613 0%, #C5050F 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    position: relative;
    animation: pulse 2s infinite;
}

.auth-icon::before {
    content: "✓";
    font-size: 36px;
    color: white;
    font-weight: bold;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(227, 6, 19, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(227, 6, 19, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(227, 6, 19, 0);
    }
}

.auth-title {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 28px;
    color: #1D1D1B;
    margin-bottom: 20px;
    line-height: 1.3;
}

.auth-subtitle {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 16px;
    color: #666;
    margin-bottom: 30px;
    line-height: 1.5;
}

.auth-description {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
    text-align: left;
    background: #F8F9FA;
    padding: 20px;
    border-radius: 8px;
    border-left: 4px solid #E30613;
}

.auth-description p {
    margin-bottom: 15px;
}

.auth-description p:last-child {
    margin-bottom: 0;
}

.auth-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 30px;
}

.auth-button {
    display: inline-block;
    background-color: #E30613;
    color: white;
    text-decoration: none;
    padding: 16px 32px;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.3);
    position: relative;
    overflow: hidden;
}

.auth-button::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

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

.auth-button:hover {
    background-color: #C5050F;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(227, 6, 19, 0.4);
}

.auth-button:active {
    transform: translateY(0);
}

.auth-button.secondary {
    background-color: transparent;
    color: #E30613;
    border: 2px solid #E30613;
    box-shadow: none;
}

.auth-button.secondary:hover {
    background-color: #E30613;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(227, 6, 19, 0.4);
}

/* Auth Form Styles */
.bx-system-auth-form {
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    padding: 50px 40px;
    max-width: 500px;
    width: 100%;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.bx-system-auth-form::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #E30613 0%, #C5050F 100%);
}

.bx-system-auth-form table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.bx-system-auth-form td {
    padding: 15px 0;
    border: none;
    vertical-align: top;
}

.bx-system-auth-form input[type="text"],
.bx-system-auth-form input[type="password"] {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    color: #1D1D1B;
    background-color: #F9FAFB;
    transition: all 0.3s ease;
    outline: none;
}

.bx-system-auth-form input[type="text"]:focus,
.bx-system-auth-form input[type="password"]:focus {
    border-color: #E30613;
    background-color: white;
    box-shadow: 0 0 0 3px rgba(227, 6, 19, 0.1);
}

.bx-system-auth-form input[type="text"]::placeholder,
.bx-system-auth-form input[type="password"]::placeholder {
    color: #9CA3AF;
    font-weight: 400;
}

.bx-system-auth-form label {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.bx-system-auth-form input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #E30613;
    cursor: pointer;
}

.bx-system-auth-form input[type="submit"] {
    width: 100%;
    background-color: #E30613;
    color: white;
    border: none;
    padding: 16px 32px;
    border-radius: 8px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.3);
    position: relative;
    overflow: hidden;
}

.bx-system-auth-form input[type="submit"]::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.bx-system-auth-form input[type="submit"]:hover::before {
    left: 100%;
}

.bx-system-auth-form input[type="submit"]:hover {
    background-color: #C5050F;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(227, 6, 19, 0.4);
}

.bx-system-auth-form input[type="submit"]:active {
    transform: translateY(0);
}

.bx-system-auth-form a {
    color: #E30613;
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
    display: inline-block;
    margin: 10px 0;
}

.bx-system-auth-form a:hover {
    color: #C5050F;
    text-decoration: underline;
}

.bx-system-auth-form .bx-auth-secure {
    display: inline-block;
    margin-left: 10px;
    vertical-align: middle;
}

.bx-system-auth-form .bx-auth-secure-icon {
    width: 20px;
    height: 20px;
    background-color: #10B981;
    border-radius: 50%;
    position: relative;
}

.bx-system-auth-form .bx-auth-secure-icon::before {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.bx-system-auth-form .bx-auth-secure-unlock {
    background-color: #EF4444;
}

.bx-system-auth-form .bx-auth-secure-unlock::before {
    content: "!";
}

.bx-system-auth-form .bx-auth-lbl {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 16px;
    color: #1D1D1B;
    margin: 20px 0 15px 0;
    text-align: center;
}

/* Captcha styles */
.bx-system-auth-form img[alt="CAPTCHA"] {
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    margin: 10px 0;
}

/* Error message styles */
.bx-system-auth-form .bx-notetext {
    background-color: #FEF2F2;
    border: 1px solid #FECACA;
    color: #DC2626;
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
}

/* Social services styles */
.bx-system-auth-form .bx-socserv-icons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 20px 0;
}

.bx-system-auth-form .bx-socserv-icons a {
    display: inline-block;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #F3F4F6;
    border: 2px solid #E5E7EB;
    transition: all 0.3s ease;
    text-align: center;
    line-height: 46px;
    font-size: 20px;
}

.bx-system-auth-form .bx-socserv-icons a:hover {
    background-color: #E30613;
    border-color: #E30613;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header {
        padding: 0 20px;
        height: 70px;
    }
    
    .logo::before {
        font-size: 24px;
    }
    
    .logo::after {
        font-size: 10px;
    }
    
    .contacts {
        gap: 20px;
    }
    
    .contact-item {
        font-size: 12px;
    }
    
    .main-container {
        padding: 40px 15px;
    }
    
    .main-illustration {
        width: 100%;
        max-width: 400px;
        height: auto;
        aspect-ratio: 536/286;
    }
    
    .main-title {
        font-size: 22px;
    }
    
    .action-button {
        padding: 14px 30px;
        font-size: 14px;
    }
    
    .footer {
        height: 60px;
    }
    
    .footer::before {
        width: 150px;
    }
    
    /* Auth page mobile styles */
    .auth-page {
        padding: 20px 15px;
        min-height: calc(100vh - 140px);
    }
    
    .auth-container {
        padding: 30px 20px;
        margin: 0;
    }
    
    .auth-title {
        font-size: 24px;
    }
    
    .auth-subtitle {
        font-size: 14px;
    }
    
    .auth-description {
        font-size: 13px;
        padding: 15px;
    }
    
    .auth-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 20px;
    }
    
    .auth-icon::before {
        font-size: 28px;
    }
    
    .auth-button {
        padding: 14px 24px;
        font-size: 14px;
    }
    
    /* Auth form mobile styles */
    .bx-system-auth-form {
        padding: 30px 20px;
        margin: 0 15px;
    }
    
    .bx-system-auth-form input[type="text"],
    .bx-system-auth-form input[type="password"] {
        padding: 14px 16px;
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    .bx-system-auth-form input[type="submit"] {
        padding: 14px 24px;
        font-size: 14px;
    }
    
    .bx-system-auth-form .bx-socserv-icons {
        gap: 10px;
    }
    
    .bx-system-auth-form .bx-socserv-icons a {
        width: 45px;
        height: 45px;
        line-height: 41px;
        font-size: 18px;
    }
}


/* Стили для страниц авторизации */
.auth-info {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 15px;
    margin-bottom: 20px;
}

.auth-info p {
    margin: 0;
    color: #495057;
}

.auth-info a {
    color: #007bff;
    text-decoration: none;
    margin-left: 10px;
}

.auth-info a:hover {
    text-decoration: underline;
}

.auth-message {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
}

/* Стили для формы авторизации Bitrix */
.errortext {
    color: #dc3545;
    font-weight: 500;
    margin-bottom: 20px;
    display: block;
    text-align: center;
    font-size: 16px;
}

.bx-auth {
    max-width: 500px;
    margin: 40px auto;
    padding: 40px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
}

.bx-auth-note {
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 30px;
    font-family: 'Inter', sans-serif;
}

.bx-auth-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.bx-auth-table tr {
    border: none;
}

.bx-auth-table td {
    padding: 12px 0;
    border: none;
    vertical-align: top;
}

.bx-auth-label {
    width: 120px;
    font-weight: 500;
    color: #495057;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
}

.bx-auth-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    background-color: #fff;
    font-family: 'Inter', sans-serif;
}

.bx-auth-input:focus {
    outline: none;
    border-color: #E30613;
    box-shadow: 0 0 0 3px rgba(227, 6, 19, 0.1);
}

.bx-auth-input:hover {
    border-color: #ced4da;
}

/* Стили для чекбокса "Запомнить меня" */
.bx-auth-table tr:nth-child(3) td {
    padding-top: 8px;
    padding-bottom: 20px;
}

.bx-auth-table tr:nth-child(3) input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    accent-color: #E30613;
    cursor: pointer;
}

.bx-auth-table tr:nth-child(3) label {
    font-size: 14px;
    color: #6c757d;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    user-select: none;
}

/* Стили для кнопки входа */
.authorize-submit-cell {
    text-align: center;
    padding-top: 20px;
}

.btn-primary {
    background-color: #E30613;
    border: 2px solid #E30613;
    color: white;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
    min-width: 140px;
}

.btn-primary:hover {
    background-color: #c1050f;
    border-color: #c1050f;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Стили для ссылок под формой */
.bx-auth noindex {
    margin-top: 30px;
}

.bx-auth noindex p {
    text-align: center;
    margin: 8px 0;
}

.bx-auth noindex a {
    color: #E30613;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.bx-auth noindex a:hover {
    color: #c1050f;
    text-decoration: underline;
}

/* Адаптивные стили */
@media (max-width: 768px) {
    .bx-auth {
        margin: 20px;
        padding: 30px 20px;
        border-radius: 8px;
    }

    .bx-auth-note {
        font-size: 16px;
        margin-bottom: 25px;
    }

    .bx-auth-table {
        margin-bottom: 15px;
    }

    .bx-auth-label {
        width: 100px;
        font-size: 13px;
    }

    .bx-auth-input {
        padding: 10px 14px;
        font-size: 16px; /* Предотвращает зум на iOS */
    }

    .btn-primary {
        padding: 12px 30px;
        font-size: 15px;
        width: 100%;
        max-width: 200px;
    }

    .bx-auth noindex a {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .bx-auth {
        margin: 10px;
        padding: 25px 15px;
    }

    .bx-auth-note {
        font-size: 15px;
        margin-bottom: 20px;
    }

    .bx-auth-table td {
        padding: 8px 0;
    }

    .bx-auth-label {
        width: 80px;
        font-size: 12px;
    }

    .bx-auth-input {
        padding: 8px 12px;
        font-size: 15px;
    }

    .btn-primary {
        padding: 10px 25px;
        font-size: 14px;
    }
}

/* Дополнительные стили для улучшения UX */
.bx-auth-input::placeholder {
    color: #adb5bd;
    font-style: italic;
}

.bx-auth-table tr:nth-child(3) {
    background-color: #f8f9fa;
    border-radius: 6px;
    margin: 10px 0;
}

.bx-auth-table tr:nth-child(3) td {
    padding: 15px 12px;
}

/* Анимация появления формы */
.bx-auth {
    animation: fadeInUp 0.6s ease-out;
}

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

/* Стили для фокуса доступности */
.bx-auth-input:focus,
.btn-primary:focus,
.bx-auth noindex a:focus {
    outline: 2px solid #E30613;
    outline-offset: 2px;
}

/* Стили для состояния загрузки */
.btn-primary:disabled {
    background-color: #6c757d;
    border-color: #6c757d;
    cursor: not-allowed;
    transform: none;
}

.btn-primary:disabled:hover {
    background-color: #6c757d;
    border-color: #6c757d;
    transform: none;
    box-shadow: none;
}

/* Общие стили для страницы авторизации */
body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
}

/* Стили для контейнера страницы */
.auth-page-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* Стили для логотипа на странице авторизации */
.auth-logo {
    text-align: center;
    margin-bottom: 30px;
}

.auth-logo .logo {
    display: inline-block;
    width: 80px;
    height: 80px;
    background-color: #E30613;
    border-radius: 50%;
    margin-bottom: 15px;
}

.auth-logo h1 {
    color: #333;
    font-size: 24px;
    font-weight: 600;
    margin: 0;
    font-family: 'Inter', sans-serif;
}

/* Стили для сообщений об ошибках */
.bx-auth .bx-auth-error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
    text-align: center;
}

/* Стили для успешных сообщений */
.bx-auth .bx-auth-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
    text-align: center;
}

/* Улучшенные стили для мобильных устройств */
@media (max-width: 768px) {
    body {
        background: #f8f9fa;
    }

    .auth-page-container {
        padding: 10px;
    }

    .auth-logo h1 {
        font-size: 20px;
    }

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

/* Стили для очень маленьких экранов */
@media (max-width: 480px) {
    .auth-logo h1 {
        font-size: 18px;
    }

    .auth-logo .logo {
        width: 50px;
        height: 50px;
    }
}


/* Стили для формы авторизации */
.bx-auth-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.bx-auth-form .bx-auth-form-title {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

.bx-auth-form .bx-auth-form-field {
    margin-bottom: 15px;
}

.bx-auth-form label {
    display: block;
    margin-bottom: 5px;
    color: #555;
    font-weight: bold;
}

.bx-auth-form input[type="text"],
.bx-auth-form input[type="password"],
.bx-auth-form input[type="email"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.bx-auth-form input[type="checkbox"] {
    margin-right: 5px;
}

.bx-auth-form .bx-auth-form-submit {
    width: 100%;
    padding: 12px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
}

.bx-auth-form .bx-auth-form-submit:hover {
    background-color: #0056b3;
}

.bx-auth-form .bx-auth-form-links {
    text-align: center;
    margin-top: 15px;
}

.bx-auth-form .bx-auth-form-links a {
    color: #007bff;
    text-decoration: none;
    margin: 0 10px;
}

.bx-auth-form .bx-auth-form-links a:hover {
    text-decoration: underline;
}

/* Стили для сообщений об ошибках */
.bx-auth-form .bx-auth-form-error {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
}

/* Стили для успешных сообщений */
.bx-auth-form .bx-auth-form-success {
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
}
/* Стили для формы авторизации на странице статей */

/* Стили для сообщения об ошибке */
.errortext {
    color: #dc3545;
    font-weight: 500;
    margin: 20px 0;
    display: block;
    text-align: center;
    font-size: 16px;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    padding: 12px 16px;
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
}

/* Контейнер для формы авторизации */
.bx-auth {
    max-width: 600px;
    margin: 40px auto;
    padding: 40px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid #e9ecef;
    font-family: 'Inter', sans-serif;
}

/* Заголовок формы */
.bx-auth-note {
    text-align: center;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 30px;
}

/* Таблица формы */
.bx-auth-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.bx-auth-table tr {
    border: none;
}

.bx-auth-table td {
    padding: 12px 0;
    border: none;
    vertical-align: top;
}

/* Лейблы полей */
.bx-auth-label {
    width: 120px;
    font-weight: 500;
    color: #495057;
    font-size: 14px;
}

/* Поля ввода */
.bx-auth-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    background-color: #fff;
    font-family: 'Inter', sans-serif;
}

.bx-auth-input:focus {
    outline: none;
    border-color: #E30613;
    box-shadow: 0 0 0 3px rgba(227, 6, 19, 0.1);
}

.bx-auth-input:hover {
    border-color: #ced4da;
}

/* Строка с чекбоксом "Запомнить меня" */
.bx-auth-table tr:nth-child(3) {
    background-color: #f8f9fa;
    border-radius: 6px;
    margin: 10px 0;
}

.bx-auth-table tr:nth-child(3) td {
    padding: 15px 12px;
}

.bx-auth-table tr:nth-child(3) input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    accent-color: #E30613;
    cursor: pointer;
}

.bx-auth-table tr:nth-child(3) label {
    font-size: 14px;
    color: #6c757d;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    user-select: none;
}

/* Кнопка входа */
.authorize-submit-cell {
    text-align: center;
    padding-top: 20px;
}

.btn-primary {
    background-color: #E30613;
    border: 2px solid #E30613;
    color: white;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
    min-width: 140px;
}

.btn-primary:hover {
    background-color: #c1050f;
    border-color: #c1050f;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(227, 6, 19, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
}

/* Ссылки под формой */
.bx-auth noindex {
    margin-top: 30px;
}

.bx-auth noindex p {
    text-align: center;
    margin: 8px 0;
}

.bx-auth noindex a {
    color: #E30613;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.bx-auth noindex a:hover {
    color: #c1050f;
    text-decoration: underline;
}

/* Адаптивные стили */
@media (max-width: 768px) {
    .bx-auth {
        margin: 20px;
        padding: 30px 20px;
        border-radius: 8px;
    }

    .bx-auth-note {
        font-size: 16px;
        margin-bottom: 25px;
    }

    .bx-auth-table {
        margin-bottom: 15px;
    }

    .bx-auth-label {
        width: 100px;
        font-size: 13px;
    }

    .bx-auth-input {
        padding: 10px 14px;
        font-size: 16px; /* Предотвращает зум на iOS */
    }

    .btn-primary {
        padding: 12px 30px;
        font-size: 15px;
        width: 100%;
        max-width: 200px;
    }

    .bx-auth noindex a {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .bx-auth {
        margin: 10px;
        padding: 25px 15px;
    }

    .bx-auth-note {
        font-size: 15px;
        margin-bottom: 20px;
    }

    .bx-auth-table td {
        padding: 8px 0;
    }

    .bx-auth-label {
        width: 80px;
        font-size: 12px;
    }

    .bx-auth-input {
        padding: 8px 12px;
        font-size: 15px;
    }

    .btn-primary {
        padding: 10px 25px;
        font-size: 14px;
    }
}

/* Анимация появления формы */
.bx-auth {
    animation: fadeInUp 0.6s ease-out;
}

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

/* Стили для фокуса доступности */
.bx-auth-input:focus,
.btn-primary:focus,
.bx-auth noindex a:focus {
    outline: 2px solid #E30613;
    outline-offset: 2px;
}

/* Стили для состояния загрузки */
.btn-primary:disabled {
    background-color: #6c757d;
    border-color: #6c757d;
    cursor: not-allowed;
    transform: none;
}

.btn-primary:disabled:hover {
    background-color: #6c757d;
    border-color: #6c757d;
    transform: none;
    box-shadow: none;
}

/* Дополнительные стили для улучшения UX */
.bx-auth-input::placeholder {
    color: #adb5bd;
    font-style: italic;
}
