/* Shared look for the password reset pages and the two-factor setup walkthrough.
   Many members are 50+, so text and tap targets are deliberately large.
   Inputs stay at 18px or more, which also stops iPhones zooming in when one is tapped. */

html:has(.acct-page), body:has(.acct-page) { background: #f5f2ec !important; }

.acct-page {
    display: flex;
    justify-content: center;
    padding: 8px 0 32px;
    font-family: 'Lato', Arial, sans-serif;
    font-size: 18px;
    line-height: 1.5;
    color: #1a1410;
}

.acct-card {
    width: 100%;
    max-width: 560px;
    background: #fff;
    border: 1px solid #e4dfd5;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(40, 30, 20, 0.08);
    padding: 32px;
    box-sizing: border-box;
}

.acct-card--wide { max-width: 780px; }

@media (max-width: 600px) {
    .acct-page { padding: 0 0 16px; }
    .acct-card { padding: 20px; border-radius: 12px; }
}

.acct-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    font-family: 'Oswald', Arial, sans-serif;
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.acct-brand img { width: 44px; height: 44px; }

.acct-card h1 {
    font-family: 'Oswald', Arial, sans-serif;
    font-size: 32px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: normal;
    text-transform: none;
    color: inherit;
    margin: 0 0 12px;
    outline: none;
}

.acct-card h2 {
    font-family: 'Oswald', Arial, sans-serif;
    font-size: 22px;
    font-weight: 600;
    letter-spacing: normal;
    text-transform: none;
    color: inherit;
    margin: 28px 0 8px;
}

.acct-card p { margin: 0 0 16px; }
.acct-muted { color: #5c5248; }

/* ── Big status icon ─────────────────────────────── */
.acct-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    margin-bottom: 16px;
}

.acct-icon .mud-icon-root { font-size: 44px; width: 44px; height: 44px; }
.acct-icon--success { background: #e3f4e6; color: #1b7a31; }
.acct-icon--warning { background: #fdf0d9; color: #a86500; }
.acct-icon--brand   { background: #fbe6e6; color: #c62828; }

/* ── Form fields ─────────────────────────────────── */
.acct-field { margin-bottom: 20px; }

.acct-field label {
    display: block;
    font-weight: 700;
    margin-bottom: 6px;
}

.acct-hint {
    display: block;
    font-size: 16px;
    color: #5c5248;
    margin-top: 6px;
}

.acct-input {
    display: block;
    width: 100%;
    min-height: 56px;
    box-sizing: border-box;
    padding: 12px 14px;
    font: inherit;
    font-size: 18px;
    color: inherit;
    background: #fff;
    border: 2px solid #8a8074;
    border-radius: 10px;
}

.acct-input:focus {
    outline: 3px solid rgba(198, 40, 40, 0.3);
    border-color: #c62828;
}

.acct-password { position: relative; }
.acct-password .acct-input { padding-right: 84px; }

.acct-password button {
    position: absolute;
    top: 6px;
    right: 6px;
    bottom: 6px;
    min-width: 68px;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    color: #b71c1c;
    background: #f7f4ee;
    border: 0;
    border-radius: 7px;
    cursor: pointer;
}

.acct-code-input {
    font-size: 34px;
    font-weight: 700;
    letter-spacing: 0.22em;
    text-align: center;
    max-width: 300px;
    margin: 0 auto;
    min-height: 72px;
}

.validation-message {
    display: block;
    color: #b71c1c;
    font-size: 16px;
    margin-top: 6px;
}

/* ── Live password checklist ─────────────────────── */
.acct-rules {
    list-style: none;
    margin: 0 0 20px;
    padding: 14px 16px;
    background: #f7f4ee;
    border-radius: 10px;
    font-size: 17px;
}

.acct-rules li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 3px 0;
}

.acct-rules li::before {
    content: "";
    flex: 0 0 22px;
    height: 22px;
    box-sizing: border-box;
    border: 2px solid #8a8074;
    border-radius: 50%;
}

.acct-rules li.is-met { color: #1b7a31; font-weight: 700; }

.acct-rules li.is-met::before {
    content: "\2713";
    color: #fff;
    font-size: 14px;
    line-height: 18px;
    text-align: center;
    background: #1b7a31;
    border-color: #1b7a31;
}

/* ── Buttons ─────────────────────────────────────── */
.acct-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    min-height: 60px;
    box-sizing: border-box;
    padding: 12px 20px;
    font: inherit;
    font-size: 20px;
    font-weight: 700;
    text-align: center;
    text-decoration: none;
    color: #fff;
    background: #c62828;
    border: 2px solid #c62828;
    border-radius: 12px;
    cursor: pointer;
}

.acct-button:hover { background: #a91f1f; border-color: #a91f1f; color: #fff; }

.acct-button--secondary {
    color: #b71c1c;
    background: #fff;
}

.acct-button--secondary:hover { color: #fff; }

.acct-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.acct-buttons > * { flex: 1 1 200px; width: auto; }

.acct-nav { margin-top: 24px; }

.acct-back {
    display: inline-block;
    padding: 12px 4px;
    color: #5c5248;
    font-size: 17px;
}

/* ── Messages ────────────────────────────────────── */
.acct-alert {
    display: flex;
    gap: 12px;
    padding: 14px 16px;
    margin-bottom: 20px;
    border-radius: 10px;
    font-size: 17px;
}

.acct-alert .mud-icon-root { flex: 0 0 auto; }
.acct-alert--error { color: #8e1616; background: #fdeaea; border: 1px solid #f3bcbc; }
.acct-alert--info  { color: #24404f; background: #e9f3f8; border: 1px solid #bcdbe9; }

.acct-message {
    padding: 16px 18px;
    margin-bottom: 20px;
    background: #fbf6e9;
    border-left: 5px solid #c9a84c;
    border-radius: 4px;
}

.acct-checks {
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
}

.acct-checks li {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 6px 0;
}

.acct-checks .mud-icon-root { color: #1b7a31; flex: 0 0 auto; }

.acct-tick {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin-bottom: 20px;
    cursor: pointer;
}

.acct-tick input {
    flex: 0 0 26px;
    width: 26px;
    height: 26px;
    margin: 0;
    accent-color: #c62828;
}

/* ── Walkthrough progress ────────────────────────── */
.acct-progress-label {
    font-weight: 700;
    color: #5c5248;
    margin-bottom: 8px;
}

.acct-progress {
    display: flex;
    gap: 6px;
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
}

.acct-progress li {
    flex: 1;
    padding-top: 10px;
    font-size: 15px;
    color: #5c5248;
    text-align: center;
    border-top: 6px solid #e4dfd5;
}

.acct-progress li.is-done { color: #1b7a31; border-top-color: #1b7a31; }
.acct-progress li.is-current { color: #1a1410; font-weight: 700; border-top-color: #c62828; }

@media (max-width: 600px) {
    .acct-progress li { font-size: 13px; }
}

/* ── Numbered instructions ───────────────────────── */
.acct-steps {
    list-style: none;
    counter-reset: acct-step;
    margin: 0 0 24px;
    padding: 0;
}

.acct-steps > li {
    counter-increment: acct-step;
    position: relative;
    min-height: 40px;
    padding: 4px 0 16px 54px;
}

.acct-steps > li::before {
    content: counter(acct-step);
    position: absolute;
    top: 0;
    left: 0;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    font-weight: 700;
    color: #fff;
    background: #c62828;
    border-radius: 50%;
}

/* ── Scan layout ─────────────────────────────────── */
.acct-connect {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 28px;
    align-items: start;
    margin-bottom: 8px;
}

@media (max-width: 720px) {
    .acct-connect { grid-template-columns: 1fr; }
}

.acct-qr {
    display: block;
    width: 100%;
    max-width: 280px;
    height: auto;
    margin: 0 auto;
    background: #fff;
    border: 2px solid #e4dfd5;
    border-radius: 12px;
    image-rendering: pixelated;
}

/* Phones and tablets can't scan their own screen, so they get the tap-to-add button first.
   Going by the kind of pointer also catches iPads, which report themselves as Macs. */
.acct-for-touch { display: none; }

@media (hover: none) and (pointer: coarse) {
    .acct-for-touch { display: block; }
    .acct-for-mouse { display: none; }
}

.acct-more {
    margin-bottom: 16px;
    border: 1px solid #e4dfd5;
    border-radius: 10px;
}

.acct-more summary {
    padding: 14px 16px;
    font-weight: 700;
    color: #b71c1c;
    cursor: pointer;
}

.acct-more > div { padding: 0 16px 16px; }

.acct-key {
    display: block;
    padding: 12px;
    margin-bottom: 12px;
    font-family: Consolas, 'Courier New', monospace;
    font-size: 20px;
    font-weight: 700;
    text-align: center;
    word-spacing: 0.15em;
    overflow-wrap: anywhere;
    background: #f7f4ee;
    border-radius: 8px;
}

/* ── Example of what the app will show ───────────── */
.acct-phone-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

.acct-phone {
    width: 230px;
    box-sizing: border-box;
    padding: 34px 10px 30px;
    background: #24211e;
    border-radius: 30px;
}

.acct-phone-screen {
    padding: 12px 14px 22px;
    background: #fff;
    border-radius: 6px;
    text-align: left;
}

.acct-phone-title {
    padding-bottom: 8px;
    margin-bottom: 12px;
    font-size: 13px;
    font-weight: 700;
    color: #5c5248;
    border-bottom: 1px solid #e4dfd5;
}

.acct-phone-account { font-size: 14px; color: #5c5248; }

.acct-phone-code {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 30px;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: #1a56b0;
}

.acct-phone-timer {
    width: 20px;
    height: 20px;
    background: conic-gradient(#1a56b0 0 70%, #dfe8f6 70% 100%);
    border-radius: 50%;
}

.acct-phone-caption {
    margin-top: 8px;
    font-size: 15px;
    color: #5c5248;
}

/* ── Backup codes ────────────────────────────────── */
.acct-codes {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px 16px;
    padding: 16px;
    margin-bottom: 20px;
    font-family: Consolas, 'Courier New', monospace;
    font-size: 18px;
    font-weight: 700;
    text-align: center;
    background: #f7f4ee;
    border: 2px dashed #8a8074;
    border-radius: 10px;
}

@media (max-width: 360px) {
    .acct-codes { grid-template-columns: 1fr; }
}

@media print {
    .acct-card { box-shadow: none; border: 0; }
    .acct-noprint { display: none !important; }
}

.acct-signout {
    margin-top: 24px;
    padding-top: 16px;
    font-size: 16px;
    color: #5c5248;
    border-top: 1px solid #e4dfd5;
}

.acct-signout button {
    padding: 8px 4px;
    font: inherit;
    color: #b71c1c;
    text-decoration: underline;
    background: none;
    border: 0;
    cursor: pointer;
}
