/* ============== LOGIN IdPC STYLES ============== */

/* ------------- IdPC TABS (solo con legacy mode) ------------- */
.idpc-tabs-container {
    border-bottom: 1px solid #b2b2b2;
    margin-bottom: 32px;
}

.idpc-tabs-wrapper {
    display: flex;
    gap: 2px;
}

.idpc-tab-btn {
    background: #e3e3e3;
    border: none;
    border-radius: 3px 3px 0 0;
    margin-bottom: 2px;
    font-size: 18px;
    font-family: "Titillium Web", sans-serif !important;
    font-weight: 600 !important;
    line-height: 2.5em !important;
    padding: 0 24px;
    cursor: pointer;
    color: #333;
    transition: all 0.2s ease;
}

.idpc-tab-btn.active {
    background: var(--fse-primary);
    color: white;
    border-bottom: 3px solid var(--fse-primary);
    margin-bottom: 0;
}

.idpc-tab-btn:hover:not(.active) {
    background: #d0d0d0;
}

/* ------------- CONTENT AREAS ------------- */
.idpc-login-content {
    display: none;
}

.idpc-login-content.active {
    display: block;
}

/* ------------- IdPC LOGIN SECTION ------------- */
.idpc-login-section {
    text-align: center;
    padding: 24px 16px 8px;
}

.idpc-description {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin-bottom: 32px;
    text-align: left;
}

.idpc-config-hint {
    margin-bottom: 20px;
    padding: 12px 16px;
    border: 1px solid rgba(0, 122, 51, 0.25);
    border-radius: 8px;
    background: rgba(0, 122, 51, 0.08);
    color: #144d28;
    font-size: 14px;
    text-align: left;
}

/* ------------- ACCEDI BUTTON ------------- */
.idpc-button-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 24px;
}

.idpc-accedi-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 48px;
    background-color: var(--fse-primary);
    color: #fff !important;
    border: none;
    border-radius: 4px;
    font-family: "Titillium Web", sans-serif;
    font-size: 20px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.idpc-accedi-btn:hover {
    background-color: var(--fse-primary-dark);
    color: #fff !important;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.idpc-accedi-btn:focus {
    outline: 2px solid var(--fse-primary);
    outline-offset: 2px;
}

.idpc-accedi-icon {
    width: 1.2em;
    height: 1.2em;
    fill: currentColor;
}

/* ------------- INFO LINKS ------------- */
.idpc-info-links {
    margin-top: 16px;
}

.idpc-info-links a {
    color: var(--fse-primary);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
}

.idpc-info-links a:hover {
    color: var(--fse-primary-dark);
    text-decoration: underline;
}

/* ------------- LOGIN FORM (Legacy/Esterni) ------------- */
.login-form {
    max-width: 400px;
    margin: 0 auto;
    padding: 20px;
}

.form-field {
    margin-bottom: 20px;
}

.form-field label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
}

.login-form .input-group {
    position: relative;
}

.login-form .input-group input {
    width: 100%;
    padding: 12px 45px 12px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.2s ease;
}

.login-form .input-group input:focus {
    border-color: var(--fse-primary);
    box-shadow: 0 0 0 2px rgba(var(--fse-primary-rgb), 0.1);
}

.input-icon {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    font-size: 18px;
}

.password-toggle:hover {
    color: var(--fse-primary);
}

.btn-login {
    width: 100%;
    background: var(--fse-primary);
    color: white;
    border: none;
    padding: 12px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-login:hover:not(:disabled) {
    background: var(--fse-primary-dark);
}

.btn-login:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

/* ------------- RESPONSIVE ------------- */
@media (max-width: 824px) {
    .idpc-tabs-wrapper {
        flex-direction: column;
        gap: 4px;
        align-items: stretch;
    }

    .idpc-tab-btn {
        display: block;
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 575.98px) {
    .idpc-accedi-btn {
        width: 100%;
        justify-content: center;
        padding: 14px 24px;
        font-size: 18px;
    }

    .idpc-login-section {
        padding: 16px 8px 8px;
    }
}
