/* Login Page Styles matching New Landing Page */

/* Inherit Global Variables from global.css (e.g. --orange-500, --teal-500) */

.login-section {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-block: 150px;
    background-color: var(--body-bg);
}

.login-card {
    width: 100%;
    max-width: 500px;
    background: #fff; /* or var(--card-bg) if defined as white/light-gray */
    padding: 32px;
    border-radius: 32px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    /* border: 1px solid var(--text-secondary-invert); */
    position: relative;
    z-index: 10;
}

h1 {
    text-align: center;
    font-family: 'DG Trika', sans-serif;
    color: var(--text-primary);
    font-size: 28px;
    font-weight: 900;
    margin-bottom: 10px;
}
/* Buttons */
.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
  }
p {
    text-align: center;
    font-family: 'DG Trika', sans-serif;
    color: var(--text-secondary-invert);
    font-size: 16px;
    margin-bottom: 32px;
}

.field {
    margin-bottom: 20px;
    position: relative;
}

.field label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-secondary-invert);
    font-size: 14px;
    font-weight: 500;
}

.field input {
    width: 100%;
    padding: 12px 16px;
    padding-inline-start: 40px; /* space for icon */
    border-radius: 16px;
    background: transparent;
    border: 1px solid var(--text-secondary-invert);
    color: var(--gray-900);
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.field input:focus {
    outline: none;
    border-color: var(--text-primary);
}

.input-icon {
    position: absolute;
    top: 38px; /* adjusted based on label height */
    left: 14px;
    color: var(--text-secondary-invert);
    opacity: 0.7;
    pointer-events: none;
}

:dir(rtl) .field input {
    padding-inline-start: 40px;
}
:dir(rtl) .input-icon {
    left: auto;
    right: 14px;
}

.options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: var(--text-secondary-invert);
    margin-bottom: 24px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}
.toggle-password {
    pointer-events: auto;
    cursor: pointer;
}
 /* =========================
   LOGIN CHECKBOX — THEME BASED
========================= */

.login-checkbox {
    width: 18px;
    height: 18px;
    margin: 0;

    appearance: none;
    -webkit-appearance: none;

    border-radius: 6px;
    border: 2px solid var(--text-secondary-invert);
    background-color: transparent;

    display: inline-grid;
    place-content: center;

    cursor: pointer;
    transition: all 0.2s ease;
}

/* inner check indicator */
.login-checkbox::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 3px;

    background-color: var(--text-primary);
    transform: scale(0);
    transition: transform 0.15s ease-in-out;
}

/* checked state */
.login-checkbox:checked {
    border-color: var(--text-primary);
    background-color: var(--teal-100);
}

.login-checkbox:checked::before {
    transform: scale(1);
}

/* hover */
.login-checkbox:hover {
    border-color: var(--text-primary);
}

/* keyboard focus */
.login-checkbox:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px color-mix(
        in srgb,
        var(--text-primary) 35%,
        transparent
    );
}

/* disabled */
.login-checkbox:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}


/* .btn {
    width: 100%;
    padding: 12px 24px;
    background-color: var(--text-primary) !important;
    border: none;
    color: #fff !important;
    border-radius: 16px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    font-family: inherit;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
} */

.btn:hover {
    transform: scale(1.02);
    /* background: var(--text-primary); */
    opacity: 0.9;
}

.footer-text {
    text-align: center;
    margin-top: 20px;
    font-size: 14px;
    color: var(--text-secondary-invert);
}
 
.footer-text a {
    color: var(--text-primary);
    font-weight: bold;
    text-decoration: none;
}

.footer-text a:hover {
    text-decoration: underline;
}

/* Eye icon toggle */

.forgot-password a {
    color: var(--text-primary);
    font-weight: bold;
    text-decoration: none;
}

.forgot-password a:hover {
    text-decoration: underline;
}

.password-input-wrapper {
    position: relative;
    width: 100%;
}

.eye-toggle-btn,
.generate-toggle-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: var(--text-secondary-invert);
    font-size: 14px;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
}

.eye-toggle-btn {
    right: 12px;
}

.generate-toggle-btn {
    right: 48px;
}

.password-input-wrapper input {
    padding-inline-end: 45px;
}

.password-input-wrapper input.has-double-icon {
    padding-inline-end: 85px;
}



:dir(rtl) .generate-toggle-btn {
    right: auto;
    left: 48px;
}

:dir(rtl) .eye-toggle-btn {
    right: auto;
    left: 10px;
}


/* =====================================
   LOGIN CARD — FULL DARK MODE
===================================== */

body.dark-mode .login-card {
    background-color: var(--card-bg); /* dark card */
    box-shadow: 0 10px 30px rgba(0,0,0,0.45);
}

/* Headings */
body.dark-mode .login-card h1 {
    color: var(--text-primary);
}

body.dark-mode .login-card p {
    color: var(--text-secondary-invert);
}

/* Labels */
body.dark-mode .login-card .field label {
    color: var(--text-secondary-invert);
}

/* Inputs */
body.dark-mode .login-card .field input {
    background-color: transparent;
    border-color: var(--text-secondary);
    color: var(--text-secondary-invert);
}

body.dark-mode .login-card .field input::placeholder {
    color: var(--gray-500);
}

/* Input focus */
body.dark-mode .login-card .field input:focus {
    border-color: var(--text-primary);
    box-shadow: 0 0 0 3px color-mix(
        in srgb,
        var(--text-primary) 25%,
        transparent
    );
}

/* Icons (email + eye) */
body.dark-mode .login-card .input-icon {
    color: var(--text-secondary-invert);
    opacity: 0.8;
}

/* Options text */
body.dark-mode .login-card .options {
    color: var(--text-secondary-invert);
}

/* Checkbox text */
body.dark-mode .login-card .checkbox-label span {
    color: var(--text-secondary-invert);
}

/* Button */
body.dark-mode .login-card .btn {
    background-color: var(--text-primary);
    color: var(--text-primary-invert);
}

/* Footer */
body.dark-mode .login-card .footer-text {
    color: var(--text-secondary-invert);
}

body.dark-mode .login-card .footer-text a {
    color: var(--text-primary);
}


body.dark-mode .eye-toggle-btn,
body.dark-mode .generate-toggle-btn {
    color: var(--text-secondary-invert);
}