/* Rahmah identity, v2 overhaul: her_profile.html and his_profile.html (the two session profile pages).
 * Presentation only. No logic, ids, handlers or copy are changed.
 * Corners: 4px controls, square cards. 44px targets. Fig focus ring. Copper is never used for small text.
 *
 * SCOPE: these two pages only. Linked after the page's own <style> blocks so it wins by order; !important
 * is used only against the inline style="" attributes in the markup (attribute selectors below).
 * TO REVERT: delete the two <link> lines (bym/styles/rahmah.css and rahmah-profile-legacy.css) before </head>.
 * Tokens: bym/styles/rahmah.css (--bym-*).
 */
@font-face { font-family: "BYM Afacad"; src: url("/bym/fonts/AfacadFlux-Regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "BYM Afacad"; src: url("/bym/fonts/AfacadFlux-Medium.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "BYM Afacad"; src: url("/bym/fonts/AfacadFlux-Semibold.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }

:root { --font-display: "BYM Afacad", "Afacad Flux", "Avenir Next", Arial, sans-serif; }
html { font-size: 18px; }
body { background: var(--bym-canvas); color: var(--bym-text); font-family: var(--font-display); font-size: var(--bym-text-base); line-height: 1.55; }
*, *::before, *::after { box-shadow: none !important; text-shadow: none !important; }
:where(a, button, input, select, textarea, [tabindex]):focus-visible { outline: 3px solid var(--bym-focus); outline-offset: 3px; }
h1, h2, h3, h4 { color: var(--bym-primary); font-family: var(--font-display); letter-spacing: -.02em; line-height: 1.15; }

/* ---- Top bar (inline-styled in the markup) ---- */
body > div[style*="justify-content:space-between"]:first-of-type { background: var(--bym-canvas) !important; border-bottom: 1px solid var(--bym-rule) !important; padding: 8px 16px !important; min-height: 56px; }
[style*="Playfair Display"] { font-family: var(--font-display) !important; font-size: 1.25rem !important; font-weight: 600 !important; color: var(--bym-primary) !important; letter-spacing: -.01em; }
body > div[style*="justify-content:space-between"]:first-of-type a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 6px; font-size: var(--bym-text-xs) !important; color: var(--bym-primary) !important; text-decoration: underline; text-underline-offset: 3px; }
body > div[style*="justify-content:space-between"]:first-of-type a[style*="font-weight:500"] { font-weight: 600 !important; }

/* ---- Banner, header, notices ---- */
.session-banner { background: var(--bym-surface); border-bottom: 1px solid var(--bym-rule); color: var(--bym-text-muted); font-size: var(--bym-text-xs); }
.page-header h1 { font-size: var(--bym-text-title); letter-spacing: -.02em; }
.page-header .subtitle { color: var(--bym-text-muted); font-size: var(--bym-text-sm); font-weight: 400; }
#profile-ownership-notice { background: var(--bym-surface-soft) !important; border: 0 !important; border-inline-start: 3px solid var(--bym-primary) !important; border-radius: 0 !important; }

/* ---- Tabs ---- */
.tab-nav { border-bottom: 1px solid var(--bym-rule); }
.tab-btn { min-height: 48px; padding: 0 18px; color: var(--bym-text-muted); font-size: var(--bym-text-sm); font-weight: 500; transition: none; }
.tab-btn:hover { color: var(--bym-primary); }
.tab-btn.active { color: var(--bym-primary); border-bottom: 3px solid var(--bym-primary); font-weight: 600; }
.section-label { color: var(--bym-primary); font-size: var(--bym-text-lg); }

/* ---- Tag pills, kid buttons: 4px, selected = Fig ---- */
.tag-pill, .kidbtn { min-height: 44px; border-radius: 4px; border: 1px solid var(--bym-border); background: var(--bym-surface); color: var(--bym-primary); font-size: var(--bym-text-xs); font-weight: 500; padding: 0 16px; transition: none; }
.tag-pill:hover, .kidbtn:hover { border-color: var(--bym-primary); background: var(--bym-surface-soft); color: var(--bym-primary); }
.tag-pill.selected, .kidbtn.selected { background: var(--bym-primary); border-color: var(--bym-primary); color: var(--bym-on-primary); font-weight: 600; }
@media (max-width: 600px) { .tag-pill { padding: 0 14px; font-size: var(--bym-text-xs); } .tab-btn { padding: 0 14px; font-size: var(--bym-text-xs); } }

/* ---- Fields ---- */
.text-area-wrap label { color: var(--bym-primary); font-size: var(--bym-text-xs); font-weight: 600; }
.text-area-wrap textarea, input.input, select { background: var(--bym-surface); border: 1px solid var(--bym-border); border-radius: 4px; color: var(--bym-text); font-family: var(--font-display); font-size: var(--bym-text-sm); outline: none; }
.text-area-wrap textarea { min-height: 220px; padding: 14px 16px; }
input.input, select { min-height: var(--bym-control-height); padding: 8px 12px; }
.text-area-wrap textarea:focus, input.input:focus, select:focus { border-color: var(--bym-focus); outline: 3px solid var(--bym-focus); outline-offset: 2px; }
.text-area-wrap textarea::placeholder { color: var(--bym-text-muted); opacity: 1; }
input[type="checkbox"], input[type="radio"] { accent-color: var(--bym-primary); }

/* ---- Buttons ---- */
.btn { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; border-radius: 4px; background: var(--bym-primary); color: var(--bym-on-primary); border: 1px solid var(--bym-primary); font-size: var(--bym-text-sm); font-weight: 600; transition: none; }
.btn-outline { background: transparent; color: var(--bym-primary); border-color: var(--bym-primary); }
.btn-outline:hover { background: var(--bym-surface-soft); }
.btn-small { padding: 0 14px; font-size: var(--bym-text-xs); }
.export-bar { background: var(--bym-surface); border-top: 1px solid var(--bym-rule); }
.btn-export { min-height: 48px; border-radius: 4px; background: var(--bym-primary) !important; background-image: none !important; color: var(--bym-on-primary); font-size: var(--bym-text-sm); font-weight: 600; transition: none; }
.btn-export:hover { background: #2f1f2e !important; }
.copied-msg { color: var(--bym-success); font-size: var(--bym-text-xs); font-weight: 600; }
.sync-indicator { background: var(--bym-primary); border: 0; border-radius: 4px; color: var(--bym-on-primary); font-size: var(--bym-text-xs); }

/* ---- Inline style="" attributes the markup (and its scripts) set directly ---- */
[style*="color:#978396"], [style*="color: #978396"], [style*="color:#7A6678"], [style*="color: #7A6678"] { color: var(--bym-text-muted) !important; }
[style*="color:#B88355"], [style*="color: #B88355"] { color: var(--bym-primary) !important; }
[style*="color:#412B3F"] { color: var(--bym-primary) !important; }
[style*="color:#5a8a6a"], [style*="color:#3e5f48"] { color: var(--bym-success) !important; }
[style*="color:#c47070"], [style*="color:#a84040"] { color: var(--bym-error) !important; }
[style*="font-size:9px"], [style*="font-size:10px"], [style*="font-size:11px"], [style*="font-size:11.5px"], [style*="font-size:12px"], [style*="font-size:12.5px"], [style*="font-size:13px"], [style*="font-size:13.5px"] { font-size: var(--bym-text-xs) !important; }
[style*="border-radius:10px"], [style*="border-radius:12px"], [style*="border-radius:14px"], [style*="border-radius:9px"], [style*="border-radius:8px"] { border-radius: 4px !important; }
[style*="background:#EFD8D0"]:not(body > div:first-of-type) { background: var(--bym-surface-soft) !important; }
[style*="background:#fbeed9"], [style*="background:#f6efe4"], [style*="background:#ecdfd0"], [style*="background:#fdf3e4"] { background: var(--bym-surface-soft) !important; }

/* ---- "Report an issue" (report-issue.js), same treatment as the landing page ---- */
.bym-ri-btn { border-radius: 4px !important; box-shadow: none !important; min-height: var(--bym-target-min); padding: 0 16px !important; font-size: var(--bym-text-sm) !important; background: var(--bym-canvas) !important; color: var(--bym-primary) !important; border: 1px solid var(--bym-primary) !important; }
.bym-ri-btn:hover { background: var(--bym-surface-soft) !important; color: var(--bym-primary) !important; }
@media (max-width: 760px) { .bym-ri-btn { bottom: 84px !important; } }
.bym-ri-box { border-radius: 4px !important; box-shadow: none !important; }
.bym-ri-box button, .bym-ri-box textarea, .bym-ri-box input[type=email] { border-radius: 4px !important; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
input[type="range"] { min-height: 44px; accent-color: var(--bym-primary); }

/* Same rule for inline styles written with a space after the colon. */
[style*="font-size: 9px"], [style*="font-size: 10px"], [style*="font-size: 11px"], [style*="font-size: 11.5px"], [style*="font-size: 12px"], [style*="font-size: 12.5px"], [style*="font-size: 13px"], [style*="font-size: 13.5px"] { font-size: var(--bym-text-xs) !important; }
