/* Shared card for the public Account screens (_Layout): ConfirmEmail, ForgotPassword(+Confirmation),
   ResetPassword(+Confirmation), RegisterConfirmation, Message, InvoicePending, ExternalLoginFailure.
   Same shell as PaymentSuccess / PaymentCancel: crimson logo bar, centred status icon, title, message,
   full-width brand button. Views set ViewBag.ShowPageBackground = true and link font-awesome.min.css (FA 4.7). */

/* Right-edge diamond chain (Views/Account/_AccountGeo.cshtml) - sits behind the card */
.acct-geo {
    position: absolute;
    top: 70px;
    right: 0;
    width: 44vw;
    max-width: 640px;
    min-width: 200px;
    overflow: hidden;          /* the big diamond runs off the edge - never add a horizontal scrollbar */
    pointer-events: none;
    z-index: 0;
}
.acct-geo svg { display: block; width: 100%; height: auto; }
.acct-geo ~ .acct-page-center { position: relative; z-index: 1; }

/* Diamonds pop in one after another, then bob gently at different rates */
.acct-geo-pop {
    transform-box: fill-box;
    transform-origin: center;
    animation: acct-geo-pop 0.55s var(--geo-delay, 0s) cubic-bezier(0.22,1,0.36,1) both;
}
.acct-geo-bob-a { animation: acct-geo-bob 6s 1.4s ease-in-out infinite alternate; }
/* b drifts the other way by moving up, not by alternate-reverse - that starts at the 6px end, so the shapes snapped down when it kicked in */
.acct-geo-bob-b { animation: acct-geo-bob-up 7.5s 1.6s ease-in-out infinite alternate; }
.acct-geo-draw {
    stroke-dasharray: var(--len);
    stroke-dashoffset: var(--len);
    animation: acct-geo-draw 1.2s var(--geo-delay, 0.6s) cubic-bezier(0.22,1,0.36,1) forwards;
}
@keyframes acct-geo-pop {
    from { opacity: 0; transform: scale(0.4) rotate(-90deg); }
    to   { opacity: 1; transform: scale(1) rotate(0deg); }
}
@keyframes acct-geo-bob {
    from { transform: translateY(0); }
    to   { transform: translateY(6px); }
}
@keyframes acct-geo-bob-up {
    from { transform: translateY(0); }
    to   { transform: translateY(-6px); }
}
@keyframes acct-geo-draw { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) {
    .acct-geo-pop, .acct-geo-bob-a, .acct-geo-bob-b { animation: none; }
    .acct-geo-draw { animation: none; stroke-dashoffset: 0; }
}
/* Phones: the card fills the width - shapes would only peek out from behind it */
@media (max-width: 600px) {
    .acct-geo { display: none; }
}

.acct-page-center {
    min-height: calc(100vh - 90px);
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    padding: 20px 16px;
}

.acct-outer {
    max-width: 520px;
    width: 100%;
    margin: 0 auto;
}

.acct-card {
    overflow: hidden;
    padding: 0 !important;
    border-radius: 16px;
    -webkit-animation: acct-fade-up 0.45s cubic-bezier(0.22,1,0.36,1) both;
    animation: acct-fade-up 0.45s cubic-bezier(0.22,1,0.36,1) both;
}

/* ── Logo bar ─────────────────────────────────────────────────── */
.acct-topbar {
    background-color: var(--SitePrimaryColour, #9C1C3C);
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    padding: 20px 32px;
    gap: 18px;
}

.acct-topbar-logo { height: 38px; object-fit: contain; filter: brightness(0) invert(1); } /* colour logo -> white on the burgundy bar */

.acct-topbar-vr {
    width: 1px;
    height: 32px;
    background: rgba(255,255,255,0.28);
    flex-shrink: 0;
}

.acct-topbar-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    margin: 0;
}

.acct-topbar-sub {
    font-size: 12px;
    color: rgba(255,255,255,0.78);
    margin: 2px 0 0;
}

/* ── Body ─────────────────────────────────────────────────────── */
.acct-body {
    padding: 40px 36px 32px;
    background: #fff;
    text-align: center;
}

/* Form screens: heading centred, fields left-aligned */
.acct-body--form { padding-top: 32px; }
.acct-body--form form { text-align: left; }

.acct-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 28px;
    background: rgba(156,28,60,0.08);
    border: 2px solid rgba(156,28,60,0.22);
    color: #9C1C3C;
}

.acct-icon--success { background: rgba(39,174,96,0.1); border-color: rgba(39,174,96,0.3); color: #1e8449; }
.acct-icon--warning { background: rgba(230,126,34,0.1); border-color: rgba(230,126,34,0.3); color: #b85c00; }
.acct-icon--sm { width: 60px; height: 60px; font-size: 24px; margin-bottom: 16px; }

.acct-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a2e;
    letter-spacing: -0.3px;
    line-height: 1.3;
    margin: 0 0 10px;
}

.acct-message {
    font-size: 15px;
    color: #555;
    line-height: 1.65;
    max-width: 400px;
    margin: 0 auto 24px;
}

    .acct-message strong { color: #333; }

/* Grey call-out under the message (next steps / tips) */
.acct-note {
    display: -webkit-flex;
    display: flex;
    gap: 10px;
    text-align: left;
    background: #f7f7f9;
    border: 1px solid #ebebef;
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 13px;
    color: #555;
    line-height: 1.55;
    margin: 0 0 24px;
}

    .acct-note .fa {
        color: #9C1C3C;
        margin-top: 2px;
        flex-shrink: 0;
    }

/* Server-supplied rich text (Message / ErrorMessage) */
.acct-richtext { text-align: left; }
    .acct-richtext a { color: #9C1C3C; font-weight: 600; }

/* ── Buttons (same look as Contact .ct-btn-*) ──────────────────── */
.acct-actions {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    gap: 10px;
}

.acct-btn-primary,
.acct-btn-secondary {
    min-height: 48px;
    width: 100%;
    padding: 0 24px;
    font-size: 16px;
    border-radius: 10px;
    text-decoration: none;
    display: -webkit-inline-flex;
    display: inline-flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
    gap: 10px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.16s ease, border-color 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
}

.acct-btn-primary {
    font-weight: 700;
    border: none;
    background: #9C1C3C;
    color: #fff;
    box-shadow: 0 4px 16px rgba(156,28,60,0.30);
}

    .acct-btn-primary:hover,
    .acct-btn-primary:focus {
        background: #7a1530;
        color: #fff;
        text-decoration: none;
        transform: translateY(-2px);
        box-shadow: 0 8px 24px rgba(156,28,60,0.38);
    }

    .acct-btn-primary[disabled],
    .acct-btn-primary.is-busy {
        opacity: 0.6;
        cursor: wait;
        transform: none;
        box-shadow: none;
    }

.acct-btn-secondary {
    font-weight: 600;
    background: transparent;
    color: #9C1C3C;
    border: 2px solid rgba(156,28,60,0.35);
}

    .acct-btn-secondary:hover,
    .acct-btn-secondary:focus {
        background: rgba(156,28,60,0.06);
        border-color: #9C1C3C;
        color: #9C1C3C;
        text-decoration: none;
        transform: translateY(-2px);
    }

    .acct-btn-primary:focus-visible,
    .acct-btn-secondary:focus-visible {
        outline: 3px solid rgba(156,28,60,0.45);
        outline-offset: 3px;
    }

    .acct-btn-primary .fa,
    .acct-btn-secondary .fa {
        font-size: 14px;
        transition: transform 0.16s ease;
    }

    .acct-btn-primary:hover .fa-arrow-right { transform: translateX(3px); }
    .acct-btn-primary:hover .fa-arrow-left { transform: translateX(-3px); }

/* ── Footer line ──────────────────────────────────────────────── */
.acct-footnote {
    border-top: 1px solid rgba(0,0,0,0.07);
    margin-top: 28px;
    padding-top: 18px;
    font-size: 13px;
    color: #666;
    line-height: 1.6;
    text-align: center;
}

    .acct-footnote a {
        color: #9C1C3C;
        font-weight: 600;
    }

    /* Bootstrap's a:focus draws a black ring after a mouse click - keep a ring only
       for keyboard focus */
    .acct-page-center a:focus:not(:focus-visible) { outline: none; }
    .acct-footnote a:focus-visible { outline: 3px solid #2A9DA8; outline-offset: 3px; border-radius: 2px; }

    .acct-footnote .acct-sep { margin: 0 8px; color: #ccc; }

/* ── Form fields (match Login .login-field) ───────────────────── */
.acct-field { margin-bottom: 18px; }

    .acct-field label {
        display: block;
        font-size: 13px;
        font-weight: 600;
        margin-bottom: 6px;
        color: #444;
    }

.acct-input-wrap {
    position: relative;
    display: block;
}

    /* !important: SiteVizzarri caps every input at max-width:280px */
    .acct-input-wrap .form-control {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
        height: 44px;
        padding-left: 38px;
        padding-right: 14px;
        border-radius: 8px;
        font-size: 15px;
        border: 1.5px solid #e0e0e0;
        box-shadow: none;
        transition: border-color 0.15s ease, box-shadow 0.15s ease;
    }

    .acct-input-wrap--toggle .form-control { padding-right: 52px; }

        .acct-input-wrap .form-control:focus {
            border-color: #9C1C3C;
            outline: none;
            box-shadow: 0 0 0 3px rgba(156,28,60,0.12);
        }

        .acct-input-wrap .form-control.input-validation-error { border-color: #c0392b; }

    .acct-input-wrap .acct-input-icon {
        position: absolute;
        left: 13px;
        top: 50%;
        transform: translateY(-50%);
        color: #b0b0b0;
        font-size: 14px;
        pointer-events: none;
    }

.acct-pwd-toggle {
    position: absolute;
    right: 1px;
    top: 1px;
    bottom: 1px;
    width: 46px;
    background: transparent;
    border: none;
    border-radius: 0 7px 7px 0;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: center;
    justify-content: center;
    color: #a0a0a0;
    font-size: 15px;
    cursor: pointer;
    padding: 0;
}

    .acct-pwd-toggle:hover { color: #9C1C3C; }
    .acct-pwd-toggle:focus-visible { outline: 2px solid rgba(156,28,60,0.45); outline-offset: -2px; }

.acct-field .field-validation-error {
    display: block;
    font-size: 12px;
    margin-top: 5px;
    color: #c0392b;
}

.acct-field .field-validation-valid { display: none; }

/* Server-side errors (ValidationSummary) */
.acct-errors .validation-summary-errors {
    background: #fdf2f2;
    border: 1px solid #f5c6cb;
    border-radius: 10px;
    padding: 12px 14px;
    margin: 0 0 20px;
    font-size: 13px;
    color: #8a1f1f;
    text-align: left;
}

    .acct-errors .validation-summary-errors ul { margin: 0; padding-left: 18px; }
.acct-errors .validation-summary-valid { display: none; }

/* ── Password rules + strength (ResetPassword) ────────────────── */
.acct-criteria {
    list-style: none;
    margin: -4px 0 20px;
    padding: 12px 14px;
    background: #f7f7f9;
    border: 1px solid #ebebef;
    border-radius: 10px;
    font-size: 13px;
    color: #666;
}

    .acct-criteria li {
        display: -webkit-flex;
        display: flex;
        -webkit-align-items: center;
        align-items: center;
        gap: 8px;
        padding: 2px 0;
        transition: color 0.15s ease;
    }

        .acct-criteria li .fa {
            width: 14px;
            text-align: center;
            color: #b0b0b0;
        }

        .acct-criteria li.met { color: #1e7a45; }
            .acct-criteria li.met .fa { color: #1e8449; }

.acct-strength {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    gap: 10px;
    margin: 0 0 12px;
    font-size: 12px;
    color: #666;
}

.acct-strength-bar {
    -webkit-flex: 1;
    flex: 1;
    height: 6px;
    border-radius: 3px;
    background: #ececf0;
    overflow: hidden;
}

    .acct-strength-bar span {
        display: block;
        height: 100%;
        width: 0;
        border-radius: 3px;
        background: #c0392b;
        transition: width 0.25s ease, background-color 0.25s ease;
    }

.acct-strength[data-level="medium"] .acct-strength-bar span { background: #d68910; }
.acct-strength[data-level="strong"] .acct-strength-bar span { background: #1e8449; }

.acct-strength-label { min-width: 92px; text-align: right; font-weight: 600; }

/* ── Motion / small screens ───────────────────────────────────── */
@-webkit-keyframes acct-fade-up {
    from { opacity: 0; -webkit-transform: translateY(12px); }
    to { opacity: 1; -webkit-transform: translateY(0); }
}

@keyframes acct-fade-up {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    .acct-card { -webkit-animation: none; animation: none; }
    .acct-btn-primary, .acct-btn-secondary, .acct-btn-primary .fa,
    .acct-criteria li, .acct-strength-bar span { transition: none; }
    .acct-btn-primary:hover, .acct-btn-primary:focus,
    .acct-btn-secondary:hover, .acct-btn-secondary:focus,
    .acct-btn-primary:hover .fa-arrow-right { transform: none; }
}

@media (max-width: 480px) {
    .acct-topbar { padding: 16px 20px; gap: 14px; }
    .acct-topbar-logo { height: 32px; }
    .acct-body { padding: 32px 22px 26px; }
    .acct-title { font-size: 20px; }
}
