/* Scoped Identity / Account pages — matches storefront accent without heavy chrome */
.identity-app {
    --identity-accent: #dc2626;
    --identity-accent-soft: rgba(220, 38, 38, 0.12);
    --identity-accent-hover: #b91c1c;
    --identity-ink: #111827;
    --identity-muted: #6b7280;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(165deg, #fef2f2 0%, #f3f4f6 42%, #fafafa 100%);
    color: var(--identity-ink);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.identity-app .identity-topbar {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--identity-accent-soft);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset, 0 4px 12px rgba(0, 0, 0, 0.04);
}

.identity-app .identity-brand {
    color: var(--identity-ink);
    transition: color 0.15s ease, opacity 0.15s ease;
}

.identity-app .identity-brand:hover {
    color: var(--identity-accent);
    opacity: 1;
}

.identity-app .identity-brand-name {
    font-weight: 700;
    letter-spacing: -0.02em;
    font-size: 1.05rem;
}

.identity-app .identity-back {
    color: var(--identity-muted);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.15s ease;
}

.identity-app .identity-back:hover {
    color: var(--identity-accent);
}

.identity-app .identity-main {
    flex: 1;
    display: flex;
    align-items: center;
    padding-top: 1.5rem;
    padding-bottom: 2.5rem;
}

.identity-app .identity-panel {
    width: 100%;
    max-width: 36rem;
    margin-left: auto;
    margin-right: auto;
    background: #fff;
    border-radius: 1rem;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow:
        0 4px 6px -1px rgba(0, 0, 0, 0.06),
        0 12px 24px -4px rgba(220, 38, 38, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.8) inset;
    overflow: hidden;
}

.identity-app .identity-panel-bar {
    height: 4px;
    background: linear-gradient(90deg, var(--identity-accent) 0%, #f87171 55%, #fecaca 100%);
}

.identity-app .identity-panel-inner {
    padding: 1.75rem 1.5rem 2rem;
}

@media (min-width: 576px) {
    .identity-app .identity-panel-inner {
        padding: 2rem 2rem 2.25rem;
    }
}

.identity-app .identity-title {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: var(--identity-ink);
    margin-bottom: 0.25rem;
}

.identity-app .identity-title.text-danger {
    color: #b91c1c;
}

.identity-app .identity-lead {
    font-size: 0.9rem;
    color: var(--identity-muted);
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.identity-app .identity-lead--error {
    color: #b91c1c;
    font-weight: 500;
}

.identity-app .form-label {
    font-weight: 600;
    font-size: 0.875rem;
    color: #374151;
    margin-bottom: 0.35rem;
}

.identity-app .form-control,
.identity-app .form-select {
    border-radius: 0.5rem;
    border-color: #e5e7eb;
    padding: 0.55rem 0.85rem;
}

.identity-app .form-control:focus,
.identity-app .form-select:focus {
    border-color: rgba(220, 38, 38, 0.55);
    box-shadow: 0 0 0 0.2rem rgba(220, 38, 38, 0.12);
}

.identity-app .btn-primary {
    --bs-btn-bg: var(--identity-accent);
    --bs-btn-border-color: var(--identity-accent);
    --bs-btn-hover-bg: var(--identity-accent-hover);
    --bs-btn-hover-border-color: var(--identity-accent-hover);
    --bs-btn-active-bg: var(--identity-accent-hover);
    --bs-btn-active-border-color: var(--identity-accent-hover);
    --bs-btn-focus-shadow-rgb: 220, 38, 38;
    font-weight: 600;
    padding: 0.6rem 1rem;
    border-radius: 0.5rem;
}

.identity-app .form-check-input:checked {
    background-color: var(--identity-accent);
    border-color: var(--identity-accent);
}

.identity-app .form-check-input:focus {
    border-color: rgba(220, 38, 38, 0.45);
    box-shadow: 0 0 0 0.2rem rgba(220, 38, 38, 0.12);
}

.identity-app .identity-footer-link {
    font-size: 0.875rem;
    text-align: center;
    margin-top: 1.25rem;
    margin-bottom: 0;
}

.identity-app .identity-footer-link a {
    color: var(--identity-muted);
    font-weight: 500;
    text-decoration: none;
}

.identity-app .identity-footer-link a:hover {
    color: var(--identity-accent);
    text-decoration: underline;
}

.identity-app .identity-body-text {
    color: var(--identity-muted);
    line-height: 1.6;
    margin-bottom: 1.25rem;
}

.identity-app .text-danger[role="alert"] {
    border-radius: 0.5rem;
    padding: 0.65rem 0.85rem;
    background: rgba(220, 38, 38, 0.06);
    border: 1px solid rgba(220, 38, 38, 0.15);
}

.identity-app a:not(.btn):not(.identity-brand):not(.identity-back) {
    color: var(--identity-accent);
}

.identity-app a:not(.btn):not(.identity-brand):not(.identity-back):hover {
    color: var(--identity-accent-hover);
}
