/* ============================================
   AUTHENTICATION PAGES – HOSTKART STYLE
   Clean, modern, and conflict-free
============================================ */

/* ---- 1. HIDE DEFAULT WHMCS ELEMENTS (Yellow Circle Area) ---- */
/* This hides breadcrumbs and page headers that come from the default Six theme */
.breadcrumb, 
.header-lined, 
.login-header,
#main-body .header-lined,
#main-body .breadcrumb {
    display: none !important;
}

/* If your theme uses specific IDs for the 'Already Registered' bar */
.login-header + .alert,
.register-container .sub-heading {
    display: none !important;
}

/* ---- 2. Root Variables ---- */
:root {
    --hk-green: #009B4D;
    --hk-yellow: #FFCC00;
    --hk-ivory: #FAF5E9;
    --hk-dark: #111827;
    --hk-card: #FFFFFF;
    --hk-text: #1F2937;
    --hk-muted: #6B7280;
    --hk-radius: 18px;
}

/* ---- 3. Page Container ---- */
.hk-auth-page {
    padding: 60px 20px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--hk-ivory);
}

/* ---- 4. Auth Card ---- */
.hk-auth-card {
    max-width: 480px;
    width: 100%;
    background: #ffffff;
    border-radius: 24px;
    padding: 48px 40px;
    box-shadow: 0 20px 60px rgba(0,155,77,0.06);
    border: 1px solid rgba(0,155,77,0.08);
    position: relative;
    z-index: 1;
}
.hk-register-card {
    max-width: 640px;
}

/* ---- 5. Logo / Branding ---- */
.hk-auth-logo {
    text-align: center;
    margin-bottom: 32px;
}
.hk-auth-logo img {
    max-height: 60px;
    width: auto;
}
.hk-auth-logo h1 {
    font-size: 28px;
    font-weight: 800;
    color: var(--hk-green);
    margin: 0;
}
.hk-auth-logo p {
    color: var(--hk-muted);
    font-size: 15px;
    margin-top: 6px;
}

/* ---- 6. Form Groups & Floating Labels (Pink Circle Logic) ---- */
.hk-auth-card .form-group {
    margin-bottom: 25px;
    position: relative;
}

/* Input Fields */
.hk-auth-card .form-control {
    height: 56px;
    border: 2px solid #e9edf4;
    border-radius: 14px;
    padding: 0 18px 0 46px;
    font-size: 15px;
    font-weight: 500;
    color: var(--hk-text);
    background: #ffffff;
    transition: all .25s ease;
    width: 100%;
    display: block;
}

.hk-auth-card .form-control:focus {
    border-color: var(--hk-green);
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(0,155,77,0.12);
    outline: none;
}

/* Floating Label Positioning */
.hk-auth-card .floating-label label {
    position: absolute;
    left: 42px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    color: #a0aec0;
    pointer-events: none;
    transition: all 0.2s ease;
    font-weight: 500;
    margin: 0;
    padding: 0 6px;
    background: transparent; /* Transparent when resting inside */
    z-index: 5;
}

/* Floating Label HOVER/FOCUS Effect (Moves to Pink Circle Area) */
.hk-auth-card .floating-label input:focus ~ label,
.hk-auth-card .floating-label input:not(:placeholder-shown) ~ label,
.hk-auth-card .floating-label select:focus ~ label,
.hk-auth-card .floating-label select:not([value=""]) ~ label {
    top: 0;
    left: 15px; /* Adjust left to look natural on the border */
    font-size: 12px;
    color: var(--hk-green);
    font-weight: 700;
    background: #ffffff; /* This creates the "cut" in the border line */
    transform: translateY(-50%);
}

/* Fields without icons (e.g., phone) */
.hk-auth-card .floating-label.no-icon .form-control {
    padding-left: 18px;
}
.hk-auth-card .floating-label.no-icon label {
    left: 18px;
}
.hk-auth-card .floating-label.no-icon input:focus ~ label,
.hk-auth-card .floating-label.no-icon input:not(:placeholder-shown) ~ label {
    left: 15px;
}

/* Hide original placeholders so they don't clash with the floating label */
.hk-auth-card .floating-label input::placeholder {
    color: transparent;
}

/* ---- 7. Input Icons ---- */
.hk-auth-card .input-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #a0aec0;
    font-size: 16px;
    pointer-events: none;
    transition: .25s;
    z-index: 4;
}
.hk-auth-card .form-control:focus + .input-icon,
.hk-auth-card .form-control:focus ~ .input-icon {
    color: var(--hk-green);
}

/* ---- 8. Checkbox & Options ---- */
.hk-auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 16px 0 24px;
    flex-wrap: wrap;
    gap: 10px;
}
.hk-auth-options .checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--hk-muted);
    cursor: pointer;
    margin: 0;
}
.hk-auth-options .checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--hk-green);
}

/* ---- 9. Primary Button ---- */
.hk-auth-btn {
    width: 100%;
    height: 54px;
    border: none;
    border-radius: 14px;
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 16px;
    background: linear-gradient(135deg, var(--hk-green), #007a3e);
    color: #fff;
    transition: .3s ease;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}
.hk-auth-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 10px 30px rgba(0,155,77,0.35);
}

/* ---- 10. Social Login ---- */
.hk-social-login {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 20px;
}
.hk-social-login .provider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    height: 48px;
    border: 2px solid #e2e8f0;
    border-radius: 14px;
    font-weight: 600;
    text-decoration: none;
    color: var(--hk-text);
    transition: .25s;
}
.hk-social-login .provider:hover {
    background: #f8fafc;
    transform: translateY(-2px);
}

/* ---- 11. Footer Links ---- */
.hk-auth-footer {
    text-align: center;
    margin-top: 28px;
    font-size: 15px;
    color: var(--hk-muted);
}
.hk-auth-footer a {
    font-weight: 600;
    color: var(--hk-green);
    text-decoration: none;
}
.hk-auth-footer a:hover {
    text-decoration: underline;
}

/* ---- 12. Register Page Specifics ---- */
.hk-section-subtitle {
    font-weight: 700;
    font-size: 18px;
    color: var(--hk-dark);
    margin: 35px 0 20px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--hk-green);
}
.hk-row-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}
.hk-row-full {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* ===== PASSWORD TOGGLE ===== */
.password-toggle-group {
    position: relative;
}
.password-toggle-btn {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #a0aec0;
    font-size: 18px;
    cursor: pointer;
    z-index: 10;
}
.password-toggle-btn:hover {
    color: var(--hk-green);
}

/* Password strength meter */
.password-strength-meter {
    margin-top: 8px;
}
.password-strength-meter .progress {
    height: 6px;
    border-radius: 10px;
    background: #e9edf4;
    overflow: hidden;
}

/* TOS & Marketing */
.hk-marketing-optin, .hk-tos-panel {
    margin: 20px 0;
    padding: 18px;
    background: var(--hk-ivory);
    border-radius: 16px;
    border: 1px solid #e2e8f0;
}

/* ---- 13. Responsive ---- */
@media (max-width: 576px) {
    .hk-row-two-col {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .hk-auth-card {
        padding: 32px 20px;
    }
}