/* #region Form Messages */
.form-message {
    margin: 10px 0;
}

.form-message .success {
    color: #388e3c;
    padding: 10px;
    background: #e8f5e9;
    border-radius: 4px;
    margin-bottom: 10px;
}

.form-message .error {
    color: red;
    padding: 10px;
    background: #ffebee;
    border-radius: 4px;
    margin-bottom: 10px;
}

.field-note {
    font-size: 0.85em;
    color: #666;
    margin: 5px 0 0;
}

/* #endregion Form Messages */


/* #region Unified Login/Logout Form */
/* Typography */
.discourse-advanced__unified-form-container h3 {
    margin: 1em 0;
    font-size: 1.5rem;
}

.discourse-advanced__login-instructions {
    font-size: 0.9rem;
    margin-block-start: -1em;
}

@media (min-width: 760px) {
    .discourse-advanced__login-instructions {
        font-size: 1rem;
    }
}

@media (min-width: 1200px) {
    .discourse-advanced__login-instructions {
        font-size: 1.3rem;
    }
}

.discourse-advanced__unified-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    font-size: 1.2rem;
}

.discourse-advanced__lost-password {
    color: #000;
    font-size: 0.8em;
    opacity: 0.8;
    text-decoration: none;
}

.discourse-advanced__go-back-link {
    display: inline-block;
    position: relative;
    margin-top: 15px;
    color: #666;
    text-decoration: none;
    font-size: 0.9em;
}

.discourse-advanced__go-back-link::before {
    content: "";
    position: absolute;
    bottom: 3px;
    right: 0;
    width: 96%;
    height: 1px;
    background-color: #666;
    transform: scaleX(0);
}

.discourse-advanced__go-back-link:hover::before {
    transform: scaleX(1);
}

/* Layout */
.discourse-advanced__unified-form-container {
    max-width: 800px;
    margin: 0 auto;
    min-height: 50vh;
}

.discourse-advanced__unified-step {
    display: none;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 4px;
    margin-bottom: 20px;
}

.discourse-advanced__unified-step.active {
    display: block;
}

.discourse-advanced__unified-form .form-group {
    margin-bottom: 15px;
}

.discourse-advanced__unified-form input[type="text"],
.discourse-advanced__unified-form input[type="email"],
.discourse-advanced__unified-form input[type="password"] {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.discourse-advanced__unified-form input[readonly] {
    background-color: #f5f5f5;
    cursor: not-allowed;
}

.discourse-advanced__unified-form-container .submit-button {
    padding: 10px 20px;
    background-color: #0b4fa0 !important;
    color: white !important;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
}

.discourse-advanced__unified-form-container .submit-button:hover {
    background-color: #0095cc !important;
}

.discourse-advanced__unified-form-container .submit-button:disabled {
    background-color: #ccc !important;
    cursor: not-allowed;
}

.discourse-advanced__unified-form-container .submit-button.success {
    display: none;
}

/* #endregion Unified Login/Logout Form */


/* #region render_logout_button */
.discourse-advanced__logout-button {
    color: inherit;
    text-decoration: none;
}

/* #endregion render_logout_button */

/* #region discourse_register */
.captcha-container {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #e9ecef;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100px;
}

.captcha-container iframe {
    margin: 0 auto;
}

.h-captcha,
.g-recaptcha {
    display: flex;
    justify-content: center;
}

/* #endregion discourse_register */

/* #region discourse_profile_edit */
.discourse-advanced__profile-edit {
    display: grid;
    gap: 20px;
    margin: 1.5em;
}

@media (min-width: 760px) {
    .discourse-advanced__profile-edit {
        margin: 0;
    }
}

.discourse-advanced__profile-dashboard {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 50px;
    margin-bottom: 20px;
}

@media (min-width: 1200px) {
    .discourse-advanced__profile-dashboard {
        flex-direction: row;
        gap: 100px;
    }
}

.discourse-advanced__profile-edit-column {
    width: 100%;
}

.discourse-advanced__profile-edit .form-group {
    margin-bottom: 20px;
}

.discourse-advanced__profile-edit-column .form-group .email-section {
    margin-bottom: 2em;
}

.discourse-advanced__profile-edit label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #333;
}

.discourse-advanced__profile-edit input {
    width: 100%;
    padding: 8px;
    margin-bottom: 5px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.discourse-advanced__profile-edit input:focus {
    border-color: #00aeef;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 174, 239, 0.2);
}

.discourse-advanced__profile-edit .field-note {
    font-size: 0.9em;
    color: #666;
    margin-top: 0;
    margin-bottom: 10px;
}

.discourse-advanced__profile-edit h3 {
    color: #333;
    font-size: 1.2em;
    margin: 20px 0 15px;
}

.discourse-advanced__profile-edit .submit-button {
    padding: 10px 20px;
    background-color: #0b4fa0 !important;
    color: white !important;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    max-width: fit-content;
}

.discourse-advanced__profile-edit .submit-button:hover {
    background-color: #0095cc !important;
}

.current-email {
    background: #f5f5f5;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 15px;
}

.podcast-credential-pair {
    
}

.podcast-credentials {
    background: #f5f5f5;
    padding: 10px;
    border-radius: 4px;
}

.password-requirements {
    background: #f5f5f5;
    padding: 15px;
    margin: 10px 0;
    border-radius: 4px;
}

.strength-meter {
    height: 4px;
    background: #eee;
    margin: 5px 0;
    border-radius: 2px;
}

.strength-meter .meter {
    height: 100%;
    width: 0;
    border-radius: 2px;
    transition: all 0.3s ease;
    background-color: #4caf50;
}

.strength-text {
    font-size: 0.9em;
    margin-top: 3px;
}

.password-section button {
    background-color: #0b4fa0 !important;
    color: white !important;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    margin: 10px 0;
}

.password-section button:hover {
    background-color: #0095cc !important;
}

.password-section button:disabled {
    background-color: #ccc !important;
    cursor: not-allowed;
}

.password-step {
    margin-bottom: 20px;
    padding: 15px;
    background: #f5f5f5;
    border-radius: 4px;
}

.password-step h4 {
    margin: 0 0 10px 0;
}

.info-text {
    color: #666;
    margin-bottom: 10px;
    font-size: 0.9em;
}

.requirement {
    color: #666;
    transition: color 0.3s;
}

.requirement.met {
    color: #4caf50;
}

/* #endregion discourse_profile_edit */

/* #region render_additional_emails */
.email-list {
    margin: 20px 0;
}

.email-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    padding: 10px;
    margin-bottom: 10px;
    background: #f5f5f5;
    border-radius: 4px;
}

@media (min-width: 760px) {
    .email-item {
        flex-direction: row;
        gap: 0;
    }
}

.email-item.primary {
    background: #e3f2fd;
}

.email-item.unconfirmed {
    background: #fff3e0;
}

.email-address {
    font-size: 0.8em;
    flex: 1;
    font-weight: 500;

    @media (min-width: 768px) {
        font-size: 1em;
    }
}

.email-badge {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 0.8em;
    margin: 0 10px;
}

.email-badge.primary {
    background: #0b4fa0;
    color: white;
}

.email-badge.pending {
    background: #ff9800;
    color: white;
    text-align: center;
}

.email-actions {
    display: flex;
    gap: 8px;
}

.email-actions button {
    padding: 4px 8px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 0.9em;
}

.make-primary {
    background: #2196f3;
    color: white;
}

.delete-email {
    background: #f44336;
    color: white;
}

.resend-verification {
    background-color: #ff9800 !important;
    color: white !important;
    text-align: center !important;
}

/* #endregion render_additional_emails */