/* ============================================
   CSS Variables - Brand Colors
   xTimer identity: deep calm blue on cream.
   Area-vs-saturation rule: saturated color only on SMALL elements
   (buttons, links, selections); large surfaces stay neutral or tinted.
   Accent is ~68% saturation (not full) to avoid simultaneous-contrast
   vibration against warm cream. Neutral family stays warm throughout.
   ============================================ */
:root {
    --color-primary: #2547c0;
    --color-primary-dark: #1c3799;
    --color-primary-light: #4d69d4;
    --color-primary-rgba: rgba(37, 71, 192, 0.10);
    --color-primary-rgba-hover: rgba(37, 71, 192, 0.20);
    /* The two *-gradient tokens are flat on purpose (Cobalt + cream: no
       gradients). Kept because many templates still reference them;
       customer-site palettes in design_system.py set their own values. */
    --color-primary-gradient: var(--color-primary);
    --color-text-primary: #14161a;
    --color-text-secondary: #33363c;
    --color-text-tertiary: #55585f;
    --color-text-quaternary: #6a6e76;
    --color-text-muted: #8a8e96;
    --color-text-light: #c9c6bd;
    --color-border: #e3ddcd;
    --color-border-light: #efe9db;
    --color-background: #ffffff;
    --color-background-light: #faf8f2;
    --color-background-lighter: #f7f4ec;
    --color-background-blue: #f0ede2;
    --color-background-blue-light: #f7f4ec;
    --color-background-gradient: var(--color-background-light);
    --color-success: #22c55e;
    --color-success-bg: #f0fdf4;
    --color-success-border: #bbf7d0;
    --color-success-text: #166534;
    --color-success-bg-alt: #e8f5e9;
    --color-success-text-alt: #2e7d32;
    --color-success-border-alt: #a5d6a7;
    --color-error: #c53030;
    --color-error-bg: #fff5f5;
    --color-error-border: #feb2b2;
    --color-error-bg-alt: #fce8e8;
    --color-error-border-alt: #f5b5b5;
    --color-shadow-xs: rgba(20, 22, 26, 0.08);
    --color-shadow-sm: rgba(20, 22, 26, 0.10);
    --color-shadow-md: rgba(20, 22, 26, 0.20);
    --color-gray-light: #d8d3c4;
    --color-gray-lighter: #e3ddcd;
    --icon-edit: "✎";
}

/* Global edit icon - use with class for consistent inclined pencil */
.icon-edit {
    font-style: normal;
}

/* ============================================
   Reset & Base Styles
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scrollbar-gutter: stable;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: var(--color-text-secondary);
    background: var(--color-background-light);
    overflow-x: hidden;
}

/* ============================================
   Global checkbox - consistent size across all pages
   ============================================ */
input[type="checkbox"] {
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    cursor: pointer;
    flex-shrink: 0;
}

/* ============================================
   Pro SMS badge - used in settings and elsewhere
   ============================================ */
.pro-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--color-primary);
    background: var(--color-primary-rgba);
    padding: 2px 6px;
    border-radius: 8px;
    margin-left: 4px;
    white-space: nowrap;
    text-decoration: none;
    vertical-align: middle;
    box-sizing: border-box;
}
a.pro-badge {
    cursor: pointer;
}
a.pro-badge:hover {
    text-decoration: underline;
}
/* Disabled context: parent opacity dims badge; only disable link clicks */
.pro-badge-disabled a.pro-badge {
    pointer-events: none;
}

/* Plan mismatch / limit exceeded: greyed out with plan badge */
.plan-mismatch {
    opacity: 0.6;
}
.plan-mismatch .plan-badge {
    opacity: 1;
}

/* ============================================
   Sticky footer layout
   --------------------------------------------
   Usage (provider inner pages):
     <body class="layout-sticky-footer">
       <div class="... layout-main">  ← grows to fill space
         ...page content...
       </div>
       <div class="page-footer">     ← always at bottom
         © <span id="yr"></span> xTimer
       </div>
     </body>
   --------------------------------------------
   Rule: .page-footer must be a DIRECT child of body
   (sibling of layout-main), NOT nested inside it.
   Public/landing pages use .bottom-footer instead.
   ============================================ */
body.layout-sticky-footer {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

body.layout-sticky-footer .layout-main {
    flex: 1;
    width: 100%;
    padding-bottom: 30px;
}

.page-footer {
    text-align: center;
    padding: 20px;
    color: var(--color-text-muted);
    font-size: 0.9em;
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    color: var(--color-text-primary);
    font-weight: 600;
}

h1 {
    font-size: 2rem;
}

h2 {
    font-size: 1.5em;
}

/* ============================================
   Navigation
   ============================================ */
nav {
    background: white;
    border-bottom: 1px solid var(--color-border-light);
    padding: 0 24px;
    height: 56px;
    display: flex;
    align-items: center;
}

.nav-container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

/* Provider nav: logo left, buttons right (dashboard, subscription, etc.) */
.dashboard-nav .nav-container,
.provider-nav .nav-container {
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.provider-nav .nav-buttons {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.provider-nav .language-selector { font-size: 0.8rem; }
.provider-nav .lang-btn { padding: 0.2rem 0.35rem; font-size: 0.8rem; }
.provider-nav .lang-separator { margin: 0 2px; font-size: 0.7rem; }

.provider-nav .profile-btn {
    background: white;
    border: 1px solid var(--color-primary);
    color: var(--color-primary);
    font-size: 0.9em;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.2s;
}
.provider-nav .profile-btn:hover {
    background: var(--color-primary);
    color: white;
}
.provider-nav .profile-badge {
    padding: 0.35rem 0.6rem !important;
    border: none !important;
    background: transparent !important;
}
.provider-nav .profile-badge:hover {
    background: transparent !important;
    transform: none;
    box-shadow: none;
}
.provider-nav .badge {
    font-size: 0.7em;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
}
.provider-nav .badge-trial {
    background: #fef3c7;
    color: #b45309;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.2;
}
.provider-nav .badge-pro { background: var(--color-primary-rgba); color: var(--color-primary); }
.provider-nav .badge-free { background: #f0f4f8; color: #64748b; }

.provider-nav .profile-dropdown { position: relative; }
.provider-nav .profile-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 2px solid var(--color-primary);
    background: var(--color-primary);
    color: white;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all 0.2s;
}
.provider-nav .profile-avatar:hover {
    background: var(--color-primary-dark);
    border-color: var(--color-primary-dark);
    transform: scale(1.05);
}
.provider-nav .profile-dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 140px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    padding: 6px 0;
    z-index: 1000;
}
.provider-nav .profile-dropdown-menu.open { display: block; }
.provider-nav .profile-dropdown-item {
    display: block;
    padding: 10px 16px;
    color: var(--color-text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.15s;
}
.provider-nav .profile-dropdown-item:hover {
    background: var(--color-background-light);
    color: var(--color-primary);
}
.provider-nav .profile-dropdown-logout:hover { color: #dc2626; }

/* Mobile: single-row header, compact language (show only switch option) */
@media (max-width: 768px) {
    .dashboard-nav .nav-container,
    .provider-nav .nav-container,
    nav .nav-container {
        flex-wrap: nowrap;
    }
    .dashboard-nav .nav-buttons,
    .provider-nav .nav-buttons,
    nav .nav-buttons {
        flex-wrap: nowrap;
        min-width: 0;
    }
    /* Language: hide current, show only "switch to" button */
    .language-selector .lang-separator {
        display: none;
    }
    .language-selector .lang-btn.active {
        display: none;
    }
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
}

        .logo {
            height: 32px;
            width: auto;
        }

.logo-large {
    height: 50px;
}

/* ============================================
   Language Selector
   ============================================ */
.language-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.language-selector form {
    display: inline;
}

.lang-btn {
    background: none;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.3rem 0.5rem;
    text-decoration: none;
    transition: color 0.2s;
}

.lang-btn:hover {
    color: var(--color-primary);
}

.lang-btn.active {
    color: var(--color-primary);
    font-weight: 600;
}

.lang-separator {
    color: var(--color-text-light);
    margin: 0 8px;
}

/* Global nav buttons (landing, dashboard, etc.) */
.nav-btn {
    padding: 6px 14px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    line-height: 1.2;
    display: inline-flex;
    align-items: center;
    transition: all 0.2s ease;
}
.nav-btn-outline {
    color: var(--color-primary);
    border: 1.5px solid var(--color-primary);
    background: transparent;
}
.nav-btn-outline:hover {
    background: var(--color-background-blue);
    text-decoration: none;
}
.nav-btn-fill {
    background: var(--color-primary);
    color: white;
    border: 1.5px solid var(--color-primary);
}
.nav-btn-fill:hover {
    background: var(--color-primary-dark);
    border-color: var(--color-primary-dark);
    text-decoration: none;
}

/* ============================================
   Back Button (shared across pages)
   ============================================ */
.back-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    color: var(--color-text-quaternary);
    text-decoration: none;
    transition: all 0.2s;
}

.back-btn:hover {
    background: var(--color-background-light);
    color: var(--color-text-primary);
}

.back-btn--absolute {
    position: absolute;
    top: 16px;
    left: 16px;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    padding: 0.7rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    display: inline-block;
}

.btn:active:not(:disabled),
.submit-btn:active:not(:disabled) {
    transform: translateY(1px);
}

.btn:focus-visible,
.submit-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--color-primary-rgba-hover);
}

.btn-primary {
    background: var(--color-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--color-primary-dark);
}

.btn-secondary {
    background: transparent;
    color: var(--color-primary);
    border: 1px solid var(--color-primary);
}

.btn-secondary:hover {
    background: var(--color-background-blue);
}

.submit-btn {
    width: 100%;
    padding: 14px;
    background: var(--color-primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, box-shadow 0.15s;
    margin-top: 10px;
}

.submit-btn:hover {
    background: var(--color-primary-dark);
}

/* ============================================
   Forms
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: var(--color-text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="time"],
input[type="tel"],
.modal-box input[type="number"],
select,
textarea {
    width: 100%;
    padding: 13px 16px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.15s, box-shadow 0.15s;
    background: white;
    font-family: inherit;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="date"]:focus,
input[type="time"]:focus,
input[type="tel"]:focus,
.modal-box input[type="number"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    background: white;
    box-shadow: 0 0 0 3px var(--color-primary-rgba);
}

input[type="checkbox"] {
    accent-color: var(--color-primary);
}

/* ============================================
   Containers & Cards
   ============================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.card {
    background: white;
    padding: 40px;
    border-radius: 8px;
    border: 1px solid var(--color-border-light);
    box-shadow: 0 1px 2px var(--color-shadow-xs);
}

/* Ring instead of border: the dashboards make .section full-bleed on phones
   with their own bottom divider and box-shadow: none, which drops the ring. */
.section {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 0 0 1px var(--color-border-light);
    margin-bottom: 30px;
}

.section-header-with-tabs {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    align-items: center;
    gap: 12px 20px;
    margin-bottom: 20px;
}
.section-header-with-tabs .calendar-tabs {
    margin-bottom: 0;
}
@media (max-width: 767px) {
    .section-header-with-tabs {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ============================================
   Messages & Alerts
   ============================================ */
.success-message {
    background: var(--color-success-bg);
    color: #166534;
    padding: 12px;
    border-radius: 5px;
    margin-bottom: 20px;
    border: 1px solid var(--color-success-border);
}

.error-message {
    background: var(--color-error-bg);
    color: var(--color-error);
    padding: 12px;
    border-radius: 5px;
    margin-bottom: 20px;
    border: 1px solid var(--color-error-border);
}

/* ============================================
   Toast notifications (global)
   ============================================ */
.toast-notification {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 12px var(--color-shadow-sm);
    font-size: 0.9em;
    z-index: 10000;
    animation: toastSlideIn 0.3s ease;
}
.toast-notification[data-type="success"] {
    background: var(--color-success-bg);
    color: var(--color-success-text);
    border: 1px solid var(--color-success-border);
}
.toast-notification[data-type="error"] {
    background: var(--color-error-bg);
    color: var(--color-error);
    border: 1px solid var(--color-error-border);
}
.toast-notification[data-type="warning"] {
    background: #fffbeb;
    color: #b45309;
    border: 1px solid #fde68a;
}
.toast-notification:not([data-type]),
.toast-notification[data-type="info"] {
    background: var(--color-background-light);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}
@keyframes toastSlideIn {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ============================================
   Modals (dashboard showModal(), #addCalendarModal) — same sheet
   language as the setup wizard: ink wash + blur, 8px white sheet,
   footer bar; bottom sheet on phones.
   Children are scoped under .modal-box because customer booking pages
   reuse .modal-buttons / .modal-btn for different markup.
   ============================================ */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(20, 22, 26, 0.32);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: modal-fade-in 0.18s ease;
}
.modal-box {
    width: 100%;
    max-width: 420px;
    max-height: calc(100dvh - 40px);
    overflow-y: auto;
    background: white;
    border: 1px solid var(--color-border-light);
    border-radius: 8px;
    padding: 20px 20px 0;
    box-shadow: 0 24px 48px -16px rgba(20, 22, 26, 0.3);
    animation: modal-sheet-in 0.24s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.modal-box--wide { max-width: 520px; }
.modal-box .modal-title {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.3;
    color: var(--color-text-primary);
    margin-bottom: 8px;
}
.modal-box .modal-subtitle {
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.35;
    color: var(--color-primary);
    margin: -2px 0 10px;
}
.modal-box .modal-message {
    font-size: 0.92rem;
    line-height: 1.55;
    color: var(--color-text-tertiary);
}
.modal-box .modal-input {
    width: 100%;
    min-height: 88px;
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid var(--color-border);
    border-radius: 8px;
    background: white;
    font-family: inherit;
    font-size: 0.92rem;
    resize: vertical;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.modal-box .modal-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-rgba);
}
.modal-box .modal-buttons {
    position: sticky;
    bottom: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    margin: 20px -20px 0;
    padding: 14px 20px;
    border-top: 1px solid var(--color-border-light);
    border-radius: 0 0 7px 7px;
    background: white;
}
.modal-box .modal-btn {
    padding: 9px 16px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.25;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
}
.modal-box .modal-btn:active:not(:disabled) { transform: translateY(1px); }
.modal-box .modal-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--color-primary-rgba-hover);
}
.modal-box .modal-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.modal-box .modal-btn-primary { background: var(--color-primary); color: white; }
.modal-box .modal-btn-primary:hover { background: var(--color-primary-dark); }
.modal-box .modal-btn-secondary {
    background: white;
    color: var(--color-text-primary);
    border-color: var(--color-border);
}
.modal-box .modal-btn-secondary:hover { background: var(--color-background-lighter); }
.modal-box .modal-btn-danger { background: var(--color-error); color: white; }
.modal-box .modal-btn-danger:hover { background: #a52828; }
@keyframes modal-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes modal-sheet-in {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: none; }
}
@media (max-width: 640px) {
    .modal-overlay {
        align-items: flex-end;
        padding: 0;
    }
    .modal-box {
        max-width: none;
        max-height: 90dvh;
        border-bottom: none;
        border-radius: 8px 8px 0 0;
    }
    .modal-box .modal-buttons {
        border-radius: 0;
        padding-bottom: calc(14px + env(safe-area-inset-bottom));
    }
    .modal-box .modal-btn { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
    .modal-overlay,
    .modal-box { animation: none; }
}

/* ============================================
   Links
   ============================================ */
a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    text-decoration: underline;
}

/* ============================================
   Page header (back + title, used in settings, calendar, etc.)
   ============================================ */
.page-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 30px;
    background: white;
    padding: 16px 20px;
    border: 1px solid var(--color-border-light);
    border-radius: 8px;
    box-shadow: 0 1px 2px var(--color-shadow-xs);
}
.page-header .back-btn {
    margin-top: 5px;
    flex-shrink: 0;
}
.page-header h1 {
    margin: 0;
    font-size: 1.3em;
    color: var(--color-text-primary);
    font-weight: 700;
    letter-spacing: -0.01em;
}

/* ============================================
   Header Styles (dashboard/nav)
   ============================================ */
.header {
    background: white;
    border-bottom: 1px solid var(--color-border);
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* ============================================
   Utilities
   ============================================ */
.text-center {
    text-align: center;
}

.text-muted {
    color: var(--color-text-muted);
}

.text-secondary {
    color: var(--color-text-secondary);
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* ============================================
   Footer
   ============================================ */
.bottom-footer {
    margin-top: auto;
    background: white;
    border-top: 1px solid #e5e5e5;
    padding: 10px 16px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.05);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.footer-link {
    color: #555;
    text-decoration: none;
    font-size: 13px;
    transition: color 0.2s;
}

.footer-link:hover {
    color: var(--color-primary);
}

.footer-separator {
    color: #ccc;
    font-size: 12px;
}

.footer-company {
    color: #777;
    font-size: 12px;
}

.footer-company a {
    color: #555;
    text-decoration: none;
}

.footer-company a:hover {
    color: var(--color-primary);
}

.footer-copyright {
    color: #888;
    font-size: 12px;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .footer-links {
        justify-content: center;
    }
    .footer-links .footer-separator:last-of-type {
        display: none;
    }
}

@media (max-width: 480px) {
    nav {
        padding: 0 12px;
    }

    .logo {
        height: 28px;
    }

    .lang-btn {
        font-size: 0.85rem;
        padding: 0.2rem 0.4rem;
    }

    .lang-separator {
        margin: 0 4px;
    }
}

/* ============================================
   Calendar tabs (minimalistic)
   ============================================ */
.calendar-tabs {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}
.calendar-tab {
    padding: 6px 12px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--color-text-quaternary);
    text-decoration: none;
    border-radius: 6px;
    transition: color 0.15s, background 0.15s;
}
.calendar-tab:hover {
    color: var(--color-text-primary);
    background: var(--color-background-light);
}
.calendar-tab.active {
    color: var(--color-primary);
    background: var(--color-primary-rgba);
}
.calendar-tab.calendar-hidden {
    color: #b8c4d4;
}
.calendar-tab.calendar-hidden:hover {
    color: #94a3b8;
}
.calendar-tab.calendar-hidden.active {
    color: #94a3b8;
    background: rgba(184, 196, 212, 0.2);
}
.calendar-select option.calendar-hidden {
    color: #b8c4d4;
}
.calendar-tab-add {
    padding: 6px 10px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--color-text-muted);
    background: transparent;
    border: 1px dashed var(--color-border);
    border-radius: 6px;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s;
}
.calendar-tab-add:hover {
    color: var(--color-primary);
    border-color: var(--color-primary-light);
}

.calendar-dropdown-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.calendar-dropdown-wrap .calendar-select,
.calendar-dropdown-wrap .calendar-tab-add {
    height: 34px;
    min-height: 34px;
    box-sizing: border-box;
}
.calendar-dropdown-wrap .calendar-select {
    line-height: 1.2;
}
.calendar-dropdown-wrap .calendar-tab-add {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    padding: 0;
}
.calendar-select {
    padding: 6px 10px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid var(--color-border);
    border-radius: 6px;
    background: white;
    color: var(--color-text-primary);
    cursor: pointer;
}
.calendar-select-compact {
    min-width: 12ch;
    max-width: 100%;
    box-sizing: border-box;
}
.calendar-tab-add-inline {
    flex-shrink: 0;
}

/* Provider page calendar pills */
.calendar-picker {
    margin-bottom: 20px;
}
.calendar-picker-label {
    font-size: 0.85rem;
    color: var(--color-text-quaternary);
    margin-bottom: 8px;
}
.calendar-pills {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.calendar-pill {
    padding: 6px 12px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--color-text-quaternary);
    text-decoration: none;
    border-radius: 6px;
    background: var(--color-background-light);
    border: none;
    transition: color 0.15s, background 0.15s;
}
.calendar-pill:hover {
    color: var(--color-text-primary);
    background: var(--color-gray-lighter);
}
.calendar-pill.active {
    color: var(--color-primary);
    background: var(--color-primary-rgba);
}

/* Group badge styles - centralized */
.group-badge {
    display: inline-flex;
    align-items: center;
    color: #666;
    font-size: 16px;
    letter-spacing: -15px;
    padding-right: 15px;
}

.group-badge-small {
    display: inline-flex;
    align-items: center;
    background: #eff6ff;
    color: #3b82f6;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 16px;
    font-weight: 600;
    border: 1px solid #bfdbfe;
    letter-spacing: normal;
}

