/* ========== MATHA AYURVEDA EYE HOSPITAL LOGIN - CAPTCHA ALWAYS 1 ROW ========== */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: 'Poppins', 'Inter', sans-serif;
    background: linear-gradient(135deg, #1a5a40 0%, #2a6f4f 50%, #348e67 100%);
    display: flex;
    flex-direction: column;
}

/* ========== ANIMATED BACKGROUND WITH FLOATING ICONS ========== */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

.gradient-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(125deg, 
        rgba(26, 90, 64, 0.95) 0%,
        rgba(42, 111, 79, 0.95) 50%,
        rgba(52, 142, 103, 0.95) 100%);
    animation: gradientShift 12s ease infinite;
    background-size: 200% 200%;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Floating Shapes */
.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(4px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: rgba(255, 255, 255, 0.4);
    animation: float 15s infinite ease-in-out;
}

.shape-1 { width: 80px; height: 80px; top: 8%; left: 5%; animation-delay: 0s; font-size: 32px; }
.shape-2 { width: 110px; height: 110px; bottom: 12%; right: 6%; animation-delay: 2s; font-size: 38px; }
.shape-3 { width: 60px; height: 60px; top: 45%; left: 10%; animation-delay: 4s; font-size: 24px; }
.shape-4 { width: 90px; height: 90px; bottom: 30%; right: 12%; animation-delay: 1s; font-size: 30px; }
.shape-5 { width: 55px; height: 55px; top: 70%; left: 85%; animation-delay: 3s; font-size: 22px; }
.shape-6 { width: 70px; height: 70px; top: 20%; right: 20%; animation-delay: 5s; font-size: 28px; }

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    25% {
        transform: translateY(-25px) rotate(8deg);
    }
    50% {
        transform: translateY(15px) rotate(-6deg);
    }
    75% {
        transform: translateY(-10px) rotate(4deg);
    }
}

/* ========== RESPONSIVE UTILITIES ========== */
.desktop-only {
    display: block;
}

.mobile-only {
    display: none;
}

/* ========== MAIN CONTAINER ========== */
.login-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    min-height: 0;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.login-wrapper {
    max-width: 950px;
    width: 100%;
    display: flex;
    background: transparent;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ========== LEFT SIDE - WHITE BACKGROUND (DESKTOP ONLY) ========== */
.login-brand {
    flex: 1;
    background: white;
    padding: 40px 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-content {
    text-align: center;
}

.hospital-logo-large {
    margin-bottom: 20px;
}

.hospital-logo-large img {
    width: 140px;
    height: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
    transition: transform 0.3s ease;
}

.hospital-logo-large img:hover {
    transform: scale(1.02);
}

.hospital-name {
    font-size: 22px;
    font-weight: 700;
    color: #1a5a40;
    margin-bottom: 8px;
    line-height: 1.3;
}

.hospital-name span {
    font-weight: 400;
    font-size: 16px;
    color: #2a6f4f;
    display: block;
    margin-top: 4px;
}

.tagline {
    color: #6b7280;
    font-size: 11px;
    letter-spacing: 1.5px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e5e7eb;
    display: inline-block;
}

.brand-features {
    text-align: left;
    margin-top: 15px;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #374151;
    font-size: 11px;
}

.feature i {
    font-size: 12px;
    color: #2a6f4f;
}

/* ========== RIGHT SIDE - LIGHT GREEN FORM ========== */
.login-form-section {
    flex: 1;
    background: linear-gradient(135deg, #e8f5e9, #dcfce7);
    padding: 35px 30px;
}

.form-wrapper {
    max-width: 320px;
    margin: 0 auto;
}

/* Mobile Logo Styles - 100px on mobile */
.mobile-logo {
    text-align: center;
    margin-bottom: 15px;
}

.mobile-logo img {
    width: 100px;
    height: auto;
}

.form-header {
    text-align: center;
    margin-bottom: 20px;
}

.form-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1a5a40;
    letter-spacing: 1px;
}

/* Input Groups */
.input-group {
    position: relative;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    background: white;
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 1px solid #d1d5db;
}

.input-icon {
    padding: 0 14px;
    color: #9ca3af;
    font-size: 14px;
    transition: all 0.3s ease;
}

.input-group input {
    width: 100%;
    padding: 11px 14px 11px 0;
    font-size: 13px;
    border: none;
    background: transparent;
    outline: none;
    font-weight: 500;
    color: #1f2937;
}

.input-group input::placeholder {
    color: #cbd5e1;
    font-weight: 400;
    font-size: 12px;
}

.input-border {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #2a6f4f, #4caf7c);
    transition: width 0.3s ease;
}

.input-group.focused {
    border-color: #4caf7c;
    box-shadow: 0 0 0 3px rgba(76, 175, 124, 0.1);
}

.input-group.focused .input-border {
    width: 100%;
}

.input-group.focused .input-icon {
    color: #2a6f4f;
}

/* Password Toggle */
.password-group {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 14px;
    cursor: pointer;
    color: #9ca3af;
    font-size: 14px;
    transition: all 0.3s ease;
    z-index: 2;
}

.toggle-password:hover {
    color: #2a6f4f;
}

/* CAPTCHA - Always Single Row */
.captcha-row {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    align-items: center;
    flex-wrap: nowrap;
}

.captcha-code {
    flex: 1;
    background: white;
    border-radius: 12px;
    padding: 8px;
    text-align: center;
    border: 1px solid #d1d5db;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 100px;
}

.captcha-code:hover {
    border-color: #4caf7c;
    transform: scale(1.02);
}

.captcha-code span {
    font-size: 13px;
    font-weight: 700;
    color: #2a6f4f;
    letter-spacing: 1px;
}

.refresh-captcha {
    width: 40px;
    height: 40px;
    background: white;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    cursor: pointer;
    color: #2a6f4f;
    font-size: 14px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.refresh-captcha:hover {
    background: #2a6f4f;
    border-color: #2a6f4f;
    color: white;
    transform: rotate(180deg);
}

.captcha-input {
    width: 95px;
    padding: 10px 8px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    font-size: 13px;
    outline: none;
    transition: all 0.3s ease;
    text-align: center;
    letter-spacing: 2px;
    font-weight: 600;
    background: white;
    flex-shrink: 0;
}

.captcha-input:focus {
    border-color: #4caf7c;
    box-shadow: 0 0 0 3px rgba(76, 175, 124, 0.1);
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    position: relative;
    padding-left: 24px;
    cursor: pointer;
    font-size: 12px;
    color: #6b7280;
    user-select: none;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 16px;
    width: 16px;
    background-color: white;
    border: 1.5px solid #d1d5db;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.checkbox-container:hover input ~ .checkmark {
    border-color: #4caf7c;
}

.checkbox-container input:checked ~ .checkmark {
    background: linear-gradient(135deg, #2a6f4f, #4caf7c);
    border-color: #2a6f4f;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 1.5px 1.5px 0;
    transform: rotate(45deg);
}

.checkbox-text {
    font-size: 11px;
}

.forgot-link {
    color: #2a6f4f;
    text-decoration: none;
    font-size: 11px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.forgot-link:hover {
    color: #4caf7c;
    text-decoration: underline;
}

/* IP Address */
.ip-address {
    text-align: center;
    padding: 8px 0;
    margin-bottom: 16px;
    font-size: 11px;
    color: #6b7280;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.ip-address i {
    color: #2a6f4f;
    font-size: 11px;
}

.ip-address span {
    font-weight: 500;
}

/* Login Button */
.login-btn {
    width: 100%;
    padding: 11px;
    background: linear-gradient(135deg, #2a6f4f, #4caf7c);
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 15px -5px rgba(42, 111, 79, 0.4);
    background: linear-gradient(135deg, #348e67, #5cbf85);
}

.login-btn:active {
    transform: translateY(0);
}

.login-btn i {
    font-size: 13px;
    transition: transform 0.3s ease;
}

.login-btn:hover i {
    transform: translateX(3px);
}

/* Form Footer */
.form-footer {
    margin-top: 18px;
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 18px;
}

.form-footer a {
    color: #9ca3af;
    text-decoration: none;
    font-size: 10px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.form-footer a:hover {
    color: #2a6f4f;
}

/* Footer - Fixed at Bottom */
.hospital-footer {
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
    padding: 6px 16px;
    text-align: center;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.footer-content {
    max-width: 950px;
    margin: 0 auto;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.7);
}

.brand-name {
    color: #8bd8a5;
    font-weight: 700;
}

.geosys-link {
    color: #8bd8a5;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.geosys-link:hover {
    color: white;
    text-decoration: underline;
}

/* ========== MOBILE RESPONSIVE ========== */
@media (max-width: 768px) {
    /* Hide left panel on mobile */
    .desktop-only {
        display: none !important;
    }
    
    /* Show mobile logo */
    .mobile-only {
        display: block;
    }
    
    /* Full width form on mobile */
    .login-wrapper {
        max-width: 100%;
        flex-direction: column;
        height: auto;
    }
    
    .login-form-section {
        padding: 20px 20px;
        border-radius: 24px;
        width: 100%;
    }
    
    .form-wrapper {
        max-width: 100%;
    }
    
    .form-header {
        margin-bottom: 16px;
    }
    
    .form-header h2 {
        font-size: 22px;
    }
    
    /* Keep captcha in single row - no wrap */
    .captcha-row {
        gap: 8px;
        flex-wrap: nowrap;
    }
    
    .captcha-code {
        min-width: 90px;
        padding: 6px;
    }
    
    .captcha-code span {
        font-size: 15px;
    }
    
    .refresh-captcha {
        width: 38px;
        height: 38px;
    }
    
    .captcha-input {
        width: 85px;
        padding: 8px 6px;
    }
    
    /* Input adjustments */
    .input-group {
        margin-bottom: 14px;
    }
    
    .input-group input {
        padding: 10px 12px 10px 0;
        font-size: 13px;
    }
    
    .ip-address {
        margin-bottom: 14px;
        padding: 6px 0;
    }
    
    .login-btn {
        padding: 10px;
    }
    
    /* Floating shapes */
    .shape {
        opacity: 0.2;
    }
    
    .shape-1, .shape-3, .shape-5 {
        display: none;
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: 12px;
    }
    
    .login-form-section {
        padding: 16px 16px;
    }
    
    /* Logo 100px as requested */
    .mobile-logo img {
        width: 100px;
    }
    
    .form-header h2 {
        font-size: 20px;
    }
    
    /* Keep captcha in single row */
    .captcha-row {
        gap: 6px;
    }
    
    .captcha-code {
        min-width: 80px;
        padding: 5px;
    }
    
    .captcha-code span {
        font-size: 12px;
    }
    
    .refresh-captcha {
        width: 35px;
        height: 35px;
        font-size: 12px;
    }
    
    .captcha-input {
        width: 75px;
        padding: 7px 5px;
        font-size: 12px;
    }
    
    .input-group {
        margin-bottom: 12px;
    }
    
    .input-group input {
        padding: 9px 10px 9px 0;
        font-size: 12px;
    }
    
    .input-icon {
        padding: 0 10px;
        font-size: 13px;
    }
    
    .form-options {
        margin-bottom: 10px;
    }
    
    .checkbox-text, .forgot-link {
        font-size: 10px;
    }
    
    .ip-address {
        margin-bottom: 12px;
        font-size: 10px;
        padding: 5px 0;
    }
    
    .login-btn {
        padding: 9px;
        font-size: 13px;
    }
    
    .form-footer {
        margin-top: 12px;
        gap: 12px;
    }
    
    .form-footer a {
        font-size: 9px;
    }
    
    .footer-content {
        font-size: 8px;
    }
}

/* For very small screens - ensure captcha still in single row */
@media (max-width: 380px) {
    .captcha-row {
        gap: 5px;
    }
    
    .captcha-code {
        min-width: 70px;
    }
    
    .captcha-code span {
        font-size: 10px;
    }
    
    .refresh-captcha {
        width: 32px;
        height: 32px;
    }
    
    .captcha-input {
        width: 65px;
        font-size: 11px;
    }
}

/* For extremely small screens - maintain single row with smaller sizes */
@media (max-width: 340px) {
    .captcha-code {
        min-width: 65px;
    }
    
    .captcha-code span {
        font-size: 12px;
    }
    
    .refresh-captcha {
        width: 30px;
        height: 30px;
    }
    
    .captcha-input {
        width: 60px;
        padding: 6px 4px;
    }
}