/* ========================================
   LOGIN PAGE - Modern Responsive Styles
   ======================================== */

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    min-height: 100%;
    margin: 0;
    padding: 0;
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: #f5f6fa;
    overflow-x: hidden;
}

/* Login Wrapper - Split Layout */
.login-wrapper {
    display: flex;
    min-height: 100vh;
    min-height: 100dvh;
    width: 100%;
    align-items: stretch;
}

/* Left Side - Welcome Image */
.login-left {
    flex: 1;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #1a5632 0%, #0d3d1f 100%);
}

.login-left-content {
    width: 100%;
    height: 100%;
    position: relative;
}

.welcome-img {
    width: 100%;
    height: 100%;
    min-height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
    /* kayma engelle: sabit merkez, cover kırpma */
}

.welcome-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: #fff;
}

.welcome-overlay h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.welcome-overlay p {
    font-size: 1.1rem;
    opacity: 0.95;
    margin: 0;
}

/* Right Side - Form Area */
.login-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #fff;
    padding: 40px;
    overflow-y: auto;
}

.login-form-container {
    width: 100%;
    max-width: 420px;
    display: block;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Login Logo */
.login-logo {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo img {
    max-width: 280px;
    height: auto;
}

/* Welcome Text */
.login-welcome {
    text-align: center;
    margin-bottom: 35px;
}

.login-welcome h4 {
    font-size: 1.75rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 8px;
}

.login-welcome p {
    color: #7f8c8d;
    font-size: 0.95rem;
    margin: 0;
}

/* Form Styles */
.login-form {
    display: block !important;
    width: 100%;
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #34495e;
    margin-bottom: 8px;
}

/* Input with Icon */
.input-icon-wrapper {
    position: relative;
    display: block;
}

.input-icon-wrapper i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #95a5a6;
    font-size: 1rem;
    transition: color 0.3s ease;
    z-index: 1;
    pointer-events: none;
}

.input-icon-wrapper .form-control {
    display: block;
    width: 100%;
    padding-left: 48px;
    height: 52px;
    border: 2px solid #e0e6ed;
    border-radius: 12px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background-color: #f8f9fb;
    color: #2c3e50;
}

.input-icon-wrapper .form-control:focus {
    border-color: #00a74d;
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(0, 167, 77, 0.1);
    outline: none;
}

.input-icon-wrapper .form-control::placeholder {
    color: #b0bec5;
}

/* Select Dropdown Styling */
.input-icon-wrapper select.form-control {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 40px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2395a5a6' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    cursor: pointer;
}

.input-icon-wrapper select.form-control:focus {
    border-color: #00a74d;
    background-color: #fff;
    box-shadow: 0 0 0 4px rgba(0, 167, 77, 0.1);
    outline: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2300a74d' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
}

/* Form Row Responsive */
.form-row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -10px;
    margin-left: -10px;
}

.form-row > .form-group {
    padding-right: 10px;
    padding-left: 10px;
    flex: 1;
    min-width: 0;
}

@media (max-width: 575.98px) {
    .form-row {
        flex-direction: column;
    }

    .form-row > .form-group {
        padding-right: 0;
        padding-left: 0;
        flex: 0 0 100%;
        max-width: 100%;
    }
}

/* Text Danger Validation */
.text-danger {
    display: block;
    margin-top: 4px;
}

/* Alert Styles */
.alert {
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.alert-success {
    background-color: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}

.alert-danger {
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.alert-warning {
    background-color: #fffbeb;
    border: 1px solid #fde68a;
    color: #92400e;
}

/* Login Options Row */
.login-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.login-options .custom-control {
    position: relative;
    display: block;
    min-height: 1.5rem;
    padding-left: 1.5rem;
}

.login-options .custom-control-label {
    font-size: 0.875rem;
    color: #5d6d7e;
    cursor: pointer;
}

.forgot-password {
    font-size: 0.875rem;
    color: #00a74d;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.forgot-password:hover {
    color: #008a40;
    text-decoration: underline;
}

/* Login Button */
.btn-login {
    display: block !important;
    width: 100%;
    background: linear-gradient(135deg, #00a74d 0%, #008a40 100%);
    border: none;
    color: #fff;
    font-size: 1rem;
    font-weight: 600;
    padding: 14px 24px;
    border-radius: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 167, 77, 0.3);
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 167, 77, 0.4);
    background: linear-gradient(135deg, #00b855 0%, #00a74d 100%);
    color: #fff;
    text-decoration: none;
}

.btn-login:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(0, 167, 77, 0.3);
}

/* Divider */
.login-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 25px 0;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e0e6ed;
}

.login-divider span {
    padding: 0 15px;
    color: #95a5a6;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
}

/* Register Button */
.btn-register {
    display: block !important;
    width: 100%;
    background: #fff;
    border: 2px solid #00a74d;
    color: #00a74d;
    font-size: 1rem;
    font-weight: 600;
    padding: 14px 24px;
    border-radius: 12px;
    transition: all 0.3s ease;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.btn-register:hover {
    background: #00a74d;
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 167, 77, 0.3);
    text-decoration: none;
}

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

/* Login Footer */
.login-footer {
    text-align: center;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #e0e6ed;
}

.login-footer small {
    color: #95a5a6;
    font-size: 0.8rem;
}

/* Alert / Validation Styles */
.alert-danger {
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 0.875rem;
    margin-bottom: 20px;
}

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

/* Tablet (768px - 991px) */
@media (max-width: 991.98px) {
    .login-left {
        display: none;
    }

    .login-right {
        padding: 30px 20px;
    }

    .login-form-container {
        max-width: 100%;
    }
}

/* Mobile Large (576px - 767px) */
@media (max-width: 767.98px) {
    .login-wrapper {
        flex-direction: column;
    }

    .login-left {
        display: block;
        flex: none;
        height: 200px;
        order: 0;
    }

    .welcome-overlay {
        padding: 20px;
    }

    .welcome-overlay h2 {
        font-size: 1.5rem;
    }

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

    .login-right {
        order: 1;
        flex: 1;
        padding: 25px 20px;
        border-radius: 24px 24px 0 0;
        margin-top: -30px;
        position: relative;
        z-index: 1;
    }

    .login-logo img {
        max-width: 200px;
    }

    .login-welcome h4 {
        font-size: 1.5rem;
    }

    .input-icon-wrapper .form-control {
        height: 48px;
        font-size: 0.9rem;
    }

    .btn-login,
    .btn-register {
        padding: 12px 20px;
        font-size: 0.95rem;
    }
}

/* Mobile Small (max 575px) */
@media (max-width: 575.98px) {
    .login-left {
        height: 160px;
    }

    .welcome-overlay {
        padding: 15px;
    }

    .welcome-overlay h2 {
        font-size: 1.25rem;
        margin-bottom: 5px;
    }

    .welcome-overlay p {
        font-size: 0.8rem;
    }

    .login-right {
        padding: 20px 15px;
    }

    .login-logo {
        margin-bottom: 20px;
    }

    .login-logo img {
        max-width: 180px;
    }

    .login-welcome {
        margin-bottom: 25px;
    }

    .login-welcome h4 {
        font-size: 1.3rem;
    }

    .login-welcome p {
        font-size: 0.85rem;
    }

    .login-form .form-group {
        margin-bottom: 16px;
    }

    .input-icon-wrapper .form-control {
        height: 46px;
        font-size: 0.875rem;
        border-radius: 10px;
    }

    .input-icon-wrapper i {
        left: 14px;
    }

    .login-options {
        flex-direction: column;
        gap: 12px;
        align-items: flex-start;
    }

    .btn-login,
    .btn-register {
        padding: 12px 16px;
        border-radius: 10px;
    }

    .login-footer {
        margin-top: 25px;
    }
}

/* Extra Small (max 400px) */
@media (max-width: 399.98px) {
    .login-left {
        height: 120px;
    }

    .welcome-overlay h2 {
        font-size: 1.1rem;
    }

    .login-logo img {
        max-width: 160px;
    }

    .input-icon-wrapper .form-control {
        height: 44px;
        padding-left: 42px;
    }

    .input-icon-wrapper i {
        left: 12px;
        font-size: 0.9rem;
    }
}
