/* Ahs Digital Product - Custom Login Page Styles (Modern Dark Design) */

/* Base & Reset */
:root {
    --bg-dark: #0a0a0a;
    --card-dark: #1a1a1a;
    --border-dark: #2a2a2a;
    --accent-color: #00d4aa;
    --accent-hover: #00e5bb;
    --text-main: #ffffff;
    --text-muted: #888888;
    --text-content: #cccccc;
    --danger: #ff5555;
    --success: #00d4aa;
}

body {
    background-color: var(--bg-dark) !important;
    color: var(--text-main);
    font-family: -apple-system, BlinkMacSystemFont, 'Inter', 'Segoe UI', 'Roboto', sans-serif;
    margin: 0;
}

.ahs-dp-login-wrapper {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    box-sizing: border-box;
}

.ahs-dp-login-container {
    width: 100%;
    max-width: 500px;
    position: relative;
    z-index: 1;
}

/* Card Styling */
.ahs-dp-login-box {
    background: var(--card-dark);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    padding: 25px;
    animation: fadeInUp 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
    border: 1px solid var(--border-dark);
    position: relative;
    overflow: hidden;
}

/* Accent Line */
.ahs-dp-login-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-color), #4dd4ac);
}

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

.ahs-dp-login-header {
    text-align: center;
    margin-bottom: 32px;
}

.ahs-dp-login-logo {
    max-width: 180px;
    height: auto;
    margin-bottom: 20px;
}

.ahs-dp-login-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 8px 0;
    letter-spacing: -0.5px;
}

.ahs-dp-login-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    margin: 0;
}

.ahs-dp-login-form {
    margin: 0;
}

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

.ahs-dp-form-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-content);
    margin-bottom: 8px;
}

/* Input Styling */
/* Input Styling */
.ahs-dp-input {
    width: 100%;
    padding: 12px 16px;
    padding-right: 48px; /* Make space for eye icon */
    font-size: 15px;
    border: 1px solid var(--border-dark) !important;
    border-radius: 8px !important;
    transition: all 0.2s ease;
    background: #0f0f0f !important;
    color: var(--text-main) !important;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
}

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

.ahs-dp-toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-muted);
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.ahs-dp-toggle-password:hover {
    color: var(--accent-color);
}

.ahs-dp-input:focus {
    outline: none;
    border-color: var(--accent-color) !important;
    box-shadow: 0 0 0 3px rgba(0, 212, 170, 0.1) !important;
    background: #151515 !important;
}

.ahs-dp-input::placeholder {
    color: #555 !important;
}

/* Autofill Fix for Dark Theme */
.ahs-dp-input:-webkit-autofill,
.ahs-dp-input:-webkit-autofill:hover, 
.ahs-dp-input:-webkit-autofill:focus, 
.ahs-dp-input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 30px #0f0f0f inset !important;
    -webkit-text-fill-color: var(--text-main) !important;
    transition: background-color 5000s ease-in-out 0s;
}

.ahs-dp-form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    font-size: 14px;
}

.ahs-dp-checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    color: var(--text-muted);
    margin: 0;
    transition: color 0.2s;
}

.ahs-dp-checkbox-label:hover {
    color: var(--text-content);
}

.ahs-dp-checkbox-label input[type="checkbox"] {
    margin-right: 8px;
    cursor: pointer;
    accent-color: var(--accent-color);
}

.ahs-dp-forgot-link {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 600;
}

.ahs-dp-forgot-link:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

/* Button Styling */
.ahs-dp-login-button {
    width: 100%;
    padding: 14px 24px;
    font-size: 15px;
    font-weight: 600;
    color: #0a0a0a;
    background: var(--accent-color);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(0, 212, 170, 0.2);
}

.ahs-dp-login-button:hover {
    background: var(--accent-hover);
    color:rgba(0, 0, 0, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 212, 170, 0.3);
}

.ahs-dp-login-button:active {
    transform: translateY(0);
}

.ahs-dp-login-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.ahs-dp-button-loader {
    display: inline-flex;
    align-items: center;
}

/* Messages */
.ahs-dp-message {
    margin-top: 20px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    animation: fadeIn 0.3s ease;
}

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

.ahs-dp-message-success {
    background: rgba(0, 212, 170, 0.1);
    color: var(--accent-color);
    border: 1px solid rgba(0, 212, 170, 0.3);
}

.ahs-dp-message-error {
    background: rgba(255, 85, 85, 0.1);
    color: var(--danger);
    border: 1px solid rgba(255, 85, 85, 0.3);
}

.ahs-dp-login-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--border-dark);
}

.ahs-dp-login-footer p {
    margin: 0;
    font-size: 14px;
    color: var(--text-muted);
}

.ahs-dp-login-footer a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.ahs-dp-login-footer a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 480px) {
    .ahs-dp-login-box {
        padding: 30px 24px;
    }

    .ahs-dp-login-title {
        font-size: 22px;
    }

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

/* Dark mode overrides not needed as root vars handle it */
@media (prefers-color-scheme: dark) {
    /* Handled by default root vars */
}
