:root {
    --blue: #2563eb;
    --green: #38cc75;
    --ink: #1d1d1f;
    --sub: #6e6e73;
    --paper: #f4f4f4;
    --line: rgba(0, 0, 0, .08);
    --ease: cubic-bezier(.2, .7, .2, 1);
    --font: "Geist", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
    font-family: var(--font);
    background: var(--paper);
    color: var(--ink);
    -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }

.site-header { position: fixed; top: 12px; left: 0; right: 0; z-index: 15; padding: 0 12px; }
.nav-pill {
    background: rgba(255, 255, 255, .9);
    backdrop-filter: saturate(180%) blur(16px);
    -webkit-backdrop-filter: saturate(180%) blur(16px);
    box-shadow: 0 10px 30px -12px rgba(0, 0, 0, .18), 0 0 0 1px rgba(0, 0, 0, .04);
}
.site-header .nav-bar {
    max-width: 1152px;
    margin: 0 auto;
    height: 64px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px 0 22px;
    gap: 16px;
}
.site-header .brand-wrap { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.site-header .brand { display: flex; align-items: center; text-decoration: none; }
.site-header .brand img { height: 28px; width: auto; }
.nav-row { display: none; align-items: center; gap: 22px; font-size: 14px; font-weight: 500; color: rgba(26, 26, 26, .7); }
.nav-row a { text-decoration: none; }
.nav-row a:hover, .nav-burger:hover { color: #1a1a1a; }
.site-header a[aria-current="page"] { color: #1a1a1a; font-weight: 600; }
.nav-end { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.nav-burger {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #1a1a1a;
    display: grid;
    place-items: center;
}
.nav-burger:hover { background: rgba(0, 0, 0, .05); }
.nav-sheet { max-width: 1152px; margin: 8px auto 0; border-radius: 24px; padding: 8px; }
.nav-sheet > a, .nav-sheet button.cn-premium-toggle-mobile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    text-align: left;
    text-decoration: none;
    padding: 12px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    color: rgba(26, 26, 26, .8);
}
.nav-sheet a:hover, .nav-sheet button.cn-premium-toggle-mobile:hover { background: rgba(0, 0, 0, .05); }
.btn-dark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #1a1a1a;
    color: #fff;
    text-decoration: none;
    border-radius: 999px;
    padding: 10px 18px;
    font-size: 14px;
    font-weight: 600;
}
.btn-dark:hover { background: #2563eb; color: #fff; }
.text-btn {
    border: 0;
    background: transparent;
    color: rgba(26, 26, 26, .7);
    font-size: 14px;
    font-weight: 500;
}
.premium-badge { display: inline-flex; align-items: center; gap: .85rem; text-decoration: none; }
.premium-divider { width: 1px; height: 17px; background: rgba(26, 26, 26, .2); display: block; }
.premium-badge-img {
    display: block;
    height: 11px;
    aspect-ratio: 1583 / 130;
    background: linear-gradient(90deg, #2663eb 0%, #2663eb 45%, #38cc75 100%);
    -webkit-mask: url(/img/premium_text.png?v=2) no-repeat center / contain;
    mask: url(/img/premium_text.png?v=2) no-repeat center / contain;
}
/* The round profile badge is injected into .nav-end. On a phone the
   Sign out label pushes it past the pill, so sign out lives in the menu. */
.nav-signout {
    display: flex;
    align-items: center;
    width: 100%;
    margin-top: 4px;
    padding: 12px;
    border: 0;
    border-radius: 12px;
    background: transparent;
    font-size: 15px;
    font-weight: 500;
    color: rgba(26, 26, 26, .8);
    text-align: left;
}
.nav-signout:hover { background: rgba(0, 0, 0, .05); }
@media (max-width: 1023px) {
    .site-header .nav-bar { padding: 0 6px 0 14px; gap: 8px; }
    .site-header .brand-wrap { min-width: 0; gap: 8px; }
    .site-header .brand { min-width: 0; overflow: hidden; }
    .site-header .brand img { height: 22px; width: auto; max-width: 24vw; object-fit: contain; }
    .nav-burger { width: 36px; height: 36px; }
    .premium-badge { gap: .4rem; }
    .premium-badge-img { height: 8px; }
    .nav-end #signOutBtn { display: none !important; }
}
@media (min-width: 1024px) {
    .site-header { padding: 0 20px; }
    .nav-row { display: flex !important; }
    .nav-burger, .nav-sheet, .nav-signout { display: none !important; }
}

.shell { max-width: 720px; margin: 0 auto; padding: 108px 20px 80px; }
.panel {
    background: #fff;
    border-radius: 28px;
    box-shadow: 0 24px 48px -28px rgba(0, 0, 0, .28), 0 0 0 1px var(--line);
    padding: 28px;
}
h1 { font-size: 32px; letter-spacing: -.03em; font-weight: 600; margin: 0 0 6px; }
.visits-title { display: flex; align-items: flex-start; gap: 8px; }
.beta-badge {
    margin-top: 5px;
    padding: 2px 7px;
    border-radius: 999px;
    background: rgba(38, 99, 235, .1);
    color: #2663eb;
    font-size: 11px;
    font-weight: 650;
    letter-spacing: .06em;
    line-height: 1.4;
    text-transform: uppercase;
}
.lede { margin: 0 0 22px; color: var(--sub); font-size: 16px; line-height: 1.45; }

.pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    padding: 12px 18px;
    background: #1a1a1a;
    color: #fff;
    transition: background .2s var(--ease), transform .2s var(--ease);
}
.pill:hover { background: var(--blue); }
.pill:disabled { background: #d2d2d7; color: #fff; cursor: default; }
.pill.secondary {
    background: #fff;
    color: var(--ink);
    box-shadow: inset 0 0 0 1px var(--line);
}
.pill.secondary:hover { background: var(--paper); }
.stack { display: flex; flex-direction: column; gap: 10px; }
.auth-card { max-width: 420px; margin: 48px auto; }
.loading-card { max-width: 420px; margin: 48px auto; text-align: center; }
.loading-card .after-mark { margin-bottom: 18px; }
.loading-card .lede { margin-bottom: 0; }
.field { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; }
.field span, .label { font-size: 13px; color: var(--sub); }
.field input, .field select, .name-row input, .toolbar select, .toolbar input {
    border: 1px solid var(--line);
    background: #fff;
    border-radius: 14px;
    padding: 12px 14px;
    outline: none;
}
.field input:focus, .field select:focus, .name-row input:focus, .toolbar select:focus, .toolbar input:focus {
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .15);
}
.status { min-height: 1.2em; color: #b42318; font-size: 14px; margin-top: 10px; }
.quiet { color: var(--sub); font-size: 14px; line-height: 1.45; }

.toolbar { display: flex; gap: 8px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 12px; }
.toolbar h2 { font-size: 18px; margin: 0 0 4px; font-weight: 600; flex: 1 0 100%; }
.name-row input::placeholder { color: #a1a1a6; }
.icon-btn, .today-btn {
    border: 0;
    background: var(--paper);
    border-radius: 999px;
    height: 36px;
    padding: 0 12px;
}
.visit-list { display: flex; flex-direction: column; gap: 8px; max-height: 320px; overflow: auto; }
.visit-card {
    text-align: left;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.visit-card strong { font-size: 15px; font-weight: 600; }
.visit-card span { color: var(--sub); font-size: 13px; }
.visit-card.selected { border-color: var(--blue); background: rgba(37, 99, 235, .06); }
.name-row { display: flex; gap: 8px; }
.name-row input { flex: 1; }
.check {
    width: 46px;
    border: 0;
    border-radius: 14px;
    background: var(--paper);
}
.send-box {
    margin-top: 16px;
    padding: 14px;
    border-radius: 18px;
    background: var(--paper);
}
.send-box label { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.actions { margin-top: 18px; display: flex; flex-wrap: wrap; gap: 10px; }
.banner {
    background: #fff;
    border-radius: 18px;
    padding: 12px 14px;
    margin-bottom: 14px;
    box-shadow: inset 0 0 0 1px var(--line);
    color: var(--sub);
    font-size: 14px;
    line-height: 1.45;
}
.progress-line { margin-top: 14px; color: var(--sub); font-size: 14px; }
.hidden { display: none !important; }

.after-visit {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(244, 244, 244, .72);
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    animation: afterFade .35s var(--ease);
}
@keyframes afterFade { from { opacity: 0; } to { opacity: 1; } }
.after-card {
    width: min(440px, 100%);
    background: #fff;
    border-radius: 28px;
    padding: 30px 28px 26px;
    box-shadow: 0 40px 80px -36px rgba(0, 0, 0, .35), 0 0 0 1px var(--line);
    text-align: center;
    animation: afterRise .45s var(--ease);
}
@keyframes afterRise { from { transform: translateY(14px) scale(.98); opacity: 0; } to { transform: none; opacity: 1; } }
.after-mark {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, .9), rgba(59, 130, 246, .18) 60%, rgba(16, 185, 129, .22));
    box-shadow: inset 0 0 0 1px rgba(59, 130, 246, .18);
}
.after-spinner {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 2.5px solid rgba(59, 130, 246, .2);
    border-top-color: #3B82F6;
    animation: afterSpin .9s linear infinite;
}
@keyframes afterSpin { to { transform: rotate(360deg); } }
.after-mark.done { background: linear-gradient(135deg, #3B82F6, #10B981); box-shadow: none; }
.after-mark.done::after { content: "✓"; color: #fff; font-size: 28px; font-weight: 600; }
.after-mark.failed { background: #fff4f2; box-shadow: inset 0 0 0 1px rgba(180, 35, 24, .2); }
.after-mark.failed::after { content: "!"; color: #b42318; font-size: 28px; font-weight: 600; }
.after-card h2 { margin: 0; font-size: 22px; letter-spacing: -.02em; font-weight: 600; }
.after-sub { margin: 6px 0 0; color: var(--sub); font-size: 15px; }
.after-steps {
    list-style: none;
    margin: 22px 0 0;
    padding: 0;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.after-steps li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    color: #a1a1a6;
}
.after-steps li::before {
    content: "";
    flex: 0 0 18px;
    height: 18px;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1.5px #d2d2d7;
}
.after-steps li.active { color: var(--ink); }
.after-steps li.active::before { box-shadow: inset 0 0 0 1.5px #3B82F6; background: radial-gradient(circle, #3B82F6 0 4px, transparent 5px); }
.after-steps li.done { color: var(--ink); }
.after-steps li.done::before { background: #10B981; box-shadow: none; }
.after-steps li.failed { color: #b42318; }
.after-steps li.failed::before { background: #fde2dd; box-shadow: inset 0 0 0 1.5px #b42318; }
.step-detail { margin-left: auto; color: var(--sub); font-size: 13px; font-variant-numeric: tabular-nums; }
.after-bar {
    margin-top: 20px;
    height: 4px;
    border-radius: 999px;
    background: rgba(0, 0, 0, .06);
    overflow: hidden;
}
.after-bar span {
    display: block;
    height: 100%;
    width: 0%;
    border-radius: inherit;
    background: linear-gradient(90deg, #3B82F6, #06b6d4, #10B981);
    transition: width .4s var(--ease);
}
.after-message { margin: 14px 0 0; min-height: 1.3em; color: var(--sub); font-size: 14px; line-height: 1.45; }
.after-message.error { color: #b42318; }
.after-actions { margin-top: 18px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.after-actions .pill { text-decoration: none; min-width: 140px; }

/* Note viewer: SummaryFileView (iOS) colors, sizes and layout. */
.sfv {
    --sfv-navy: #011c94;
    --sfv-green: #02ff42;
    --sfv-purple: #9C27B0;
    margin-top: 28px;
    scroll-margin-top: 96px;
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", var(--font);
    color: #000;
    animation: afterRise .45s var(--ease);
}
.sfv-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    height: 44px;
}
.sfv-nav { font-size: 17px; font-weight: 600; }
.sfv-save {
    position: absolute;
    right: 4px;
    font-size: 13px;
    color: rgba(60, 60, 67, .6);
}
.sfv-save.error { color: #b42318; }
.sfv-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 12px 0 8px 16px;
}
.sfv-patient {
    margin: 0;
    flex: 1;
    min-width: 0;
    font-size: 28px;
    line-height: 1.2;
    font-weight: 700;
    color: var(--sfv-navy);
    letter-spacing: .01em;
}
.sfv-refresh {
    flex: none;
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    margin-right: 2px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--sfv-navy);
    cursor: pointer;
}
.sfv-refresh:hover { background: rgba(1, 28, 148, .08); }
.sfv-refresh:disabled { cursor: default; }
.sfv-refresh.spin svg { animation: sfv-spin .8s linear infinite; }
@keyframes sfv-spin { to { transform: rotate(-360deg); } }
.sfv-divider {
    height: 2px;
    margin: 4px 0;
    background: linear-gradient(90deg, var(--sfv-navy), var(--sfv-green));
}
.sfv-toggle-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 12px 20px 4px;
    padding: 6px 12px;
    border-radius: 8px;
    background: rgba(128, 128, 128, .08);
    font-size: 12px;
    color: rgba(60, 60, 67, .6);
    cursor: pointer;
}
.sfv-toggle-label { display: inline-flex; align-items: center; gap: 6px; flex: 1; }
.sfv-toggle-row input { position: absolute; opacity: 0; pointer-events: none; }
.sfv-switch {
    width: 41px;
    height: 25px;
    border-radius: 999px;
    background: rgba(120, 120, 128, .16);
    position: relative;
    transition: background .2s;
}
.sfv-switch::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 21px;
    height: 21px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, .15);
    transition: transform .2s var(--ease);
}
.sfv-toggle-row input:checked + .sfv-switch { background: #34c759; }
.sfv-toggle-row input:checked + .sfv-switch::after { transform: translateX(16px); }
.sfv-card {
    position: relative;
    margin: 16px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-radius: 15px;
    background: rgba(128, 128, 128, .1);
}
.sfv-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 15px;
    padding: 2px;
    background: linear-gradient(90deg, var(--sfv-navy), var(--sfv-green));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}
.sfv-row {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 6px 8px;
    margin: 0 -8px;
    border-radius: 10px;
    transition: background .2s;
}
.sfv-row:hover { background: rgba(1, 28, 148, .04); }
.sfv-row.editing { background: #fff; box-shadow: 0 0 0 2px rgba(1, 28, 148, .25); }
.sfv-label {
    font-size: 17px;
    font-weight: 600;
    color: var(--sfv-navy);
}
.sfv-value { display: flex; align-items: flex-start; gap: 8px; }
.sfv-bullet { color: var(--sfv-navy); font-size: 17px; line-height: 22px; }
.sfv-text {
    flex: 1;
    font-size: 17px;
    line-height: 22px;
    white-space: pre-wrap;
    outline: none;
    cursor: text;
    min-height: 22px;
}
.sfv-pill {
    display: inline-flex;
    align-items: center;
    margin: 0 2px;
    padding: 1px 9px;
    border: 1px solid var(--sfv-navy);
    border-radius: 999px;
    background: #fff;
    color: var(--sfv-navy);
    font: inherit;
    font-size: 15px;
    line-height: 20px;
    cursor: pointer;
    vertical-align: baseline;
}
.sfv-pill.empty {
    border-style: dashed;
    color: #6b7280;
}
.sfv-pill.starred { background: rgba(1, 28, 148, .08); }
.sfv-prose { outline: none; border-radius: 4px; }
.sfv-prose:focus { background: rgba(1, 28, 148, .08); }
.sfv-picker {
    position: absolute;
    z-index: 4;
    left: 28px;
    top: calc(100% - 8px);
    width: min(320px, calc(100% - 36px));
    max-height: 280px;
    overflow: auto;
    padding: 12px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 12px 40px rgba(0, 0, 0, .18);
}
.sfv-picker-title { font-weight: 700; color: var(--sfv-navy); }
.sfv-picker-hint { margin: 4px 0 8px; color: #6b7280; font-size: 13px; }
.sfv-options { display: flex; flex-wrap: wrap; gap: 6px; }
.sfv-options.teeth { display: grid; grid-template-columns: repeat(8, 1fr); }
.sfv-option {
    border: 1px solid rgba(1, 28, 148, .35);
    border-radius: 999px;
    background: #fff;
    color: var(--sfv-navy);
    padding: 4px 10px;
    font: inherit;
    font-size: 13px;
    cursor: pointer;
}
.sfv-options.teeth .sfv-option { padding: 6px 0; border-radius: 8px; }
.sfv-option-row { display: flex; align-items: center; gap: 4px; max-width: 100%; }
.sfv-option-row .sfv-option { flex: 1; text-align: left; }
.sfv-star {
    flex: none;
    width: 28px;
    height: 28px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: #c4c4c4;
    font-size: 16px;
    cursor: pointer;
}
.sfv-star.on { color: #e0a100; }
.sfv-picker-star {
    display: block;
    width: 100%;
    margin-top: 8px;
    border: 0;
    background: transparent;
    color: var(--sfv-navy);
    font: inherit;
    font-size: 13px;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}
.sfv-option.on { background: var(--sfv-navy); color: #fff; }
.sfv-option.star:not(.on) { background: rgba(1, 28, 148, .08); }
.sfv-custom {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 10px;
    color: #6b7280;
    font-size: 13px;
}
.sfv-custom input {
    border: 1px solid rgba(1, 28, 148, .35);
    border-radius: 8px;
    padding: 6px 8px;
    font: inherit;
    font-size: 15px;
    color: var(--sfv-ink, #1d1d1f);
}
.sfv-picker-done {
    margin-top: 10px;
    border: 0;
    border-radius: 999px;
    padding: 6px 14px;
    background: var(--sfv-navy);
    color: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}
.sfv-undo {
    position: absolute;
    top: 4px;
    right: 4px;
    display: flex;
    gap: 6px;
}
.sfv-undo button {
    border: 0;
    border-radius: 999px;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    background: var(--sfv-navy);
    box-shadow: 0 4px 10px -4px rgba(1, 28, 148, .5);
}
.sfv-undo button:disabled { background: rgba(120, 120, 128, .35); box-shadow: none; cursor: default; }
.sfv-signature-row { display: flex; justify-content: flex-end; padding-top: 20px; }
.sfv-signature {
    border: 0;
    background: transparent;
    font-family: "Pacifico", cursive;
    font-size: 26px;
    font-weight: 400;
    color: #8e8e93;
    padding: 0 4px;
    transition: color .25s;
}
.sfv-signature.signed { color: var(--sfv-navy); }
.sfv-info {
    margin: 4px 32px 0;
    padding: 12px 14px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 0 0 1px var(--line);
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 14px;
    color: rgba(60, 60, 67, .7);
}
.sfv-info strong { color: #000; font-size: 15px; }
.sfv-actions { display: flex; flex-direction: column; gap: 0; padding: 0 0 8px; }
.sfv-button {
    margin: 16px 16px 0;
    border: 0;
    border-radius: 12px;
    padding: 16px;
    font-size: 17px;
    font-weight: 700;
    color: #fff;
    cursor: pointer;
    transition: filter .2s, transform .1s;
}
.sfv-button:active { transform: scale(.99); }
.sfv-button:hover { filter: brightness(1.08); }
.sfv-button:disabled { background: #8e8e93; cursor: default; filter: none; }
.sfv-button.purple { background: linear-gradient(135deg, var(--sfv-navy), var(--sfv-purple)); }
.sfv-button.blue { background: linear-gradient(135deg, var(--sfv-navy), var(--sfv-green)); }
.sfv-sent {
    margin: 16px 16px 0;
    padding: 14px;
    border-radius: 12px;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: var(--sfv-navy);
    background: rgba(1, 28, 148, .06);
}

.perio-fallback {
    position: fixed;
    inset: 0;
    z-index: 40;
    background: #fff;
    overflow: hidden;
}
.perio-fallback iframe { width: 100%; height: 100%; border: 0; display: block; }

.calming {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 50%, #e2e8f0 100%);
}
.calming-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}
.calming-orb-container {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.calming-orb-container:hover { transform: scale(1.03); }
.calming-orb-container:active { transform: scale(0.97); }
.orb-outer-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 280px;
    height: 280px;
    border-radius: 50%;
    background: radial-gradient(
        circle at center,
        rgba(59, 130, 246, 0.25) 0%,
        rgba(16, 185, 129, 0.15) 45%,
        rgba(16, 185, 129, 0.05) 65%,
        transparent 80%
    );
    animation: glowPulse 6s ease-in-out infinite;
}
@keyframes glowPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.8; }
    50% { transform: translate(-50%, -50%) scale(1.15); opacity: 1; }
}
.orb-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 210px;
    height: 210px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.5), rgba(16, 185, 129, 0.5));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    padding: 2px;
    animation: ringRotate 20s linear infinite, ringPulse 4s ease-in-out infinite;
}
@keyframes ringRotate {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}
@keyframes ringPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}
.orb-inner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 190px;
    height: 190px;
    border-radius: 50%;
    overflow: visible;
}
.orb-gradient {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: conic-gradient(
        from 0deg,
        #3B82F6,
        #FFFFFF,
        #10B981,
        rgba(59, 130, 246, 0.8),
        rgba(255, 255, 255, 0.9),
        rgba(16, 185, 129, 0.8),
        #3B82F6
    );
    filter: blur(25px);
    animation: orbRotate 8s linear infinite;
}
@keyframes orbRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}
.orb-gradient-overlay {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: radial-gradient(
        circle at 30% 30%,
        rgba(255, 255, 255, 0.7) 0%,
        rgba(255, 255, 255, 0.3) 30%,
        rgba(255, 255, 255, 0.1) 50%,
        transparent 70%
    );
    animation: highlightShift 10s ease-in-out infinite;
}
@keyframes highlightShift {
    0%, 100% { transform: translate(0, 0); opacity: 0.9; }
    25% { transform: translate(5%, -5%); opacity: 0.7; }
    50% { transform: translate(-3%, 3%); opacity: 0.8; }
    75% { transform: translate(2%, 5%); opacity: 0.6; }
}
.orb-inner::before {
    content: "";
    position: absolute;
    top: -10px;
    left: -10px;
    width: calc(100% + 20px);
    height: calc(100% + 20px);
    border-radius: 50%;
    background: conic-gradient(
        from 180deg,
        transparent,
        rgba(59, 130, 246, 0.3),
        transparent,
        rgba(16, 185, 129, 0.3),
        transparent
    );
    filter: blur(15px);
    animation: orbRotateReverse 12s linear infinite;
}
@keyframes orbRotateReverse {
    from { transform: rotate(360deg); }
    to { transform: rotate(0deg); }
}
.orb-inner::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 150%;
    height: 150%;
    border-radius: 50%;
    background:
        radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.4) 0%, transparent 8%),
        radial-gradient(circle at 80% 70%, rgba(59, 130, 246, 0.3) 0%, transparent 10%),
        radial-gradient(circle at 70% 20%, rgba(16, 185, 129, 0.3) 0%, transparent 6%),
        radial-gradient(circle at 30% 80%, rgba(255, 255, 255, 0.3) 0%, transparent 7%);
    animation: particleFloat 15s ease-in-out infinite;
    pointer-events: none;
}
@keyframes particleFloat {
    0%, 100% { transform: translate(-50%, -50%) rotate(0deg) scale(1); opacity: 0.6; }
    33% { transform: translate(-50%, -50%) rotate(120deg) scale(1.1); opacity: 0.8; }
    66% { transform: translate(-50%, -50%) rotate(240deg) scale(0.95); opacity: 0.7; }
}
.overlay-timer {
    font-size: 15px;
    font-weight: 500;
    color: rgba(59, 130, 246, 0.8);
    font-variant-numeric: tabular-nums;
    letter-spacing: 1px;
    padding: 8px 20px;
    background: rgba(59, 130, 246, 0.08);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: 20px;
}
.recording-logo { height: 32px; width: auto; opacity: 0.85; }
.calming-visualizer {
    width: 160px;
    height: 3px;
    background: rgba(0, 0, 0, 0.06);
    border-radius: 2px;
    overflow: hidden;
}
.calming-visualizer-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #3B82F6 0%, #06b6d4 50%, #10B981 100%);
    border-radius: 2px;
    transition: width 0.15s ease-out;
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.4);
}
.recording-hint {
    position: absolute;
    bottom: 48px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 13px;
    color: rgba(0, 0, 0, 0.3);
    font-weight: 400;
    letter-spacing: 0.3px;
    white-space: nowrap;
}
.recording-hint.warn {
    color: #b42318;
    font-weight: 600;
}
@media (prefers-reduced-motion: reduce) {
    .orb-gradient,
    .orb-inner::before,
    .orb-inner::after,
    .orb-ring,
    .orb-outer-glow,
    .orb-gradient-overlay {
        animation: none;
    }
}

body.pip-body {
    min-height: 100%;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 50%, #e2e8f0 100%);
}
body.pip-body .calming { position: relative; min-height: 100vh; }
