:root {
    --app-color: #7C3AED;
    --app-color-rgb: 124, 58, 237;
    --module-ink: #172033;
    --module-muted: #697386;
    --module-surface: rgba(255, 255, 255, .9);
    --module-border: rgba(var(--app-color-rgb), .12);
    --module-shadow: 0 18px 46px rgba(31, 41, 55, .07);
}

/* Structure commune à toutes les applications */
.module-page {
    min-height: 100vh;
    color: var(--module-ink);
    background:
        radial-gradient(circle at 16% 10%, rgba(var(--app-color-rgb), .12), transparent 28%),
        radial-gradient(circle at 90% 12%, rgba(var(--app-color-rgb), .07), transparent 24%),
        linear-gradient(180deg, #fff 0%, color-mix(in srgb, var(--app-color) 2%, #fff) 46%, color-mix(in srgb, var(--app-color) 4%, #fff) 100%);
}
.module-shell { display: flex; min-height: 100vh; }
.module-sidebar { width: 268px; flex: 0 0 268px; padding: 24px 18px; position: sticky; top: 0; height: 100vh; border-right: 1px solid var(--module-border); background: rgba(255,255,255,.72); backdrop-filter: blur(18px); }
.module-brand { display: flex; align-items: center; gap: 12px; padding: 10px 12px 26px; }
.module-brand__icon { width: 44px; height: 44px; border-radius: 16px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, color-mix(in srgb, var(--app-color) 72%, white), var(--app-color)); box-shadow: 0 16px 28px rgba(var(--app-color-rgb), .24); font-size: 1.2rem; }
.module-brand strong { display: block; font-size: 1.02rem; letter-spacing: -.02em; }
.module-menu { display: flex; flex-direction: column; gap: 6px; }
.module-menu a { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 16px; color: #746b83; font-weight: 650; font-size: .92rem; transition: all var(--transition); }
.module-menu a i { font-size: 1.15rem; }
.module-menu a:hover, .module-menu a.is-active { color: var(--app-color); background: color-mix(in srgb, var(--app-color) 10%, #fff); box-shadow: inset 0 0 0 1px rgba(var(--app-color-rgb), .08); }
.module-main { flex: 1 1 auto; min-width: 0; width: auto; margin: 0; padding: 28px 34px 10px; }
.module-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.module-header h1 { margin: 0 0 4px; font-size: 2rem; letter-spacing: -.04em; }
.module-header p { margin: 0; color: #817990; }
.module-back { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 14px; color: #817990; font-size: .86rem; font-weight: 650; }
.module-header__actions { display: flex; align-items: center; gap: 12px; }
.module-header-button { min-height: 44px; display: flex; align-items: center; gap: 10px; padding: 6px 14px 6px 7px; border: 1px solid var(--module-border); border-radius: 16px; color: #21172f; background: #fff; box-shadow: 0 10px 28px rgba(32,23,54,.06); }
.module-header-button > span { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--app-color); font-weight: 800; }
.module-header-button small { color: #6d627d; font-weight: 700; }
.module-primary-button, .module-secondary-button, .module-danger-button { min-height: 44px; padding: 10px 16px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 15px; font: inherit; font-size: .88rem; font-weight: 800; text-decoration: none; transition: transform var(--transition), box-shadow var(--transition), background var(--transition); }
.module-primary-button { color: #fff; background: linear-gradient(135deg, color-mix(in srgb, var(--app-color) 76%, white), var(--app-color)); box-shadow: 0 12px 26px rgba(var(--app-color-rgb), .22); }
.module-primary-button:hover { color: #fff; transform: translateY(-2px); }
.module-secondary-button { color: #655a74; background: color-mix(in srgb, var(--app-color) 7%, #fff); }
.module-danger-button { color: #b42318; background: #fff1f0; }
.module-card { padding: 20px; border: 1px solid var(--module-border); border-radius: 24px; background: var(--module-surface); box-shadow: var(--module-shadow); }
.module-card__header { margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.module-card__header h2 { margin: 0; font-size: 1rem; }
.module-card__header p { margin: 3px 0 0; color: #7b879a; font-size: .75rem; }
.module-card__header a { color: var(--app-color); font-size: .76rem; font-weight: 800; }
.module-kpi-grid { margin-bottom: 20px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.module-kpi { min-height: 128px; padding: 18px; display: grid; grid-template-columns: 46px 1fr; gap: 13px; align-items: start; border: 1px solid var(--module-border); border-radius: 24px; background: var(--module-surface); box-shadow: 0 16px 40px rgba(50,35,75,.07); }
.module-kpi small, .module-kpi strong { display: block; }
.module-kpi small { margin: 2px 0 7px; color: #817990; font-size: .78rem; font-weight: 750; }
.module-kpi strong { color: #251a33; font-size: 1.35rem; letter-spacing: -.04em; }
.module-kpi__icon { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 17px; font-size: 1.25rem; }
.module-kpi__icon.is-purple { color: var(--app-color); background: color-mix(in srgb,var(--app-color) 12%,#fff); }
.module-kpi__icon.is-blue { color: #358ce8; background: #e7f2ff; }
.module-kpi__icon.is-green { color: #159b68; background: #e5f8f0; }
.module-kpi__icon.is-orange { color: #e28d12; background: #fff1d9; }
.module-kpi__icon.is-pink { color: #e9589a; background: #ffe8f2; }
.module-kpi__icon.is-yellow { color: #d99000; background: #fff7d6; }
.module-kpi__icon.is-red { color: #dc2626; background: #fef2f2; }
.module-alert { margin-bottom: 18px; padding: 13px 16px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-radius: 18px; font-weight: 750; box-shadow: 0 12px 32px rgba(32,23,54,.06); }
.module-alert--success { color: #15803d; background: #ecfdf3; border: 1px solid rgba(22,163,74,.16); }
.module-alert--error { color: #b42318; background: #fff1f0; border: 1px solid rgba(244,63,94,.18); }
.module-alert--dismissible { display: flex; align-items: center; justify-content: space-between; gap: 14px; transition: opacity .25s ease, transform .25s ease, margin .25s ease; }
.module-alert--dismissible.is-hiding { opacity: 0; transform: translateY(-6px); margin-top: -8px; }
.module-alert__close { width: 30px; height: 30px; flex: 0 0 30px; display: grid; place-items: center; border: 0; border-radius: 999px; color: inherit; background: rgba(255,255,255,.72); cursor: pointer; font-size: 1rem; transition: all var(--transition); }
.module-alert__close:hover { background: #fff; transform: scale(1.04); }
.module-field { margin-bottom: 14px; }
.module-field:last-child { margin-bottom: 0; }
.module-field label { display: block; margin: 0 0 8px; color: #4d455b; font-size: .83rem; font-weight: 850; }
.module-field label span { color: #817990; font-weight: 650; }
.module-field > input, .module-field > select, .module-field > textarea { width: 100%; min-height: 48px; padding: 0 13px; border: 1px solid #e9e3ef; border-radius: 10px; outline: 0; color: #272033; background: #fff; box-shadow: inset 0 1px 2px rgba(32,23,54,.03); font: inherit; font-weight: 650; }
.module-field > textarea { min-height: 102px; padding-top: 13px; resize: vertical; }
.module-field > input:focus, .module-field > select:focus, .module-field > textarea:focus { border-color: color-mix(in srgb,var(--app-color) 58%,white); box-shadow: 0 0 0 3px rgba(var(--app-color-rgb),.1); }
.module-field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.module-input-icon { height: 48px; display: flex; align-items: center; gap: 8px; padding: 0 13px; border: 1px solid #e9e3ef; border-radius: 10px; background: #fff; box-shadow: inset 0 1px 2px rgba(32,23,54,.03); }
.module-input-icon > i { color: #817990; font-size: 1.06rem; }
.module-input-icon input, .module-input-icon select { width: 100%; border: 0; outline: 0; color: #272033; background: transparent; font: inherit; font-weight: 650; }
.module-input-icon:focus-within { border-color: color-mix(in srgb,var(--app-color) 58%,white); box-shadow: 0 0 0 3px rgba(var(--app-color-rgb),.1); }
.module-input-panel { padding: 18px 20px; border-top: 1px solid #f0edf7; border-bottom: 1px solid #f0edf7; background: rgba(255,255,255,.72); }
.module-form-section { padding: 14px 20px; }
.module-form-section > h2 { display: block; margin: 0 0 8px; color: #4d455b; font-size: .83rem; font-weight: 850; }
.module-choice-picker { display: grid; grid-template-columns: repeat(5,1fr); gap: 10px; padding: 14px 16px 20px; }
.module-choice-picker label { cursor: pointer; text-align: center; }
.module-choice-picker input { position: absolute; opacity: 0; pointer-events: none; }
.module-choice-icon { width: 58px; height: 58px; margin: 0 auto 8px; display: grid; place-items: center; border: 1px solid #eee8f8; border-radius: 50%; color: var(--type-color,var(--app-color)); background: #fff; box-shadow: 0 10px 22px rgba(32,23,54,.05); font-size: 1.32rem; transition: all var(--transition); }
.module-choice-picker small { display: block; color: #272033; font-size: .72rem; font-weight: 800; }
.module-choice-picker label.is-active .module-choice-icon { border-color: var(--type-color,var(--app-color)); background: color-mix(in srgb,var(--type-color,var(--app-color)) 12%,#fff); box-shadow: 0 12px 26px rgba(var(--app-color-rgb),.16); }
.module-choice-picker--four { grid-template-columns: repeat(4,1fr); }
.module-choice-picker--two { grid-template-columns: repeat(2,1fr); }
.module-choice-picker--scroll { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: minmax(76px,1fr); overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin; }
.module-form-panel { margin-top: 12px; padding: 15px; border: 1px solid var(--module-border); border-radius: 18px; background: #fff; box-shadow: 0 12px 30px rgba(39,32,51,.06); }
.module-form-panel[hidden] { display: none; }
.module-inline-note { display: flex; align-items: flex-start; gap: 8px; padding: 10px 12px; border-radius: 12px; color: #5d526d; background: color-mix(in srgb,var(--app-color) 6%,#fff); font-size: .74rem; line-height: 1.45; font-weight: 700; }
.module-inline-note > i { flex: 0 0 auto; color: var(--app-color); font-size: 1rem; }
.module-empty { padding: 32px 18px; display: grid; justify-items: center; gap: 7px; color: #7b879a; text-align: center; }
.module-empty > i { width: 50px; height: 50px; display: grid; place-items: center; border-radius: 18px; color: var(--app-color); background: color-mix(in srgb,var(--app-color) 8%,#fff); font-size: 1.35rem; }
.module-empty > strong { color: #334155; font-size: .88rem; }
.module-empty > span, .module-empty > p { max-width: 340px; margin: 0; font-size: .74rem; line-height: 1.5; }
.module-toolbar { margin-bottom: 16px; padding: 10px; display: flex; align-items: center; justify-content: space-between; gap: 10px; border: 1px solid var(--module-border); border-radius: 20px; background: rgba(255,255,255,.84); }
.module-filter-tabs { display: flex; gap: 5px; }
.module-filter-tabs a { padding: 9px 13px; border-radius: 12px; color: #68758a; font-size: .75rem; font-weight: 800; }
.module-filter-tabs a.is-active { color: #fff; background: var(--app-color); }
.module-search { min-width: 260px; padding: 0 12px; display: flex; align-items: center; gap: 8px; border: 1px solid #e3e8f0; border-radius: 13px; background: #fff; }
.module-search input { width: 100%; height: 38px; border: 0; outline: 0; font-size: .78rem; }
.module-action-group { display: flex; align-items: center; gap: 7px; }
.module-badges { display: flex; align-items: center; justify-content: flex-end; gap: 6px; flex-wrap: wrap; }
.module-badge { padding: 5px 8px; border-radius: 99px; color: #526176; background: #f1f5f9; font-size: .62rem; font-weight: 800; white-space: nowrap; }
.module-badge.is-urgente { color: #b91c1c; background: #fee2e2; }
.module-badge.is-haute { color: #c2410c; background: #ffedd5; }
.module-badge.is-recurrente { color: color-mix(in srgb,var(--app-color) 82%,black); background: color-mix(in srgb,var(--app-color) 16%,#fff); }
.module-badge.is-normale { color: #475569; background: #e2e8f0; }
.module-badge.is-basse { color: #15803d; background: #dcfce7; }
.module-badge.is-fixed { color: #9f1239; background: #ffe4e6; }
.module-badge.is-background { color: #0369a1; background: #e0f2fe; }
.module-period-picker { width: min(100%,430px); margin: 0 auto 18px; padding: 7px; display: grid; grid-template-columns: 46px 1fr 46px; align-items: center; gap: 8px; border: 1px solid var(--module-border); border-radius: 22px; background: rgba(255,255,255,.88); box-shadow: 0 14px 36px rgba(50,35,75,.07); }
.module-period-picker > a { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 15px; color: #6d627d; background: color-mix(in srgb,var(--app-color) 7%,#fff); font-size: 1.35rem; transition: all var(--transition); }
.module-period-picker > a:hover { color: #fff; background: var(--app-color); transform: translateY(-1px); }
.module-period-picker > div { min-width: 0; text-align: center; }
.module-period-picker small, .module-period-picker strong { display: block; }
.module-period-picker small { margin-bottom: 1px; color: #91869d; font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.module-period-picker strong { color: #272033; font-size: .98rem; }

/* Modale et formulaire communs : Work & Gain et Planer */
.module-modal { position: fixed; inset: 0; z-index: 1200; display: none; padding: 28px; }
.module-modal.is-open { display: grid; place-items: center; }
.module-modal__backdrop { position: absolute; inset: 0; background: rgba(39,32,51,.34); backdrop-filter: blur(12px); }
.module-modal__dialog { position: relative; z-index: 1; width: min(540px, 100%); height: min(900px, calc(100vh - 56px)); overflow: hidden; border: 1px solid rgba(255,255,255,.7); border-radius: 30px; background: #fff; box-shadow: 0 34px 90px rgba(39,32,51,.28); animation: moduleModalIn .22s ease both; }
.module-modal__dialog iframe { width: 100%; height: 100%; display: block; border: 0; background: transparent; }
.module-modal-open { overflow: hidden; }
@keyframes moduleModalIn { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
.module-form-page { min-height: 100vh; padding: 24px; display: grid; place-items: start center; }
.module-form-shell { width: min(100%, 540px); }
.module-form-card { min-height: calc(100vh - 48px); overflow: clip; border: 1px solid var(--module-border); border-radius: 28px; background: rgba(255,255,255,.84); box-shadow: 0 24px 70px rgba(39,32,51,.10); backdrop-filter: blur(18px); }
.module-form-header { position: sticky; top: 0; z-index: 10; padding: 24px 22px 12px; display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; gap: 10px; border-bottom: 1px solid var(--module-border); background: rgba(255,255,255,.96); box-shadow: 0 8px 20px rgba(39,32,51,.06); backdrop-filter: blur(18px); }
.module-form-header h1 { margin: 0; text-align: center; font-size: 1.12rem; letter-spacing: -.02em; }
.module-form-header a, .module-form-header button { width: 42px; height: 42px; display: grid; place-items: center; border: 0; border-radius: 16px; color: #272033; background: transparent; font-size: 1.35rem; transition: all var(--transition); }
.module-form-header button { color: var(--app-color); }
.module-form-header a:hover, .module-form-header button:hover { background: color-mix(in srgb, var(--app-color) 8%, #fff); transform: translateY(-1px); }
.module-form-page--modal .module-form-shell { width: 100%; }
.module-form-page--modal .module-form-card { min-height: 100vh; border: 0; border-radius: 0; box-shadow: none; background: rgba(255,255,255,.94); }
.module-page .mobile-bottom-nav { border-color: rgba(var(--app-color-rgb), .12); box-shadow: 0 18px 45px rgba(var(--app-color-rgb), .16); }
.module-page .mobile-nav-item.active { color: var(--app-color); }
.module-page .mobile-nav-add { background: linear-gradient(135deg, color-mix(in srgb, var(--app-color) 76%, white), var(--app-color)); box-shadow: 0 14px 30px rgba(var(--app-color-rgb), .35); }

/* Profil et paramétrage communs */
.module-profile-tabs { width: fit-content; margin-bottom: 22px; padding: 5px; display: flex; align-items: center; gap: 8px; border-radius: 17px; background: color-mix(in srgb, var(--app-color) 8%, #eeeaf3); }
.module-profile-tabs a { min-height: 40px; padding: 8px 18px; display: inline-flex; align-items: center; justify-content: center; border-radius: 13px; color: #655a74; font-size: .88rem; }
.module-profile-tabs a.is-active { color: #fff; background: linear-gradient(135deg, color-mix(in srgb, var(--app-color) 76%, white), var(--app-color)); box-shadow: 0 10px 22px rgba(var(--app-color-rgb), .24); }
.module-profile-layout { display: grid; grid-template-columns: minmax(300px,.8fr) minmax(440px,1.2fr); gap: 22px; align-items: stretch; }
.module-profile-list, .module-profile-editor, .module-profile-account { padding: 22px; border: 1px solid var(--module-border); border-radius: 26px; background: var(--module-surface); box-shadow: var(--module-shadow); }
.module-profile-list { padding: 20px; }
.module-profile-title { margin-bottom: 12px; }
.module-profile-title h2, .module-profile-editor__header h2, .module-profile-account__header h2, .module-profile-account__subtitle h2 { margin: 0 0 4px; color: #272033; font-size: 1.05rem; }
.module-profile-title p, .module-profile-editor__header p, .module-profile-account__header p, .module-profile-account__subtitle p { margin: 0; color: #817990; font-size: .84rem; }
.module-profile-items { display: flex; flex-direction: column; }
.module-profile-item { padding: 13px 8px; display: grid; grid-template-columns: 48px minmax(0,1fr) 22px; gap: 12px; align-items: center; border-top: 1px solid #f0edf7; border-radius: 17px; color: #3b3148; transition: background var(--transition), color var(--transition), transform var(--transition); }
.module-profile-item:first-child { border-top-color: transparent; }
.module-profile-item:hover { color: var(--app-color); transform: translateX(2px); }
.module-profile-item.is-selected { color: var(--app-color); background: color-mix(in srgb, var(--app-color) 10%, #fff); }
.module-profile-item__icon, .module-profile-preview { display: inline-flex; align-items: center; justify-content: center; color: var(--item-color,var(--app-color)); background: color-mix(in srgb, var(--item-color,var(--app-color)) 14%,#fff); }
.module-profile-item__icon { width: 46px; height: 46px; border-radius: 16px; font-size: 1.2rem; }
.module-profile-item__content { min-width: 0; }
.module-profile-item__content strong, .module-profile-item__content small { display: block; }
.module-profile-item__content strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.module-profile-item__content small { margin-top: 3px; color: #817990; font-size: .76rem; }
.module-profile-item > i { color: #a69caf; font-size: 1.2rem; }
.module-profile-editor__header, .module-profile-account__header { margin-bottom: 22px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.module-profile-preview { width: 54px; height: 54px; flex: 0 0 54px; border-radius: 19px; font-size: 1.45rem; }
.module-profile-form { display: flex; flex-direction: column; gap: 16px; }
.module-profile-form .module-field { margin: 0; }
.module-profile-field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.module-profile-actions { padding-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid #f0edf7; }
.module-profile-account__header { justify-content: flex-start; margin-bottom: 24px; }
.module-profile-account__avatar { width: 54px; height: 54px; flex: 0 0 54px; display: grid; place-items: center; border-radius: 19px; color: #fff; background: linear-gradient(135deg,color-mix(in srgb,var(--app-color) 76%,white),var(--app-color)); box-shadow: 0 12px 26px rgba(var(--app-color-rgb),.2); font-size: 1.45rem; }
.module-profile-separator { height: 1px; margin: 2px 0; background: #f0edf7; }
.module-profile-help { margin-top: 7px; display: flex; align-items: center; gap: 6px; color: #817990; font-size: .78rem; font-weight: 650; }
.module-profile-note { display: inline-flex; align-items: center; gap: 7px; color: #817990; font-size: .8rem; font-weight: 700; }
.module-color-field input[type="color"] { width: 34px; height: 34px; padding: 0; border: 0; border-radius: 10px; background: transparent; cursor: pointer; }
.module-color-field span { color: #655a74; font-size: .84rem; font-weight: 750; }
.module-icon-picker { position: relative; }
.module-icon-picker__control > input { padding-right: 40px; }
.module-icon-picker__control > button { position: absolute; top: 8px; right: 7px; width: 32px; height: 32px; display: grid; place-items: center; border: 0; border-radius: 10px; color: var(--app-color); background: color-mix(in srgb,var(--app-color) 9%,#fff); cursor: pointer; }
.module-icon-picker__panel { position: absolute; top: calc(100% + 7px); left: 0; z-index: 80; width: 100%; min-width: 380px; padding: 12px; border: 1px solid var(--module-border); border-radius: 18px; background: #fff; box-shadow: 0 24px 60px rgba(31,24,45,.18); }
.module-icon-picker__panel[hidden] { display: none; }
.module-icon-picker__status { margin-bottom: 10px; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.module-icon-picker__status span { color: #4d455b; font-size: .75rem; font-weight: 800; }
.module-icon-picker__status small { max-width: 230px; color: #817990; font-size: .65rem; text-align: right; }
.module-icon-picker__results { max-height: 350px; display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 6px; overflow-y: auto; overscroll-behavior: contain; }
.module-icon-picker__option { min-width: 0; min-height: 68px; padding: 7px 4px; display: grid; place-items: center; align-content: center; gap: 5px; border: 1px solid #ece8f1; border-radius: 13px; color: #655a74; background: #fff; cursor: pointer; transition: border-color var(--transition),background var(--transition),color var(--transition),transform var(--transition); }
.module-icon-picker__option:hover { border-color: color-mix(in srgb,var(--app-color) 35%,#ddd); color: var(--app-color); background: color-mix(in srgb,var(--app-color) 6%,#fff); transform: translateY(-1px); }
.module-icon-picker__option.is-selected { border-color: var(--app-color); color: var(--app-color); background: color-mix(in srgb,var(--app-color) 10%,#fff); }
.module-icon-picker__option i { font-size: 1.25rem; }
.module-icon-picker__option small { width: 100%; overflow: hidden; color: inherit; font-size: .52rem; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.module-icon-picker__more { width: 100%; margin-top: 9px; }
.module-switch { display: flex; align-items: center; gap: 10px; width: fit-content; cursor: pointer; }
.module-switch input { position: absolute; opacity: 0; pointer-events: none; }
.module-switch > span { width: 44px; height: 25px; padding: 3px; border-radius: 999px; background: #d9d3df; transition: background var(--transition); }
.module-switch > span::after { content: ''; display: block; width: 19px; height: 19px; border-radius: 50%; background: #fff; box-shadow: 0 3px 8px rgba(32,23,54,.18); transition: transform var(--transition); }
.module-switch input:checked + span { background: var(--app-color); }
.module-switch input:checked + span::after { transform: translateX(19px); }
.module-switch input:focus-visible + span { outline: 3px solid rgba(var(--app-color-rgb),.25); outline-offset: 2px; }
.module-switch strong { color: #4d455b; font-size: .86rem; }
.module-form-switches { display: grid; gap: 14px; }
.module-form-switches .module-switch { width: 100%; display: grid; grid-template-columns: 44px minmax(0,1fr); column-gap: 11px; }
.module-form-switches .module-switch > span { grid-row: 1 / 3; }
.module-form-switches .module-switch small { grid-column: 2; color: #817990; font-size: .73rem; }
.module-recurrence-panel { display: grid; gap: 14px; }
.module-recurrence-panel > [data-recurrence-rules] { display: grid; gap: 14px; }
.module-recurrence-rule { padding: 16px; display: grid; gap: 14px; border: 1px solid var(--module-border); border-radius: 18px; background: #fff; }
.module-recurrence-rule > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.module-recurrence-rule > header strong { color: #3f374c; font-size: .92rem; }
.module-recurrence-all-day { width: 100%; display: grid; grid-template-columns: 44px minmax(0,1fr); column-gap: 11px; }
.module-recurrence-all-day > span { grid-row: 1 / 3; }
.module-recurrence-all-day small { grid-column: 2; color: #817990; font-size: .73rem; }
.module-weekday-picker { display: grid; grid-template-columns: repeat(7,minmax(0,1fr)); gap: 7px; }
.module-weekday-picker label { cursor: pointer; }
.module-weekday-picker input { position: absolute; opacity: 0; pointer-events: none; }
.module-weekday-picker span { min-height: 38px; display: grid; place-items: center; border: 1px solid var(--module-border); border-radius: 11px; color: #756b80; background: #fff; font-size: .72rem; font-weight: 800; transition: border-color var(--transition),color var(--transition),background var(--transition); }
.module-weekday-picker input:checked + span { border-color: var(--app-color); color: var(--app-color); background: color-mix(in srgb,var(--app-color) 10%,#fff); }
.module-weekday-picker input:focus-visible + span { outline: 3px solid rgba(var(--app-color-rgb),.2); outline-offset: 2px; }
.module-add-recurrence { width: 100%; justify-content: center; }
.module-profile-empty { padding: 42px 20px; display: grid; justify-items: center; gap: 10px; text-align: center; }
.module-profile-empty > span { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 20px; color: var(--app-color); background: color-mix(in srgb,var(--app-color) 10%,#fff); font-size: 1.4rem; }
.module-profile-empty p { max-width: 340px; margin: 0; color: #817990; font-size: .86rem; }

@media (max-width: 1120px) { .module-sidebar { display: none; } .module-main { padding: 22px 18px 90px; } }
@media (max-width: 980px) { .module-profile-layout { grid-template-columns: 1fr; } }
@media (max-width: 767px) { .module-modal { display: none !important; } }
@media (max-width: 720px) {
    .module-header { align-items: flex-start; }
    .module-header__actions { display: none; }
    .module-header h1 { font-size: 1.55rem; }
    .module-profile-tabs { width: 100%; overflow-x: auto; }
    .module-profile-tabs a { flex: 1; padding-left: 10px; padding-right: 10px; white-space: nowrap; }
    .module-profile-list, .module-profile-editor, .module-profile-account { padding: 16px; border-radius: 22px; }
    .module-toolbar { align-items: stretch; flex-direction: column; }
    .module-filter-tabs { overflow-x: auto; }
    .module-filter-tabs a { white-space: nowrap; }
    .module-search { min-width: 0; }
}
@media (max-width: 560px) {
    .module-form-page { padding: 0; }
    .module-form-shell { width: 100%; }
    .module-form-card { min-height: 100vh; /*margin-bottom: 100px;*/ border-right: 0; border-left: 0; border-radius: 24px; }
    .module-field-grid { grid-template-columns: 1fr; gap: 0; }
    .module-choice-picker { gap: 6px; padding-right: 10px; padding-left: 10px; }
    .module-choice-icon { width: 52px; height: 52px; }
    .module-choice-picker small { font-size: .66rem; }
    .module-weekday-picker { grid-template-columns: repeat(4,minmax(0,1fr)); }
}
@media (max-width: 520px) {
    .module-profile-field-grid { grid-template-columns: 1fr; }
    .module-profile-actions { align-items: stretch; flex-direction: column-reverse; }
    .module-profile-actions > * { width: 100%; }
    .module-icon-picker__panel { min-width: 0; }
    .module-icon-picker__results { grid-template-columns: repeat(4,minmax(0,1fr)); }
}
@media (max-width: 480px) { .module-period-picker { margin-bottom: 12px; } }
