/* ================================================================
   FriendsByChance — profile.css
   Profile editor page styles
   ================================================================ */

/* ── Page title ─────────────────────────────────────────────────── */
.profile-title {
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--color-text-primary);
    margin-bottom: 24px;
}

/* ── Read-only unique nickname display ──────────────────────────── */
.profile-readonly-field {
    padding: 9px 12px;
    background: var(--color-divider);
    border: 1.5px solid var(--color-divider);
    border-radius: 7px;
    font-size: 0.95rem;
    color: var(--color-text-secondary);
    font-family: 'Courier New', Courier, monospace;
}

/* ── Loading / error states ─────────────────────────────────────── */
.profile-loading,
.profile-error {
    text-align: center;
    padding: 60px 20px;
    font-size: 0.95rem;
    color: var(--color-text-secondary);
}

.profile-error { color: #c62828; }

/* ── Danger zone ────────────────────────────────────────────────── */
.profile-danger-zone {
    margin-top: 48px;
    padding: 20px;
    border: 1.5px solid #ef9a9a;
    border-radius: 10px;
    background: #fff8f8;
}

/* Its look is .fbc-section-title's (components/shared.css, loaded later — hence both classes). */
.fbc-section-title.profile-danger-title { color: #c62828; margin-bottom: 8px; }

.profile-danger-hint {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    margin-bottom: 16px;
    line-height: 1.45;
}

/* ── Danger zone button: full-width override (base style in main.css) */
.profile-danger-zone .btn-danger {
    width:         100%;
    padding:       11px;
    font-size:     0.97rem;
    font-weight:   600;
    border-radius: 8px;
    background:    #e53935;
}
.profile-danger-zone .btn-danger:hover { background: #c62828; }



/* ── My Profile's groups, in the left pane (profile.js GROUPS) ───────── */
.profile-groups {
    display:        flex;
    flex-direction: column;
    gap:            4px;
    padding:        12px;
}
.profile-group-btn {
    display:       flex;
    align-items:   center;
    gap:           10px;
    padding:       10px 12px;
    border:        none;
    border-radius: 8px;
    background:    transparent;
    color:         var(--color-text);
    font:          inherit;
    font-weight:   500;
    text-align:    left;
    cursor:        pointer;
}
.profile-group-btn svg { width: 18px; height: 18px; flex: 0 0 auto; color: var(--color-text-secondary); }
.profile-group-btn:hover { background: var(--color-hover); }
.profile-group-btn--active,
.profile-group-btn--active:hover {
    background: var(--color-primary);
    color:      var(--color-text-on-primary);
}
.profile-group-btn--active svg { color: inherit; }
.profile-checkins-history { margin-top: 16px; }

/* ── The business card (FBC.profile.openCard, under the top bar's name) ──
   Three blocks side by side where they fit, else one above the other; it
   scrolls where the window is shorter than it. */
.fbc-popover.profile-card-pop {
    max-width:  min(760px, calc(100vw - 16px));
    max-height: calc(100vh - var(--top-bar-height) - 16px);
    overflow-y: auto;
    padding:    0;
}
.profile-card {
    /* As wide as three blocks take, never wider than the window: they
       wrap one under the other where they do not fit side by side. */
    width:     min(720px, calc(100vw - 16px));
    display:   flex;
    flex-wrap: wrap;
    gap:       1px;
    background: var(--color-divider);      /* the hairlines between the blocks */
}
.profile-card-block {
    flex:           1 1 220px;
    min-width:      0;
    display:        flex;
    flex-direction: column;
    gap:            8px;
    padding:        14px 16px 16px;
    background:     var(--color-surface);
}
.profile-card-picture {
    width:         64px;
    height:        64px;
    border-radius: 50%;
    object-fit:    cover;
    border:        2px solid var(--color-divider);
}
.profile-card-row   { display: flex; flex-direction: column; gap: 1px; }
.profile-card-label { font-size: 0.74rem; color: var(--color-text-muted); }
/* What is written: pressed, copied — a press target the size of its words, its hover saying so. */
.profile-card-value {
    align-self:    flex-start;
    max-width:     100%;
    margin-left:   -6px;
    padding:       3px 6px;
    border:        none;
    border-radius: 5px;
    background:    none;
    color:         var(--color-text);
    font-size:     0.92rem;
    text-align:    left;
    overflow-wrap: anywhere;
    cursor:        copy;
}
.profile-card-value:hover         { background: var(--color-hover); }
.profile-card-value:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 1px; }
.profile-card-empty { font-size: 0.86rem; color: var(--color-text-muted); }

/* The password asked before an account is deleted. */
.form-group.delete-password-group { margin-top: 16px; }
