@font-face{font-family:WeddingArabic;src:url('arabic-regular.ttf') format('truetype');font-weight:400 500;font-display:swap}
@font-face{font-family:WeddingArabic;src:url('arabic-bold.ttf') format('truetype');font-weight:600 900;font-display:swap}
:root{--bg:#f8f6f2;--paper:#fffefa;--ink:#302d32;--muted:#817a80;--line:#e9e3df;--plum:#754b5c;--plum-dark:#593b49;--plum-soft:#f1e8ec;--peach:#f5e7dc;--green:#426b5a;--green-soft:#e9f1eb;--gold:#97753d;--radius:18px;--shadow:0 16px 48px #3525300a;font-family:WeddingArabic,'Noto Sans Arabic',Tahoma,Arial,sans-serif;color:var(--ink);background:var(--bg);font-size:14px;line-height:1.8;color-scheme:light}
*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,a,input,select,textarea{-webkit-tap-highlight-color:transparent}button,a{touch-action:manipulation}button{cursor:pointer}a{color:inherit;text-decoration:none}a:hover{color:var(--plum)}button:disabled{cursor:not-allowed;opacity:.5}h1,h2,h3,h4,p{margin:0}h1{font-size:28px;line-height:1.5;font-weight:750;letter-spacing:-.7px}h2{font-size:19px;line-height:1.6}h3{font-size:16px}small{font-size:12px}svg.icon{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.65;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0;vertical-align:middle}svg.icon.small{width:16px;height:16px}input,select,textarea{max-width:100%;min-width:0}input:not([type=checkbox]):not([type=radio]):not([type=color]),select,textarea{width:100%;border:1px solid #ddd5d8;border-radius:10px;padding:10px 12px;background:#fffefa;color:var(--ink);outline:none;transition:border-color .15s}input:focus,select:focus,textarea:focus{border-color:var(--plum);box-shadow:0 0 0 3px #754b5c14}input[type=checkbox],input[type=radio]{accent-color:var(--plum);width:17px;height:17px;cursor:pointer}input[type=color]{width:100%;height:46px;padding:5px;border:1px solid var(--line);background:var(--paper);border-radius:10px}textarea{min-height:100px;resize:vertical}label.field{display:flex;flex-direction:column;gap:6px;font-weight:600;font-size:13px}label.field small{font-weight:400;color:var(--muted)}fieldset{border:1px solid var(--line);border-radius:12px;padding:12px;min-width:0}legend{font-weight:600;padding:0 6px}.checkbox{display:inline-flex;align-items:center;gap:8px;font-size:13px;padding:5px 0}.muted{color:var(--muted)}.ltr{direction:ltr;unicode-bidi:plaintext;display:inline-block}.number{font-family:Arial,sans-serif;letter-spacing:.4px}.eyebrow{font-size:10px;font-weight:700;letter-spacing:2.3px;text-transform:uppercase;color:var(--muted)}.btn{border:1px solid transparent;display:inline-flex;align-items:center;justify-content:center;gap:8px;border-radius:10px;padding:10px 16px;white-space:nowrap;line-height:1.7;transition:background .15s,transform .15s;background:var(--plum);color:white;font-weight:600;font-size:13px}.btn:hover{background:var(--plum-dark);color:white}.btn:active{transform:translateY(1px)}.btn.secondary{background:var(--paper);color:var(--ink);border-color:var(--line)}.btn.secondary:hover{background:#f4efeb;border-color:#d5c8cb}.btn.ghost{background:transparent;color:var(--plum);border-color:transparent}.btn.ghost:hover{background:var(--plum-soft)}.btn.danger{background:#9f4347;color:#fff}.btn.whatsapp{background:var(--green);color:#fff}.btn.sm{padding:6px 11px;font-size:12px}.icon-btn{border:0;background:transparent;color:var(--muted);display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;border-radius:9px;cursor:pointer}.icon-btn:hover{background:var(--plum-soft);color:var(--plum)}.icon-btn.call{color:var(--plum);background:var(--plum-soft)}.icon-btn.wa{color:var(--green);background:var(--green-soft)}.row{display:flex;align-items:center;gap:12px}.row.wrap{flex-wrap:wrap}.between{justify-content:space-between}.grow{flex:1;min-width:0}.stack{display:flex;flex-direction:column;gap:18px}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:16px}.full{grid-column:1/-1}.panel{background:var(--paper);border:1px solid var(--line);border-radius:var(--radius);box-shadow:var(--shadow)}.panel-head{padding:20px 22px;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;gap:12px}.panel-body{padding:22px}.pill{display:inline-flex;align-items:center;gap:5px;padding:3px 9px;border-radius:6px;font-size:11px;font-weight:600;white-space:nowrap;background:#f2efeb;color:#756e69}.pill.plum{background:var(--plum-soft);color:var(--plum)}.pill.green{background:var(--green-soft);color:var(--green)}.pill.gold{background:#f8efdf;color:#91682f}.pill.red{background:#f7e8e6;color:#a34740}.dot{width:7px;height:7px;border-radius:50%;display:inline-block;background:currentColor}.empty{text-align:center;padding:45px 20px;color:var(--muted)}.empty .empty-icon{width:64px;height:64px;border-radius:21px;background:var(--plum-soft);color:var(--plum);margin:0 auto 16px;display:grid;place-items:center}.empty .icon{width:28px;height:28px}.empty h3{color:var(--ink);margin-bottom:6px}.empty p{max-width:390px;margin:0 auto 18px;font-size:13px}.divider{height:1px;background:var(--line);margin:10px 0}.error-box{padding:13px 16px;background:#faece9;border:1px solid #eecfc9;border-radius:10px;color:#8e3d36;font-size:13px}.note{padding:13px 16px;border:1px solid #e4ddd2;border-radius:10px;background:#f7f3ec;font-size:12px;color:#756958}.loading{padding:80px;text-align:center;color:var(--muted)}.spinner{width:28px;height:28px;border-radius:50%;border:2px solid var(--line);border-top-color:var(--plum);display:inline-block;animation:spin .7s linear infinite}.initial-loading{display:grid;place-content:center;text-align:center;gap:16px;min-height:100vh}.initial-loading img{margin:auto}@keyframes spin{to{transform:rotate(360deg)}}.skip-link{position:fixed;top:-80px;right:20px;z-index:100;padding:10px;background:white;border:2px solid var(--plum)}.skip-link:focus{top:10px}
/* Workspace */
.sidebar{position:fixed;inset:0 0 0 auto;width:242px;background:#f1ede7;border-left:1px solid #e5dfd7;display:flex;flex-direction:column;padding:30px 20px;z-index:20}.brand{display:flex;align-items:center;gap:10px;padding:0 4px 28px}.brand img{width:42px;height:42px}.brand-name{font-family:Georgia,serif;direction:ltr;font-size:19px;line-height:1.1;letter-spacing:-.3px}.brand small{font-size:9px;display:block;color:var(--muted);margin-top:6px;letter-spacing:1px}.nav-label{font-size:10px;color:#91877e;margin:6px 14px 12px}.nav{display:flex;flex-direction:column;gap:6px}.nav a{display:flex;gap:12px;align-items:center;padding:12px 15px;border-radius:11px;color:#7c7471;font-size:13px}.nav a.active{background:var(--paper);color:var(--plum);font-weight:700;box-shadow:0 3px 10px #37272905}.nav a:hover{background:#fff9}.nav .icon{width:19px;height:19px}.sidebar-bottom{margin-top:auto;padding-top:26px}.sidebar-note{padding:17px 14px;border:1px solid #e0d7ce;border-radius:12px;color:#8a786b;background:#f6f0e8;font-size:11px;margin-bottom:18px}.sidebar-note .icon{margin-bottom:8px;color:#a88a70}.account{border-top:1px solid #dfd8d0;padding:18px 3px 0;display:flex;gap:10px;align-items:center}.avatar{width:38px;height:38px;border-radius:12px;background:#e5d9d5;color:var(--plum);display:grid;place-items:center;font-size:15px;font-weight:700;flex-shrink:0}.account-name{font-size:12px;font-weight:700;max-width:115px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.account small{font-size:10px;color:var(--muted)}.main{margin-right:242px;min-height:100vh}.topbar{height:78px;padding:0 38px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line);background:var(--paper);gap:12px}.topbar .row{gap:8px}.topbar-title{font-size:12px;color:var(--muted)}.topbar-title b{font-weight:500;color:var(--ink)}.topbar-date{font-size:11px;color:var(--muted)}.content{max-width:1480px;margin:auto;padding:32px 38px 40px}.page-heading{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:26px}.page-heading p{color:var(--muted);font-size:12px;margin-top:5px}.greeting .eyebrow{margin-bottom:6px}.greeting h1 span{font-weight:400;color:#91827b}.section-space{margin-top:22px}.footer{display:flex;justify-content:space-between;padding-top:32px;color:#a69b95;font-size:10px}.mobile-menu{display:none}
/* Dashboard */
.hero{background:#eee3de;display:flex;align-items:center;justify-content:space-between;overflow:hidden;min-height:170px;border-radius:var(--radius);padding:28px 32px;position:relative;border:1px solid #e9dcd7}.hero-copy{position:relative;z-index:1;max-width:600px}.hero .eyebrow{color:#9c796c;font-size:9px}.hero h2{font-size:24px;color:#623e4b;margin:6px 0}.hero p{font-size:12px;color:#927970;max-width:470px;margin-bottom:15px}.hero .btn{padding:8px 13px;font-size:11px}.hero-art{width:180px;height:150px;flex-shrink:0;opacity:.85;margin-left:10px}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:16px;margin:22px 0}.stat{padding:19px 21px;display:flex;gap:12px;align-items:flex-start;position:relative}.stat-icon{width:39px;height:39px;border-radius:12px;display:grid;place-items:center;flex-shrink:0;background:#eee8f3;color:#8c729d}.stat:nth-child(2) .stat-icon{background:var(--green-soft);color:var(--green)}.stat:nth-child(3) .stat-icon{background:#f9eede;color:#b28c50}.stat:nth-child(4) .stat-icon{background:#f7e7e4;color:#bd7a69}.stat-label{font-size:11px;color:var(--muted);margin-bottom:4px}.stat-number{font-family:Arial,sans-serif;font-size:30px;font-weight:700;line-height:1.3}.stat small{font-size:9px;color:#a69b92;display:block;margin-top:6px}.dashboard-grid{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(260px,1fr);gap:22px}.progress-content{text-align:center;padding:24px 20px}.progress-ring{width:150px;height:150px;border-radius:50%;margin:0 auto 14px;background:conic-gradient(var(--plum) var(--progress),#f0e9e5 0);padding:10px;position:relative;transform:rotate(-90deg)}.progress-ring:after{content:'';position:absolute;inset:9px;background:var(--paper);border-radius:50%}.progress-number{position:absolute;inset:0;z-index:1;display:flex;flex-direction:column;align-items:center;justify-content:center;transform:rotate(90deg);line-height:1.7}.progress-number strong{font-family:Georgia,serif;font-size:31px;font-weight:400}.progress-number small{font-size:10px;color:var(--muted)}.progress-label{font-size:12px;color:#80726c}.progress-legend{display:flex;justify-content:center;gap:20px;margin-top:17px;font-size:10px}.task-row{padding:16px 22px;display:flex;gap:12px;align-items:center;border-bottom:1px solid #f0ebe7}.task-row:last-child{border-bottom:0}.task-row .avatar{width:35px;height:35px;background:#f3e8e1;color:#9a7a6b;font-size:12px;border-radius:50%}.task-row h4{font-size:12px}.task-row p{font-size:10px;color:var(--muted)}.task-row time{font-size:10px;color:#967765}.task-row .task-note{max-width:300px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.groups-mini{padding:18px 22px;display:flex;flex-direction:column;gap:15px}.group-mini-row{display:flex;justify-content:space-between;align-items:center;font-size:12px}.group-mini-row .row{gap:9px}.mini-bar{background:#f0eae5;border-radius:5px;height:4px;margin-top:7px;overflow:hidden}.mini-bar span{display:block;height:100%;background:var(--plum);border-radius:5px}.activity-row{display:flex;align-items:flex-start;gap:12px;padding:15px 0;border-bottom:1px solid var(--line)}.activity-row:last-child{border:0}.activity-icon{width:30px;height:30px;display:grid;place-items:center;background:var(--green-soft);color:var(--green);border-radius:50%;flex-shrink:0}.activity-row h4{font-size:12px;font-weight:600}.activity-row p{font-size:11px;color:var(--muted)}.activity-row time{font-size:10px;color:#a2958a}
/* Lists and forms */
.filters{display:grid;grid-template-columns:minmax(160px,1.6fr) repeat(4,minmax(90px,1fr)) auto;gap:10px;padding:18px 20px;border-bottom:1px solid var(--line)}.filters input,.filters select{font-size:12px;padding:9px 10px!important}.search{position:relative}.search .icon{position:absolute;right:11px;top:12px;width:17px;height:17px;color:var(--muted)}.search input{padding-right:36px!important}.toolbar{padding:12px 20px;display:flex;align-items:center;justify-content:space-between;gap:10px;font-size:11px;color:var(--muted)}.bulk{padding:14px 20px;background:var(--plum-soft);display:flex;align-items:center;gap:10px;flex-wrap:wrap;font-size:12px}.bulk select{width:auto;min-width:110px;font-size:11px}.table-scroll{overflow:auto}table{width:100%;border-collapse:collapse;text-align:right}th{font-weight:500;color:#9c9087;font-size:10px;background:#fcfaf6;padding:12px 15px;white-space:nowrap;border-block:1px solid var(--line)}td{padding:16px 15px;border-bottom:1px solid #eee8e2;font-size:12px;vertical-align:middle}tbody tr:last-child td{border-bottom:0}tbody tr:hover{background:#faf7f2}.person-cell{display:flex;align-items:center;gap:11px;min-width:150px}.person-cell .avatar{width:35px;height:35px;border-radius:11px;font-size:12px;background:#f1e5e7}.person-cell button{background:none;border:0;padding:0;font-weight:600;cursor:pointer;text-align:right}.person-cell small{display:block;font-size:10px;color:var(--muted);max-width:180px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.phone-label{font-size:11px;color:#8e857f;direction:ltr;unicode-bidi:plaintext;font-family:Arial,sans-serif}.chips{display:flex;gap:5px;flex-wrap:wrap}.pagination{display:flex;align-items:center;justify-content:space-between;padding:16px 20px;border-top:1px solid var(--line);font-size:11px;color:var(--muted)}.groups-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.group-card{padding:24px;position:relative}.group-card .group-icon{width:45px;height:45px;border-radius:14px;display:grid;place-items:center;margin-bottom:16px;background:var(--plum-soft);color:var(--plum)}.group-card h3{margin-bottom:4px}.group-card .group-count{color:var(--muted);font-size:12px}.group-card .card-menu{position:absolute;left:13px;top:15px}.group-card .card-bottom{display:flex;align-items:center;justify-content:space-between;border-top:1px solid var(--line);padding-top:15px;margin-top:18px}.groups-add{border:1px dashed #cdbec2;background:transparent;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:12px;color:var(--plum);min-height:220px;border-radius:18px}.dropzone{padding:40px 20px;border:1.5px dashed #cdbfc4;border-radius:14px;background:#faf6f6;text-align:center;cursor:pointer;position:relative}.dropzone .icon{width:36px;height:36px;color:var(--plum);margin-bottom:12px}.dropzone h3{font-size:15px;margin-bottom:4px}.dropzone p{font-size:11px;color:var(--muted)}.dropzone input{margin-top:18px;font-size:12px}.import-steps{display:flex;gap:12px;margin-bottom:22px;flex-wrap:wrap}.import-step{display:flex;align-items:center;gap:7px;color:#b4a59c;font-size:11px}.import-step span{width:23px;height:23px;display:grid;place-items:center;border-radius:50%;background:#ede6e2}.import-step.active{color:var(--plum)}.import-step.active span{background:var(--plum);color:white}.import-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(220px,1fr);gap:22px}.import-help{padding:24px}.import-help ul{padding-right:18px;color:var(--muted);font-size:12px;line-height:2.3}.import-help h3{margin-bottom:12px}.history-item{padding:15px 0;border-bottom:1px solid var(--line);display:flex;align-items:center;gap:10px}.history-item:last-child{border:0}.history-item strong{font-size:12px;display:block;max-width:170px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.history-item small{font-size:10px;color:var(--muted)}.import-results{display:flex;gap:9px;flex-wrap:wrap}.import-results .pill{font-size:12px;padding:6px 10px}.review-table td{vertical-align:top;min-width:120px}.review-table .decision{min-width:220px}.review-table small{font-size:10px;display:block;color:var(--muted);max-width:270px}.review-table select{font-size:11px}.mapping-checks{display:flex;flex-wrap:wrap;gap:12px}.mapping-sample{max-width:100%;overflow:auto}.mapping-sample table{font-size:11px}.settings-grid{display:grid;grid-template-columns:1.4fr 1fr;gap:22px}.template-card{padding:23px;display:flex;flex-direction:column;gap:15px}.template-card .template-body{white-space:pre-wrap;color:#8a7c75;font-size:12px;background:#faf7f1;border-radius:10px;padding:16px;flex:1;line-height:2}.template-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}.danger-panel{border-color:#e8cecb}.danger-panel h3{color:#9f4347}.section-label{font-size:12px;color:var(--muted);margin:10px 0}.form-actions{display:flex;justify-content:flex-start;gap:10px;border-top:1px solid var(--line);padding-top:18px;margin-top:8px}.phone-editor{background:#faf7f2;padding:12px;border-radius:12px;display:grid;grid-template-columns:1fr auto;gap:7px;margin-bottom:10px}.phone-editor .phone-options{grid-column:1/-1;display:flex;gap:14px;flex-wrap:wrap}.phone-editor .checkbox{font-size:11px}.phone-editor input[type=tel]{direction:ltr;text-align:left}.person-detail-head{display:flex;gap:15px;align-items:center}.person-detail-head .avatar{width:60px;height:60px;font-size:25px;border-radius:20px}.person-detail-head p{font-size:12px;color:var(--muted)}.person-section{padding:18px 0;border-top:1px solid var(--line)}.person-section h3{font-size:13px;margin-bottom:12px}.phone-detail{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:9px 0}.detail-notes{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;color:#81716c}.timeline{max-height:290px;overflow:auto}.template-preview{white-space:pre-wrap;border-radius:12px;padding:18px;background:#eaf2eb;color:#3f6150;font-size:13px;line-height:2;min-height:140px}.backup-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;text-align:center}.backup-summary div{background:var(--bg);padding:12px;border-radius:10px}.backup-summary strong{display:block;font-size:22px}.backup-summary small{color:var(--muted)}
/* Dialog, feedback, login */
dialog{border:0;border-radius:20px;padding:0;width:min(680px,calc(100% - 32px));max-height:90dvh;background:var(--paper);color:var(--ink);box-shadow:0 30px 100px #30212f40;overflow:auto}dialog::backdrop{background:#2d263b65;backdrop-filter:blur(4px)}.modal-header{position:sticky;top:0;z-index:2;background:var(--paper);border-bottom:1px solid var(--line);padding:18px 24px;display:flex;align-items:center;justify-content:space-between}.modal-header h2{font-size:17px}.modal-body{padding:24px}.modal-body .grid2{gap:15px}.modal-body form{display:flex;flex-direction:column;gap:16px}.modal-body .inline-form{display:block}.modal-body .inline-form input{margin-bottom:10px}#toast{position:fixed;bottom:24px;left:50%;transform:translate(-50%,20px);background:#322b30;color:white;z-index:1000;padding:13px 22px;border-radius:12px;box-shadow:0 10px 40px #0002;opacity:0;pointer-events:none;transition:.2s;max-width:calc(100% - 32px);font-size:13px}#toast.show{opacity:1;transform:translate(-50%,0)}#toast.error{background:#8a3e3e}:focus-visible{outline:2px solid var(--plum);outline-offset:3px}.login{min-height:100vh;display:grid;grid-template-columns:1.1fr 1fr}.login-welcome{position:relative;background:#ede2dd;display:flex;flex-direction:column;justify-content:center;padding:64px 11%;overflow:hidden}.login-welcome:before{content:'';width:700px;height:700px;border:1px solid #dbcbc3;border-radius:50%;position:absolute;top:-230px;left:-340px}.login-welcome:after{content:'';width:560px;height:560px;border:1px solid #dbcbc3;border-radius:50%;position:absolute;bottom:-280px;right:-300px}.login-welcome .brand{padding-bottom:48px;position:relative;z-index:1}.login-welcome .brand img{width:50px;height:50px}.login-welcome h1{font-size:43px;color:#65434f;line-height:1.65;position:relative}.login-welcome h1 span{font-weight:400;color:#a07877}.login-welcome>p{color:#987e72;font-size:13px;margin-top:16px;max-width:360px;line-height:2.2}.login-art{width:260px;height:200px;margin:40px auto 12px;position:relative}.login-features{display:flex;gap:25px;margin-top:25px;position:relative;z-index:1}.login-features span{font-size:10px;color:#927a6f;display:flex;align-items:center;gap:6px}.login-features .icon{width:16px;height:16px}.login-form-wrap{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:50px 40px;background:var(--paper)}.login-card{width:100%;max-width:360px}.login-card .eyebrow{font-size:10px;color:#b29185}.login-card h2{font-size:27px;margin-top:8px;margin-bottom:8px}.login-card>p{font-size:12px;color:var(--muted);margin-bottom:30px}.login-card form{display:flex;flex-direction:column;gap:16px}.login-card .btn{padding:13px}.login-card label{font-size:12px}.login-note{margin-top:24px;border-top:1px solid var(--line);padding-top:20px;color:#9c8b81;font-size:11px;line-height:2}.login-note strong{font-weight:500;color:#7b685c}.login-footer{margin-top:45px;font-size:10px;color:#b4a59d}.login-card .lock-icon{width:50px;height:50px;display:grid;place-items:center;background:#f4ece9;border-radius:16px;margin-bottom:22px;color:var(--plum)}.checklist{padding-right:20px;font-size:12px;color:var(--muted);line-height:2.2}.print-only{display:none}
@media(min-width:1600px){.content{padding-top:42px}.hero{min-height:195px}.stat{padding:25px}}
@media(max-width:1200px){.sidebar{width:210px;padding-inline:15px}.main{margin-right:210px}.content{padding:26px}.topbar{padding-inline:26px}.filters{grid-template-columns:1.5fr 1fr 1fr}.stats{gap:10px}.stat{padding:17px 13px;gap:8px}.stat-icon{width:33px;height:33px}.stat-number{font-size:27px}.stat-label{font-size:10px}.groups-grid,.template-grid{grid-template-columns:repeat(2,1fr)}.hero-art{width:140px}.hero h2{font-size:21px}}
@media(max-width:900px){.sidebar{width:190px;padding-inline:12px}.main{margin-right:190px}.brand-name{font-size:16px}.brand img{width:35px;height:35px}.dashboard-grid,.settings-grid,.import-layout{grid-template-columns:1fr}.dashboard-grid>.stack{display:grid;grid-template-columns:1fr 1fr}.hero-art{display:none}.stats{grid-template-columns:repeat(2,1fr)}.page-heading{align-items:flex-start}.page-heading .row{flex-wrap:wrap;justify-content:flex-end}.hero{padding:24px}.topbar-date{font-size:10px}.groups-grid,.template-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:650px){.sidebar{transform:translateX(100%);transition:transform .2s;width:245px;box-shadow:-20px 0 70px #35253025}.sidebar.open{transform:translateX(0)}.main{margin-right:0}.content{padding:22px 16px}.topbar{height:62px;padding:0 16px}.mobile-menu{display:inline-flex}.topbar-date{display:none}.page-heading{gap:12px;margin-bottom:20px;flex-wrap:wrap}.page-heading h1{font-size:24px}.page-heading .row{justify-content:flex-start;gap:7px}.page-heading .btn{font-size:11px;padding:9px 11px}.hero{padding:22px}.hero h2{font-size:20px}.hero p{font-size:11px}.stats{gap:10px;margin-block:16px}.stat{padding:17px 13px;min-height:113px}.stat-number{font-size:27px}.stat small{font-size:9px}.dashboard-grid{gap:16px}.dashboard-grid>.stack{display:flex}.panel-head{padding:16px}.panel-head h2{font-size:16px}.panel-body{padding:17px}.task-row{padding:15px 16px}.task-row .task-note{max-width:180px}.filters{grid-template-columns:1fr 1fr;padding:14px;gap:8px}.filters .search{grid-column:1/-1}.filters .btn{grid-column:1/-1}.toolbar{padding:10px 14px}.groups-grid,.template-grid{grid-template-columns:1fr}.grid2{grid-template-columns:1fr}.group-card{padding:20px}.groups-add{min-height:120px}.row.wrap{gap:8px}.footer{font-size:9px;gap:10px}.modal-body{padding:18px}.modal-header{padding:16px 18px}.phone-editor .phone-options{gap:9px}.login{grid-template-columns:1fr}.login-welcome{padding:28px 26px;min-height:270px}.login-welcome .brand{padding-bottom:25px}.login-welcome h1{font-size:29px}.login-welcome>p{font-size:12px;max-width:320px;margin-top:8px}.login-art,.login-features{display:none}.login-form-wrap{padding:32px 26px}.login-card h2{font-size:23px}.login-card .lock-icon{display:none}.login-footer{margin-top:25px}.login-note{font-size:10px}.backup-summary{grid-template-columns:repeat(2,1fr)}.import-step{font-size:10px}.import-steps{gap:9px}.review-table .decision{min-width:205px}}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
@media print{.sidebar,.topbar,.btn,.icon-btn,.filters,.bulk,.footer{display:none!important}.main{margin:0}.content{padding:0}.panel{box-shadow:none;border-color:#ccc}.table-scroll{overflow:visible}body{background:white}.print-only{display:block}}

/* Swipe sorting */
.sort-board{max-width:780px;margin:auto}
.sort-filter-toggle{display:none}
.sort-filters{display:grid;grid-template-columns:1fr 1fr auto;align-items:end;gap:12px;padding:16px 20px;margin-bottom:12px}
.sort-filters label{font-size:11px}.sort-filters input,.sort-filters select{font-size:12px}
.sort-workspace{padding:8px 26px 18px;overflow:hidden}
.sort-status{display:flex;justify-content:space-between;gap:12px;font-size:11px;color:var(--muted);margin-bottom:14px;flex-wrap:wrap}
.sort-status span:first-child{color:var(--plum)}.sort-error{margin-block:12px}
.sort-stage{max-width:500px;height:450px;margin:10px auto 0;position:relative;isolation:isolate}
.sort-card-shadow{position:absolute;inset:10px 12px -7px;border:1px solid #e2d6d1;border-radius:27px;background:#f1e6e0;pointer-events:none}
.sort-card-shadow.shadow-two{transform:rotate(-4deg) translateY(5px);inset-inline:20px;background:#eee2dd;z-index:-2}
.sort-card-shadow.shadow-one{transform:rotate(2.5deg);z-index:-1;background:#f8f0e9}
.sort-card{position:absolute;inset:0;padding:22px 26px;background:linear-gradient(155deg,#fbf1ee,#fffdf9 65%);border:1px solid #e1cfcf;border-radius:25px;box-shadow:0 15px 30px #643d5010;display:flex;align-items:center;flex-direction:column;gap:8px;text-align:center;touch-action:pan-y;user-select:none;cursor:grab;overflow:hidden;transition:transform .2s ease}
.sort-card.is-dragging{cursor:grabbing;transition:none}
.sort-card.sage{background:linear-gradient(155deg,#edf3eb,#fffdf9 65%);border-color:#d4dfd2}
.sort-card.sand{background:linear-gradient(155deg,#f8efdd,#fffdf9 65%);border-color:#e4d7bc}
.sort-card.lilac{background:linear-gradient(155deg,#f0ecf6,#fffdf9 65%);border-color:#dcd2e6}
.sort-card.is-deleted{opacity:.7}.sort-card:focus-visible{outline-offset:4px}
.sort-card-top{display:flex;align-items:center;justify-content:space-between;width:100%;gap:8px;min-height:26px}
.sort-card-overline{font-size:10px;color:#a68b85}.sort-card-top .pill{font-size:10px;background:#fff9}
.sort-portrait{width:92px;height:92px;border-radius:30px;margin:8px 0 5px;display:grid;place-items:center;background:#ead9d9;color:var(--plum);font-size:39px;position:relative;flex-shrink:0;box-shadow:inset 0 0 0 6px #ffffff45}
.sage .sort-portrait{background:#dae7d8;color:#54705b}.sand .sort-portrait{background:#eee0bf;color:#95743f}.lilac .sort-portrait{background:#e3dbee;color:#80688d}
.sort-portrait i{display:grid;place-items:center;position:absolute;bottom:-7px;left:-7px;background:var(--paper);border:1px solid var(--line);width:32px;height:32px;border-radius:50%}
.sort-portrait i .icon{width:16px;height:16px}
.sort-person-name{font-size:27px;line-height:1.55;max-width:100%;overflow-wrap:anywhere;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;flex-shrink:0}
.sort-phone{font-size:12px;color:#92817b;min-height:22px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex-shrink:0}
.sort-card-tags{display:flex;flex-wrap:wrap;justify-content:center;gap:5px;max-height:55px;overflow:hidden;flex-shrink:0}
.sort-person-note{font-size:12px;color:#9a8981;max-width:90%;line-height:1.9;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.sort-card-bottom{display:flex;justify-content:space-between;align-items:center;width:100%;font-size:11px;gap:10px;margin-top:auto;border-top:1px solid #e4d9d477;padding-top:9px;flex-shrink:0}
.sort-swipe-label{position:absolute;top:42px;right:26px;color:var(--plum);background:#fffefbe8;border:2px solid currentColor;border-radius:8px;transform:rotate(8deg);padding:5px 13px;font-size:20px;font-weight:700;opacity:0;z-index:2;pointer-events:none}
.sort-navigation{max-width:500px;margin:24px auto 18px;display:flex;align-items:center;justify-content:space-between;gap:10px}
.sort-navigation p{font-size:11px;color:var(--plum);text-align:center;line-height:1.8}.sort-navigation small{font-size:9px;color:var(--muted)}
.sort-navigation .btn{padding:8px 13px;font-size:12px}.sort-arrow-right{transform:rotate(180deg)}
.sort-choices{border-top:1px solid var(--line);padding-top:18px;max-width:590px;margin:auto}
.sort-choices h3{font-size:15px}.sort-choices p{font-size:11px;color:var(--muted);margin-top:3px}
.sort-group-buttons{display:flex;flex-wrap:wrap;gap:9px;margin:15px 0 11px}
.sort-group-choice{display:flex;align-items:center;justify-content:center;gap:8px;flex:1 1 140px;min-width:0;max-width:100%;border:1px solid #e1d6d2;background:var(--paper);padding:12px 15px;border-radius:12px;color:var(--ink);font-size:13px;line-height:1.7;transition:transform .15s,border-color .15s,background .15s;overflow-wrap:anywhere}
.sort-group-choice:hover:not(:disabled){border-color:var(--group-color);background:#f7f0ec;transform:translateY(-2px)}
.sort-group-choice:active:not(:disabled){transform:scale(.97)}
.sort-group-choice.is-member{background:var(--green-soft);border-color:#d4dfd3;color:var(--green);opacity:.75}
.sort-group-dot{display:block;width:9px;height:9px;border-radius:50%;background:var(--group-color);flex-shrink:0}
.sort-group-choice .icon{margin-right:auto;width:15px;height:15px;color:var(--group-color)}
.sort-membership-note{font-size:10px;color:#a29189;display:block}
.sort-bottom-actions{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:15px;max-width:590px;margin:22px auto 4px}
.sort-delete{display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:12px 22px;border:1px solid #e9c7c4;border-radius:13px;color:#a35352;background:#fcf1ee;font-size:13px;font-weight:600;min-width:145px}
.sort-delete:hover:not(:disabled){background:#f7dfd9;border-color:#cc938d}.sort-delete-hint{font-size:10px;color:var(--muted);text-align:center}
.sort-finished{max-width:500px;min-height:350px;margin:15px auto;padding:45px 24px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center}
.sort-finished-icon{display:grid;place-items:center;width:70px;height:70px;border-radius:24px;background:var(--plum-soft);color:var(--plum);margin-bottom:20px}
.sort-finished-icon .icon{width:30px;height:30px}.sort-finished p{max-width:340px;font-size:12px;color:var(--muted);margin:10px 0 20px}.sort-finished .row{justify-content:center}
@media(max-width:650px){
 .sort-page-heading{flex-wrap:nowrap;align-items:flex-start;gap:10px;margin-bottom:14px}.sort-page-heading h1{font-size:20px}.sort-page-heading p{display:none}.sort-page-heading .row{flex-shrink:0}.sort-page-heading .btn{font-size:9px;padding:8px}
 .sort-filter-toggle{display:flex;width:100%;align-items:center;gap:10px;padding:11px 14px;border:1px solid var(--line);border-radius:12px;background:var(--paper);color:var(--plum);font-size:12px;text-align:right;margin-bottom:10px}.sort-filter-toggle span{flex:1}.sort-filter-toggle small{font-size:10px;color:var(--muted)}
 .sort-filter-shell .sort-filters{display:none}.sort-filter-shell.filters-open .sort-filters{display:grid}
 .sort-filters{grid-template-columns:1fr auto;padding:13px;gap:9px}.sort-filters label:first-child{grid-column:1/-1}.sort-filters input,.sort-filters select{padding:8px 10px!important}
 .sort-workspace{padding:5px 6px 12px}.sort-status{font-size:9px;gap:5px;margin-bottom:9px}.sort-stage{height:335px;margin-inline:9px}
 .sort-card{padding:13px 18px;gap:5px;border-radius:23px}.sort-card-shadow{border-radius:23px}
 .sort-portrait{width:56px;height:56px;min-height:42px;font-size:27px;border-radius:20px;margin:4px 0;flex-shrink:1}.sort-portrait i{width:23px;height:23px}.sort-portrait i .icon{width:12px;height:12px}
 .sort-person-name{font-size:22px;line-height:1.5;flex-shrink:1;min-height:33px}.sort-person-note{font-size:10px;-webkit-line-clamp:1}.sort-card-tags{max-height:26px}.sort-card-top{min-height:20px}.sort-card-overline{font-size:9px}.sort-card-bottom{padding-top:5px}.sort-card-bottom .btn{font-size:10px;padding:5px 7px}
 .sort-navigation{margin-top:23px;gap:7px}.sort-navigation .btn{padding:9px 10px;font-size:11px}.sort-navigation .icon{width:15px;height:15px}.sort-navigation p{font-size:10px}.sort-navigation small{font-size:8px}
 .sort-choices{padding-top:15px}.sort-choices .row{gap:7px}.sort-choices h3{font-size:14px}.sort-group-buttons{gap:8px}.sort-group-choice{flex-basis:120px;padding:12px 10px;font-size:12px}
 .sort-membership-note{font-size:9px}.sort-bottom-actions{gap:9px;margin-top:18px}.sort-bottom-actions .btn{font-size:11px;padding:11px 9px}.sort-delete{font-size:12px;padding:11px 15px;min-width:125px}.sort-finished{min-height:320px}
}
