:root {
    --hc-account-border: rgba(18, 39, 72, 0.12);
    --hc-account-border-strong: rgba(28, 79, 167, 0.18);
    --hc-account-surface: #ffffff;
    --hc-account-surface-soft: #f6f9fd;
    --hc-account-surface-muted: #edf3fb;
    --hc-account-text: #10213b;
    --hc-account-text-soft: #5f7290;
    --hc-account-accent: #1d4ed8;
    --hc-account-accent-dark: #173fb5;
    --hc-account-success: #15803d;
    --hc-account-warning: #b45309;
    --hc-account-danger: #b42318;
}

.hc-account-page {
    position: relative;
    padding: 74px 0 82px;
    background:
        radial-gradient(circle at top left, rgba(55, 118, 255, 0.1), transparent 26%),
        linear-gradient(180deg, #f7faff 0%, #f4f7fb 100%);
}

.hc-account-page::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(17, 39, 73, 0.028) 1px, transparent 1px),
        linear-gradient(90deg, rgba(17, 39, 73, 0.028) 1px, transparent 1px);
    background-size: 30px 30px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.32), transparent 84%);
}

.hc-account-page .container {
    position: relative;
    z-index: 1;
}

.hc-auth-shell {
    display: grid;
    grid-template-columns: minmax(320px, 1.02fr) minmax(0, 0.98fr);
    border: 1px solid var(--hc-account-border);
    background: rgba(255, 255, 255, 0.9);
    overflow: hidden;
}

.hc-auth-shell--simple {
    display: block;
    border: 0;
    background: transparent;
}

.hc-auth-panel,
.hc-auth-card {
    min-width: 0;
}

.hc-auth-panel {
    padding: 42px 38px;
    color: #f4f8ff;
    background:
        radial-gradient(circle at top right, rgba(110, 173, 255, 0.28), transparent 24%),
        linear-gradient(135deg, #0a1831 0%, #102645 56%, #184184 100%);
}

.hc-auth-kicker,
.hc-profile-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: rgba(240, 245, 255, 0.84);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hc-profile-kicker {
    min-height: 24px;
    padding: 0 8px;
    font-size: 10px;
}

.hc-auth-panel h1 {
    margin: 18px 0 12px;
    font-size: clamp(30px, 3.3vw, 46px);
    line-height: 1.04;
    font-weight: 700;
    letter-spacing: -0.04em;
}

.hc-profile-hero h1 {
    margin: 12px 0 10px;
    font-size: clamp(24px, 2.3vw, 34px);
    line-height: 1.14;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.hc-auth-panel p {
    margin: 0;
    color: rgba(233, 240, 255, 0.8);
    font-size: 15px;
    line-height: 1.78;
}

.hc-profile-hero p {
    margin: 0;
    max-width: 760px;
    color: rgba(243, 247, 255, 0.92);
    font-size: 13px;
    line-height: 1.7;
}

.hc-auth-benefits,
.hc-auth-links,
.hc-profile-quick-grid,
.hc-profile-link-grid,
.hc-profile-actions,
.hc-profile-stat-grid,
.hc-profile-security-list {
    display: grid;
    gap: 14px;
}

.hc-auth-benefits {
    margin-top: 28px;
}

.hc-auth-benefit {
    padding: 14px 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
}

.hc-auth-benefit strong,
.hc-profile-link-card strong,
.hc-profile-security-item strong,
.hc-profile-stat strong {
    display: block;
    margin-bottom: 6px;
    font-size: 15px;
    font-weight: 700;
}

.hc-auth-benefit span,
.hc-profile-stat span {
    display: block;
    color: rgba(233, 240, 255, 0.74);
    font-size: 13px;
    line-height: 1.7;
}

.hc-profile-link-card span,
.hc-profile-security-item span {
    display: block;
    color: var(--hc-account-text-soft);
    font-size: 13px;
    line-height: 1.68;
}

.hc-auth-links {
    margin-top: 22px;
}

.hc-auth-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    color: #ffffff;
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

.hc-auth-card {
    padding: 42px 36px;
    background: var(--hc-account-surface);
}

.hc-auth-card--single {
    width: min(100%, 560px);
    margin: 0 auto;
    border: 1px solid var(--hc-account-border);
    background: rgba(255, 255, 255, 0.96);
}

.hc-auth-card--wide {
    width: min(100%, 760px);
}

.hc-auth-card-head .hc-auth-kicker {
    margin-bottom: 16px;
}

.hc-auth-kicker--muted {
    border-color: rgba(29, 78, 216, 0.18);
    background: #eef4ff;
    color: var(--hc-account-accent-dark);
}

.hc-auth-card-head h1,
.hc-auth-card-head h2 {
    margin: 0;
    color: var(--hc-account-text);
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.hc-auth-card-head p {
    margin: 10px 0 0;
    color: var(--hc-account-text-soft);
    font-size: 14px;
    line-height: 1.75;
}

.hc-account-form {
    margin-top: 28px;
}

.hc-auth-note {
    margin-top: 20px;
    padding: 14px 16px;
    border: 1px solid var(--hc-account-border);
    background: var(--hc-account-surface-soft);
    color: var(--hc-account-text-soft);
    font-size: 13px;
    line-height: 1.72;
}

.hc-auth-note a {
    color: var(--hc-account-accent-dark);
    font-weight: 600;
    text-decoration: none;
}

.hc-account-form .form-label {
    margin-bottom: 8px;
    color: #304767;
    font-size: 13px;
    font-weight: 600;
}

.hc-account-form .form-control,
.hc-account-form .form-select,
.hc-account-form textarea.form-control {
    min-height: 50px;
    border: 1px solid var(--hc-account-border);
    background: linear-gradient(180deg, #ffffff 0%, #f9fbfe 100%);
    color: var(--hc-account-text);
    font-size: 14px;
}

.hc-account-form textarea.form-control {
    min-height: 120px;
    padding-top: 14px;
    resize: vertical;
}

.hc-account-form .form-control:focus,
.hc-account-form .form-select:focus,
.hc-account-form textarea.form-control:focus {
    border-color: rgba(29, 78, 216, 0.32);
    box-shadow: 0 0 0 4px rgba(29, 78, 216, 0.08);
}

.hc-account-form .input-group-text {
    border: 1px solid var(--hc-account-border);
    background: #f5f8fd;
}

.hc-account-form .form-check {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    padding: 0;
}

.hc-account-form .form-check-input {
    margin-top: 0;
}

.hc-account-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 22px;
}

.hc-account-btn,
.hc-account-link-btn,
.hc-profile-link-card,
.hc-profile-action-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 18px;
    border: 1px solid var(--hc-account-border);
    background: #ffffff;
    color: var(--hc-account-text);
    text-decoration: none;
    font: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color .18s ease, background .18s ease, color .18s ease;
}

.hc-account-btn:hover,
.hc-account-link-btn:hover,
.hc-profile-link-card:hover,
.hc-profile-action-link:hover {
    border-color: var(--hc-account-border-strong);
    background: #eef4ff;
    color: var(--hc-account-accent-dark);
}

.hc-account-btn--primary,
.hc-profile-action-link--primary {
    border-color: var(--hc-account-accent-dark);
    background: linear-gradient(180deg, var(--hc-account-accent) 0%, var(--hc-account-accent-dark) 100%);
    color: #ffffff;
}

.hc-account-btn--primary:hover,
.hc-profile-action-link--primary:hover {
    border-color: #123792;
    background: linear-gradient(180deg, #173fb5 0%, #123792 100%);
    color: #ffffff;
}

.hc-account-btn--danger,
.hc-profile-action-link--danger {
    border-color: #8f1d14;
    background: linear-gradient(180deg, #c53b2f 0%, #a62d22 100%);
    color: #ffffff;
}

.hc-account-btn--danger:hover,
.hc-profile-action-link--danger:hover {
    border-color: #7d2018;
    background: linear-gradient(180deg, #ad3125 0%, #8c241b 100%);
    color: #ffffff;
}

.hc-account-btn--ghost,
.hc-profile-action-link--ghost {
    background: transparent;
}

.hc-auth-footer-note,
.hc-auth-inline-note,
.hc-profile-meta-list,
.hc-profile-card-copy,
.hc-profile-inline-help {
    color: var(--hc-account-text-soft);
    font-size: 13px;
    line-height: 1.72;
}

.hc-auth-footer-note {
    margin-top: 22px;
}

.hc-auth-card-links {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--hc-account-border);
}

.hc-auth-card-links a {
    color: var(--hc-account-accent-dark);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
}

.hc-auth-footer-note a,
.hc-auth-inline-note a,
.hc-profile-inline-help a,
.hc-profile-card-copy a {
    color: var(--hc-account-accent-dark);
    font-weight: 600;
    text-decoration: none;
}

.hc-profile-shell {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 22px;
}

.hc-profile-sidebar,
.hc-profile-main {
    min-width: 0;
}

.hc-profile-sidebar-card,
.hc-profile-card,
.hc-profile-summary-card,
.hc-profile-link-card {
    border: 1px solid var(--hc-account-border);
    background: rgba(255, 255, 255, 0.94);
}

.hc-profile-sidebar-card {
    padding: 22px 20px;
    position: sticky;
    top: 106px;
}

.hc-profile-sidebar h2 {
    margin: 0;
    color: var(--hc-account-text);
    font-size: 20px;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.hc-profile-sidebar p {
    margin: 10px 0 0;
    color: var(--hc-account-text-soft);
    font-size: 13px;
    line-height: 1.7;
}

.hc-profile-nav {
    display: grid;
    gap: 16px;
    margin-top: 22px;
}

.hc-profile-nav-group {
    display: grid;
    gap: 8px;
}

.hc-profile-nav-group-title {
    display: block;
    color: var(--hc-account-text-soft);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hc-profile-nav-item-stack {
    display: grid;
    gap: 6px;
}

.hc-profile-nav-children {
    display: grid;
    gap: 4px;
    padding-left: 10px;
}

.hc-profile-nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 42px;
    padding: 0 13px;
    border: 1px solid transparent;
    color: #203555;
    text-decoration: none;
    font-size: 12.5px;
    font-weight: 600;
}

.hc-profile-nav-link:hover,
.hc-profile-nav-link.active {
    border-color: var(--hc-account-border-strong);
    background: #eef4ff;
    color: var(--hc-account-accent-dark);
}

.hc-profile-nav-sublink {
    display: flex;
    align-items: center;
    min-height: 36px;
    padding: 0 12px;
    border: 1px solid transparent;
    color: var(--hc-account-text-soft);
    text-decoration: none;
    font-size: 12.5px;
    font-weight: 500;
    background: rgba(246, 249, 253, 0.92);
    transition: border-color .18s ease, background .18s ease, color .18s ease;
}

.hc-profile-nav-sublink:hover {
    border-color: rgba(29, 78, 216, 0.14);
    background: rgba(238, 244, 255, 0.72);
    color: var(--hc-account-accent-dark);
}

.hc-profile-nav-link::after {
    content: "";
    width: 7px;
    height: 7px;
    border-top: 1.5px solid currentColor;
    border-right: 1.5px solid currentColor;
    transform: rotate(45deg);
    opacity: 0.6;
}

.hc-profile-main {
    display: grid;
    gap: 18px;
}

.hc-profile-section-card {
    scroll-margin-top: 124px;
}

.hc-profile-hero,
.hc-profile-card,
.hc-profile-summary-card {
    padding: 22px;
    border: 1px solid var(--hc-account-border);
    background: rgba(255, 255, 255, 0.94);
}

.hc-profile-hero {
    color: #ffffff;
    background:
        radial-gradient(circle at top right, rgba(125, 173, 255, 0.26), transparent 24%),
        linear-gradient(135deg, #091425 0%, #10233f 56%, #184184 100%);
}

.hc-profile-stat-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 18px;
}

.hc-profile-stat {
    padding: 12px 14px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
}

.hc-profile-stat strong {
    margin-bottom: 6px;
    color: #ffffff;
    font-size: 19px;
}

.hc-profile-stat span {
    color: rgba(243, 247, 255, 0.84);
    font-size: 12px;
    line-height: 1.6;
}

.hc-profile-card-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.hc-profile-card-head h3 {
    margin: 0;
    color: var(--hc-account-text);
    font-size: 17px;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.hc-profile-card-copy {
    margin-top: 6px;
    font-size: 12.5px;
    line-height: 1.68;
}

.hc-account-status {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 9px;
    border: 1px solid transparent;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.hc-profile-main .hc-account-btn,
.hc-profile-main .hc-account-link-btn,
.hc-profile-main .hc-profile-action-link {
    min-height: 40px;
    padding: 0 14px;
    font-size: 12px;
}

.hc-profile-main .hc-account-btn--primary,
.hc-profile-main .hc-profile-action-link--primary {
    border-color: #10233f;
    background: #10233f;
    color: #ffffff;
}

.hc-profile-main .hc-account-btn--primary:hover,
.hc-profile-main .hc-profile-action-link--primary:hover {
    border-color: #0a1730;
    background: #0a1730;
    color: #ffffff;
}

.hc-account-status--success {
    border-color: rgba(21, 128, 61, 0.18);
    background: rgba(236, 253, 245, 0.96);
    color: var(--hc-account-success);
}

.hc-account-status--warning {
    border-color: rgba(180, 83, 9, 0.18);
    background: rgba(255, 251, 235, 0.96);
    color: var(--hc-account-warning);
}

.hc-account-status--danger {
    border-color: rgba(180, 35, 24, 0.18);
    background: rgba(254, 242, 242, 0.98);
    color: var(--hc-account-danger);
}

.hc-profile-summary-list {
    display: grid;
    gap: 10px;
}

.hc-profile-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 10px 12px;
    border: 1px solid var(--hc-account-border);
    background: var(--hc-account-surface-soft);
}

.hc-profile-summary-row span:first-child {
    color: var(--hc-account-text-soft);
    font-size: 12.5px;
}

.hc-profile-summary-row span:last-child,
.hc-profile-summary-row strong {
    color: var(--hc-account-text);
    font-size: 12.5px;
    font-weight: 600;
}

.hc-profile-grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 14px;
}

.hc-profile-col-12 { grid-column: span 12; }
.hc-profile-col-6 { grid-column: span 6; }
.hc-profile-col-4 { grid-column: span 4; }

.hc-profile-link-grid {
    grid-template-columns: 1fr;
    gap: 10px;
}

.hc-profile-link-card {
    min-height: auto;
    padding: 12px 14px;
    align-items: flex-start;
    justify-content: flex-start;
    text-align: left;
    background: #ffffff;
}

.hc-profile-link-card span {
    color: var(--hc-account-text-soft);
}

.hc-profile-security-list {
    margin-top: 6px;
}

.hc-profile-security-item {
    padding: 12px 14px;
    border: 1px solid var(--hc-account-border);
    background: var(--hc-account-surface-soft);
}

.hc-profile-security-item strong,
.hc-profile-link-card strong {
    color: var(--hc-account-text);
    font-size: 14px;
}

.hc-profile-summary-note {
    margin-top: 14px;
    padding: 14px 16px;
    border: 1px solid rgba(180, 83, 9, 0.14);
    background: rgba(255, 251, 235, 0.92);
    color: #8b5e16;
    font-size: 12.5px;
    line-height: 1.72;
}

.hc-profile-alert {
    margin-bottom: 18px;
    padding: 14px 16px;
    border: 1px solid var(--hc-account-border);
    font-size: 13px;
    line-height: 1.72;
}

.hc-profile-alert--success {
    border-color: rgba(21, 128, 61, 0.16);
    background: rgba(236, 253, 245, 0.96);
    color: var(--hc-account-success);
}

.hc-profile-alert--danger {
    border-color: rgba(180, 35, 24, 0.16);
    background: rgba(254, 242, 242, 0.98);
    color: var(--hc-account-danger);
}

.hc-profile-alert--warning {
    border-color: rgba(180, 83, 9, 0.16);
    background: rgba(255, 251, 235, 0.96);
    color: var(--hc-account-warning);
}

.hc-profile-alert a {
    color: inherit;
    font-weight: 700;
    text-decoration: none;
}

.hc-authenticator-app-grid,
.hc-authenticator-setup-grid,
.hc-recovery-code-grid {
    display: grid;
    gap: 14px;
}

.hc-authenticator-app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 18px;
}

.hc-authenticator-setup-grid {
    grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
    align-items: stretch;
}

.hc-authenticator-qr-card,
.hc-authenticator-key-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--hc-account-border);
    background: var(--hc-account-surface-soft);
}

.hc-authenticator-qr-card strong,
.hc-authenticator-key-card strong {
    color: var(--hc-account-text);
    font-size: 14px;
    font-weight: 700;
}

.hc-authenticator-key-card p {
    margin: 0;
    color: var(--hc-account-text-soft);
    font-size: 13px;
    line-height: 1.72;
}

.hc-authenticator-qr-image {
    width: 100%;
    max-width: 188px;
    aspect-ratio: 1 / 1;
    padding: 10px;
    border: 1px solid var(--hc-account-border);
    background: #ffffff;
    object-fit: contain;
}

.hc-authenticator-key {
    display: block;
    padding: 14px 16px;
    border: 1px dashed rgba(16, 33, 59, 0.18);
    background: #ffffff;
    color: var(--hc-account-text);
    font-size: 15px;
    line-height: 1.8;
    word-break: break-word;
}

.hc-authenticator-form {
    margin-top: 0;
}

.hc-recovery-code-grid {
    margin-top: 18px;
}

.hc-recovery-code-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.hc-recovery-code {
    display: block;
    padding: 14px 16px;
    border: 1px solid var(--hc-account-border);
    background: var(--hc-account-surface-soft);
    color: var(--hc-account-text);
    font-size: 15px;
    font-weight: 700;
    text-align: center;
}

.hc-profile-inline-help code {
    color: var(--hc-account-accent-dark);
}

.hc-profile-empty {
    padding: 18px;
    border: 1px dashed var(--hc-account-border-strong);
    color: var(--hc-account-text-soft);
    font-size: 13px;
    line-height: 1.72;
    background: rgba(246, 249, 253, 0.94);
}

.hc-account-form .text-danger,
.hc-account-form .validation-summary-errors,
.hc-account-form .validation-summary-valid {
    font-size: 13px;
}

.validation-summary-errors ul {
    margin: 0;
    padding-left: 18px;
}

@media (max-width: 1199.98px) {
    .hc-profile-shell {
        grid-template-columns: 240px minmax(0, 1fr);
    }

    .hc-profile-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hc-profile-link-grid {
        grid-template-columns: 1fr;
    }

    .hc-authenticator-setup-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 991.98px) {
    .hc-account-page {
        padding: 56px 0 64px;
    }

    .hc-auth-shell,
    .hc-profile-shell {
        grid-template-columns: 1fr;
    }

    .hc-profile-sidebar-card {
        position: static;
    }

    .hc-authenticator-setup-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 767.98px) {
    .hc-auth-panel,
    .hc-auth-card,
    .hc-profile-hero,
    .hc-profile-card,
    .hc-profile-summary-card,
    .hc-profile-sidebar-card {
        padding: 22px 20px;
    }

    .hc-profile-grid,
    .hc-profile-stat-grid {
        grid-template-columns: 1fr;
    }

    .hc-profile-col-12,
    .hc-profile-col-6,
    .hc-profile-col-4 {
        grid-column: auto;
    }

    .hc-profile-summary-row,
    .hc-profile-card-head,
    .hc-account-actions {
        flex-direction: column;
        align-items: flex-start;
    }

    .hc-account-actions .hc-account-btn,
    .hc-account-actions .hc-account-link-btn,
    .hc-profile-actions .hc-profile-action-link {
        width: 100%;
    }

    .hc-auth-card-links {
        flex-direction: column;
        align-items: flex-start;
    }

    .hc-authenticator-app-grid,
    .hc-recovery-code-row {
        grid-template-columns: 1fr;
    }
}
