/* ============================================================
   霸州阳光郡物业 · 全站样式
   9 套主题（data-theme）：hongyun / mudan / fenghua / qinghua /
   xingkong / sunac / keji / aurora / dark —— 底纹全部由内联 SVG 矢量
   代码生成（祥云/牡丹/缠枝/青花/星空），不依赖任何位图素材
   ============================================================ */

:root {
    --radius: 14px;
    --shadow: 0 8px 24px rgba(15, 23, 42, .08);
    --font: "Microsoft YaHei", "PingFang SC", system-ui, -apple-system, sans-serif;
}

/* ---------- 主题变量 ---------- */
[data-theme="hongyun"] {
    --bg: linear-gradient(160deg, #a50f15 0%, #c0161d 55%, #a51218 100%);
    --bg-img: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27260%27%20height%3D%27260%27%3E%3Cg%20fill%3D%27none%27%20stroke%3D%27%2523e8b95a%27%20stroke-width%3D%272%27%20stroke-linecap%3D%27round%27%20opacity%3D%27.55%27%3E%3Cpath%20d%3D%27M30%2060q12-26%2042-21t22%2028q-5%2016-23%2012t-10-15q3-10%2013-8%27%2F%3E%3Cpath%20d%3D%27M150%20160q12-26%2042-21t22%2028q-5%2016-23%2012t-10-15q3-10%2013-8%27%2F%3E%3Cpath%20d%3D%27M186%2036q10-22%2032-17t14%2023q-4%2012-18%209%27%2F%3E%3Cpath%20d%3D%27M54%20200q10-22%2032-17t14%2023q-4%2012-18%209%27%2F%3E%3C%2Fg%3E%3Cg%20fill%3D%27%2523e8b95a%27%20opacity%3D%27.5%27%3E%3Cg%20transform%3D%27translate%28120%2C120%29%27%3E%3Ccircle%20r%3D%273%27%2F%3E%3Ccircle%20cy%3D%27-8%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%277.6%27%20cy%3D%27-2.5%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%274.7%27%20cy%3D%276.5%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%27-4.7%27%20cy%3D%276.5%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%27-7.6%27%20cy%3D%27-2.5%27%20r%3D%274%27%2F%3E%3C%2Fg%3E%3Cg%20transform%3D%27translate%28232%2C214%29%20scale%28.8%29%27%3E%3Ccircle%20r%3D%273%27%2F%3E%3Ccircle%20cy%3D%27-8%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%277.6%27%20cy%3D%27-2.5%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%274.7%27%20cy%3D%276.5%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%27-4.7%27%20cy%3D%276.5%27%20r%3D%274%27%2F%3E%3Ccircle%20cx%3D%27-7.6%27%20cy%3D%27-2.5%27%20r%3D%274%27%2F%3E%3C%2Fg%3E%3C%2Fg%3E%3C%2Fsvg%3E");
    --bg-blend: multiply; --bg-opacity:.32;
    --panel: #fffdf8; --panel-2: #fff6e8;
    --text: #3d2015; --muted: #8c6a52;
    --line: #f0dfc4;
    --primary: #b01318; --primary-2: #d0392b;
    --accent: #e0a83f;
    --side: linear-gradient(180deg, #7c0a0f 0%, #a50f15 100%);
    --side-text: #f8e7c8; --side-on: #ffd977;
    --top: linear-gradient(90deg, #fffdf8, #fdf2e2);
    --hero-ov: radial-gradient(circle at 88% 8%, rgba(240,200,110,.30) 0 120px, transparent 300px),
               radial-gradient(circle at 90% 92%, rgba(232,185,90,.16) 0 90px, transparent 240px),
               linear-gradient(135deg, #b01318 0%, #7e0b10 100%);
}
[data-theme="mudan"] {
    --bg: linear-gradient(160deg, #f2b13e 0%, #eec04f 45%, #e8a83a 100%);
    --bg-img: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27220%27%20height%3D%27220%27%3E%3Cg%20fill%3D%27none%27%20stroke%3D%27%2523b3271e%27%20stroke-width%3D%272%27%20opacity%3D%27.42%27%3E%3Ccircle%20cx%3D%2758%27%20cy%3D%2758%27%20r%3D%2715%27%2F%3E%3Ccircle%20cx%3D%2758%27%20cy%3D%2758%27%20r%3D%2725%27%20stroke-dasharray%3D%277%205%27%2F%3E%3Ccircle%20cx%3D%2758%27%20cy%3D%2758%27%20r%3D%2735%27%20opacity%3D%27.45%27%2F%3E%3Ccircle%20cx%3D%27172%27%20cy%3D%27176%27%20r%3D%2711%27%2F%3E%3Ccircle%20cx%3D%27172%27%20cy%3D%27176%27%20r%3D%2719%27%20stroke-dasharray%3D%276%204%27%2F%3E%3Cpath%20d%3D%27M118%2038q10-20%2032-16t16%2022q-4%2013-18%2010%27%2F%3E%3Cpath%20d%3D%27M28%20152q10-20%2032-16t16%2022q-4%2013-18%2010%27%2F%3E%3C%2Fg%3E%3Cg%20fill%3D%27%2523b3271e%27%20opacity%3D%27.38%27%3E%3Cg%20transform%3D%27translate%28150%2C108%29%27%3E%3Ccircle%20r%3D%272.5%27%2F%3E%3Ccircle%20cy%3D%27-7%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%276.7%27%20cy%3D%27-2.2%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%274.1%27%20cy%3D%275.7%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%27-4.1%27%20cy%3D%275.7%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%27-6.7%27%20cy%3D%27-2.2%27%20r%3D%273.5%27%2F%3E%3C%2Fg%3E%3Cg%20transform%3D%27translate%2812%2C210%29%20scale%28.8%29%27%3E%3Ccircle%20r%3D%272.5%27%2F%3E%3Ccircle%20cy%3D%27-7%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%276.7%27%20cy%3D%27-2.2%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%274.1%27%20cy%3D%275.7%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%27-4.1%27%20cy%3D%275.7%27%20r%3D%273.5%27%2F%3E%3Ccircle%20cx%3D%27-6.7%27%20cy%3D%27-2.2%27%20r%3D%273.5%27%2F%3E%3C%2Fg%3E%3C%2Fg%3E%3C%2Fsvg%3E");
    --bg-blend: multiply; --bg-opacity:.22;
    --panel: #fffdf6; --panel-2: #fdf4e0;
    --text: #4a2c12; --muted: #a3763f;
    --line: #f0e2c2;
    --primary: #b3271e; --primary-2: #d84a30;
    --accent: #d43831;
    --side: linear-gradient(180deg, #8a1410 0%, #b3271e 100%);
    --side-text: #ffe9c4; --side-on: #ffd977;
    --top: linear-gradient(90deg, #fffdf6, #fdf3dd);
    --hero-ov: radial-gradient(circle at 86% 10%, rgba(255,214,120,.34) 0 130px, transparent 320px),
               radial-gradient(circle at 8% 94%, rgba(120,16,10,.5) 0 200px, transparent 420px),
               linear-gradient(135deg, #c22a1e 0%, #971712 100%);
}
[data-theme="fenghua"] {
    --bg: linear-gradient(160deg, #fbf7f0 0%, #f7f0e6 55%, #f3ebde 100%);
    --bg-img: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27240%27%20height%3D%27120%27%3E%3Cg%20fill%3D%27none%27%20stroke%3D%27%2523cf3a2e%27%20stroke-width%3D%271.6%27%20opacity%3D%27.3%27%3E%3Cpath%20d%3D%27M-30%2032a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200%27%2F%3E%3Cpath%20d%3D%27M0%2092a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200a30%2030%200%200%201%2060%200%27%2F%3E%3C%2Fg%3E%3Cg%20fill%3D%27%2523cf3a2e%27%20opacity%3D%27.22%27%3E%3Ccircle%20cx%3D%2760%27%20cy%3D%2724%27%20r%3D%272.5%27%2F%3E%3Ccircle%20cx%3D%27180%27%20cy%3D%2724%27%20r%3D%272.5%27%2F%3E%3Ccircle%20cx%3D%27120%27%20cy%3D%2784%27%20r%3D%272.5%27%2F%3E%3Ccircle%20cx%3D%27240%27%20cy%3D%2784%27%20r%3D%272.5%27%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
    --bg-blend: normal; --bg-opacity:.55;
    --panel: #ffffff; --panel-2: #fdf5ef;
    --text: #46201c; --muted: #9a6a5c;
    --line: #f0dcd0;
    --primary: #c8202a; --primary-2: #e0564a;
    --accent: #d8903c;
    --side: linear-gradient(180deg, #9c1218 0%, #c8202a 100%);
    --side-text: #ffe9d8; --side-on: #ffd977;
    --top: linear-gradient(90deg, #ffffff, #fdf6ef);
    --hero-ov: radial-gradient(circle at 85% 12%, rgba(255,214,120,.32) 0 130px, transparent 320px),
               radial-gradient(circle at 10% 92%, rgba(216,144,60,.35) 0 150px, transparent 340px),
               linear-gradient(135deg, #c8202a 0%, #94121a 100%);
}
[data-theme="qinghua"] {
    --bg: linear-gradient(160deg, #0c2f9e 0%, #1e50c8 55%, #3a7bd5 100%);
    --bg-img: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20width%3D%27260%27%20height%3D%27260%27%3E%3Cg%20fill%3D%27%2523dceaff%27%20opacity%3D%27.8%27%3E%3Ccircle%20cx%3D%2730%27%20cy%3D%2740%27%20r%3D%271.8%27%2F%3E%3Ccircle%20cx%3D%2796%27%20cy%3D%27120%27%20r%3D%271.4%27%2F%3E%3Ccircle%20cx%3D%27150%27%20cy%3D%2730%27%20r%3D%272.2%27%2F%3E%3Ccircle%20cx%3D%27212%27%20cy%3D%2788%27%20r%3D%271.4%27%2F%3E%3Ccircle%20cx%3D%2760%27%20cy%3D%27204%27%20r%3D%271.8%27%2F%3E%3Ccircle%20cx%3D%27180%27%20cy%3D%27196%27%20r%3D%272.2%27%2F%3E%3Ccircle%20cx%3D%27242%27%20cy%3D%27160%27%20r%3D%271.4%27%2F%3E%3Ccircle%20cx%3D%27120%27%20cy%3D%27244%27%20r%3D%271.4%27%2F%3E%3Ccircle%20cx%3D%2712%27%20cy%3D%27130%27%20r%3D%271.4%27%2F%3E%3C%2Fg%3E%3Cg%20fill%3D%27%2523ffffff%27%3E%3Cpath%20d%3D%27M150%2020l2.6%207%207%202.6-7%202.6-2.6%207-2.6-7-7-2.6%207-2.6Z%27%2F%3E%3Cpath%20d%3D%27M50%20190l2.2%206%206%202.2-6%202.2-2.2%206-2.2-6-6-2.2%206-2.2Z%27%2F%3E%3Cpath%20d%3D%27M224%20140l1.8%204.6%204.6%201.8-4.6%201.8-1.8%204.6-1.8-4.6-4.6-1.8%204.6-1.8Z%27%2F%3E%3C%2Fg%3E%3Cg%20fill%3D%27none%27%20stroke%3D%27%2523a9c9ff%27%20stroke-width%3D%271.6%27%20opacity%3D%27.5%27%3E%3Ccircle%20cx%3D%27196%27%20cy%3D%27182%27%20r%3D%2712%27%2F%3E%3Ccircle%20cx%3D%27196%27%20cy%3D%27182%27%20r%3D%2721%27%20opacity%3D%27.6%27%2F%3E%3Cpath%20d%3D%27M18%20212q30-42%2072-30%27%2F%3E%3Cpath%20d%3D%27M212%2056q-18%2026-46%2030%27%2F%3E%3Cpath%20d%3D%27M96%2096q14-20%2036-16%27%2F%3E%3C%2Fg%3E%3C%2Fsvg%3E");
    --bg-blend: screen; --bg-opacity:.5;
    --panel: #f8fbff; --panel-2: #eaf3ff;
    --text: #122a54; --muted: #5f7ba6;
    --line: #d5e4f8;
    --primary: #1d43c8; --primary-2: #3f6fe0;
    --accent: #55b8e8;
    --side: linear-gradient(180deg, #0a1f6e 0%, #14309e 100%);
    --side-text: #d5e4ff; --side-on: #8fdcff;
    --top: linear-gradient(90deg, #f8fbff, #ecf3fe);
    --hero-ov: radial-gradient(circle at 82% 12%, rgba(120,220,255,.28) 0 130px, transparent 320px),
               radial-gradient(circle at 10% 90%, rgba(90,140,255,.4) 0 180px, transparent 400px),
               linear-gradient(135deg, #1c3cb0 0%, #0b1f66 100%);
}
[data-theme="xingkong"] {
    --bg: linear-gradient(160deg, #0b1e4b 0%, #14337d 60%, #2450a8 100%);
    --bg-img: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cg fill='%23d7e6ff' opacity='.8'%3E%3Ccircle cx='32' cy='42' r='2'/%3E%3Ccircle cx='92' cy='122' r='1.5'/%3E%3Ccircle cx='152' cy='32' r='2.5'/%3E%3Ccircle cx='212' cy='92' r='1.5'/%3E%3Ccircle cx='62' cy='202' r='2'/%3E%3Ccircle cx='182' cy='192' r='2.5'/%3E%3Ccircle cx='242' cy='162' r='1.5'/%3E%3Ccircle cx='122' cy='242' r='1.5'/%3E%3Ccircle cx='12' cy='132' r='1.5'/%3E%3C/g%3E%3Cg fill='%23ffffff'%3E%3Cpath d='M152 22l3 8 8 3-8 3-3 8-3-8-8-3 8-3Z'/%3E%3Cpath d='M52 192l2.5 6 6 2.5-6 2.5-2.5 6-2.5-6-6-2.5 6-2.5Z'/%3E%3Cpath d='M222 142l2 5 5 2-5 2-2 5-2-5-5-2 5-2Z'/%3E%3C/g%3E%3C/svg%3E");
    --bg-blend: multiply; --bg-opacity:.34;
    --panel: #f7faff; --panel-2: #eaf1ff;
    --text: #182748; --muted: #5f7599;
    --line: #d9e3f6;
    --primary: #1d4ed8; --primary-2: #3b82f6;
    --accent: #7dd3fc;
    --side: linear-gradient(180deg, #081435 0%, #0b1e4b 100%);
    --side-text: #cfe0ff; --side-on: #8fdcff;
    --top: linear-gradient(90deg, #f7faff, #ecf2fe);
    --hero-ov: linear-gradient(rgba(6,16,44,.4), rgba(6,16,44,.62));
}
[data-theme="aurora"] {
    --bg: linear-gradient(160deg, #e7f1fc 0%, #f3f9ff 55%, #fdfdff 100%);
    --bg-img: none; --bg-opacity:0;
    --panel: #ffffff; --panel-2: #f2f8ff;
    --text: #1d3a5f; --muted: #6f89a5;
    --line: #ddeaf6;
    --primary: #1668dc; --primary-2: #4d9df8;
    --accent: #38bdf8;
    --side: linear-gradient(180deg, #0d2c55 0%, #14508e 100%);
    --side-text: #dbeeff; --side-on: #8fdcff;
    --top: linear-gradient(90deg, #ffffff, #f2f8ff);
    --hero-ov: linear-gradient(135deg, #1668dc 0%, #0d2c55 100%);
}
[data-theme="dark"] {
    --bg: linear-gradient(160deg, #0b1220 0%, #101b30 55%, #17233f 100%);
    --bg-img: none; --bg-opacity:0;
    --panel: #1b2740; --panel-2: #223154;
    --text: #e2e9f7; --muted: #8fa1c4;
    --line: #2c3a5e;
    --primary: #3b82f6; --primary-2: #2563eb;
    --accent: #f59e0b;
    --side: linear-gradient(180deg, #0a101e 0%, #111c33 100%);
    --side-text: #c6d4f2; --side-on: #7cc4ff;
    --top: linear-gradient(90deg, #1b2740, #16223a);
    --hero-ov: linear-gradient(135deg, #1e293b 0%, #0b1220 100%);
    --shadow: 0 8px 24px rgba(0,0,0,.35);
}

/* 融创紫：品牌紫 + 星辉金（调亮版） */
[data-theme="sunac"] {
    --bg: linear-gradient(160deg, #4b1c7d 0%, #6c34a5 55%, #8a55c4 100%);
    --bg-img: none; --bg-opacity: 0;
    --panel: #fdfbff; --panel-2: #f4edfc;
    --text: #2d1b4e; --muted: #7d6b9e;
    --line: #e6dbf5;
    --primary: #6a2c91; --primary-2: #9b59d0;
    --accent: #f5a623;
    --side: linear-gradient(180deg, #3a1263 0%, #54228c 100%);
    --side-text: #f2e7ff; --side-on: #ffd977;
    --top: linear-gradient(90deg, #fdfbff, #f6effd);
    --hero-ov: radial-gradient(circle at 85% 15%, rgba(245,166,35,.26) 0 120px, transparent 260px),
               radial-gradient(circle at 10% 90%, rgba(180,122,224,.40) 0 160px, transparent 320px),
               linear-gradient(135deg, #7c42b4 0%, #4b1c7d 100%);
}
[data-theme="sunac"]::before {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .45;
    background-image: radial-gradient(circle at 82% 12%, rgba(245,166,35,.12) 0 200px, transparent 200px),
                      radial-gradient(circle at 12% 78%, rgba(196,148,235,.16) 0 240px, transparent 240px),
                      repeating-linear-gradient(45deg, transparent 0 46px, rgba(155,89,208,.05) 46px 47px);
}


/* 科技蓝：深蓝科技风（光线/粒子/光斑全部矢量生成，调亮版） */
[data-theme="keji"] {
    --bg: linear-gradient(160deg, #12307e 0%, #1f4fb8 55%, #3273e2 100%);
    --bg-img: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='320' height='320'%3E%3Cdefs%3E%3ClinearGradient id='b' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%2358b8ff' stop-opacity='.55'/%3E%3Cstop offset='1' stop-color='%2358b8ff' stop-opacity='0'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg fill='none' stroke='%236ec4ff' stroke-width='1' opacity='.4'%3E%3Cpath d='M-20 240L120 60'/%3E%3Cpath d='M40 300L200 96' stroke-opacity='.7'/%3E%3Cpath d='M120 330L300 104' stroke-opacity='.5'/%3E%3Cpath d='M210 330L340 168' stroke-opacity='.35'/%3E%3C/g%3E%3Cg stroke='url(%23b)' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M60 40l54 0'/%3E%3Cpath d='M180 130l70 0' stroke-opacity='.7'/%3E%3Cpath d='M40 190l46 0' stroke-opacity='.55'/%3E%3Cpath d='M230 250l60 0' stroke-opacity='.4'/%3E%3C/g%3E%3Cg fill='%239fd4ff'%3E%3Ccircle cx='36' cy='88' r='1.8'/%3E%3Ccircle cx='150' cy='36' r='1.4'/%3E%3Ccircle cx='252' cy='70' r='2.2'/%3E%3Ccircle cx='92' cy='170' r='1.5'/%3E%3Ccircle cx='200' cy='196' r='1.8'/%3E%3Ccircle cx='300' cy='150' r='1.3'/%3E%3Ccircle cx='60' cy='280' r='2'/%3E%3Ccircle cx='170' cy='296' r='1.5'/%3E%3Ccircle cx='286' cy='292' r='1.8'/%3E%3C/g%3E%3Cg fill='none' stroke='%237fd8ff' stroke-width='1' opacity='.35'%3E%3Cpath d='M250 22l8 0m-4 -4l0 8'/%3E%3Cpath d='M80 220l8 0m-4 -4l0 8'/%3E%3C/g%3E%3Cg fill='none' stroke='%23a9e2ff' opacity='.28'%3E%3Cpath d='M220 40l26 15v30l-26 15-26-15v-30z'/%3E%3Cpath d='M46 120l20 11.5v23L46 166l-20-11.5v-23z'/%3E%3C/g%3E%3C/svg%3E");
    --bg-blend: screen; --bg-opacity: .40;
    --panel: #f6f9ff; --panel-2: #e9f1ff;
    --text: #10265c; --muted: #5c74a8;
    --line: #d4e2fa;
    --primary: #0d3ba8; --primary-2: #2f6fe4;
    --accent: #35c5ff;
    --side: linear-gradient(180deg, #0c2757 0%, #17458f 100%);
    --side-text: #dbeaff; --side-on: #8ee0ff;
    --top: linear-gradient(90deg, #f6f9ff, #ebf2fe);
    --hero-ov: radial-gradient(circle at 85% 12%, rgba(126,214,255,.34) 0 140px, transparent 340px),
               radial-gradient(circle at 8% 92%, rgba(88,160,255,.42) 0 200px, transparent 420px),
               linear-gradient(135deg, #2f6bdc 0%, #14357f 100%);
}
[data-theme="keji"]::before {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .40;
    background-image: radial-gradient(circle at 84% 10%, rgba(94,200,255,.10) 0 220px, transparent 220px),
                      radial-gradient(circle at 10% 84%, rgba(47,111,228,.14) 0 260px, transparent 260px),
                      repeating-linear-gradient(115deg, transparent 0 58px, rgba(126,200,255,.05) 58px 59px),
                      repeating-linear-gradient(0deg, transparent 0 51px, rgba(94,150,255,.04) 51px 52px);
}


/* ---------- 基础 ---------- */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: var(--font); color: var(--text); font-size: 14px;
    background: var(--bg); min-height: 100vh;
}
body::before {
    /* 全局底纹：中式主题为代码生成的矢量纹样，商务/暗色为网格纹理 */
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background-image: var(--bg-img, none);
    background-size: 340px; background-blend-mode: var(--bg-blend, normal);
    opacity: var(--bg-opacity, 0);
}
[data-theme="aurora"] body::before, body[data-theme] [data-theme="aurora"]::before { display: none; }
[data-theme="aurora"]::before {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .5;
    background-image: radial-gradient(circle at 20% 30%, rgba(22,104,220,.06) 0 240px, transparent 240px),
                      radial-gradient(circle at 80% 70%, rgba(56,189,248,.07) 0 280px, transparent 280px),
                      repeating-linear-gradient(0deg, transparent 0 39px, rgba(22,104,220,.04) 39px 40px);
}
[data-theme="dark"]::before {
    content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: .6;
    background-image: radial-gradient(circle at 15% 20%, rgba(59,130,246,.08) 0 260px, transparent 260px),
                      repeating-linear-gradient(0deg, transparent 0 47px, rgba(148,163,184,.05) 47px 48px),
                      repeating-linear-gradient(90deg, transparent 0 47px, rgba(148,163,184,.05) 47px 48px);
}
a { color: var(--primary); text-decoration: none; }
.app { display: flex; flex-direction: column; min-height: 100vh; position: relative; z-index: 1; }
.app-body { display: flex; flex: 1; align-items: stretch; min-width: 0; }
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.content { flex: 1; padding: 20px 24px; max-width: 1400px; width: 100%; margin: 0 auto; }
.footer { text-align: center; color: var(--muted); font-size: 12px; padding: 18px 0 22px; opacity: .8; }

/* ---------- 品牌行（整行置顶） ---------- */
.site-head {
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
    height: 64px; padding: 0 22px; position: sticky; top: 0; z-index: 35;
    background: var(--side); color: var(--side-text);
    box-shadow: 0 4px 18px rgba(0, 0, 0, .22);
}
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-logo {
    width: 46px; height: 46px; border-radius: 10px; flex-shrink: 0; object-fit: contain;
    background: #fff; padding: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .28);
}
.brand-text { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.brand-name {
    font-size: 16.5px; font-weight: 700; line-height: 1.25; letter-spacing: .4px; color: #fff;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.brand-sep { color: rgba(255,255,255,.45); font-size: 14px; }
.brand-sub { font-size: 12px; font-weight: 400; letter-spacing: 1px; color: rgba(255,255,255,.72); white-space: nowrap; }
.site-head-right { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.user-name { font-size: 13px; color: var(--side-text); white-space: nowrap; }

/* ---------- 侧栏（位于品牌行与主导航下方） ---------- */
.sidebar {
    width: 232px; flex-shrink: 0; position: sticky; top: 111px; height: calc(100vh - 111px); overflow-y: auto;
    background: var(--side); color: var(--side-text);
    display: flex; flex-direction: column; z-index: 30;
    box-shadow: 4px 0 24px rgba(0,0,0,.18);
}
.nav { padding: 14px 10px 24px; display: flex; flex-direction: column; gap: 2px; }
.nav-group { font-size: 11px; letter-spacing: 2px; color: rgba(255,255,255,.45); margin: 14px 8px 4px; }
.nav a {
    display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px;
    color: var(--side-text); font-size: 13.5px; transition: all .15s;
}
.nav a i { font-style: normal; font-size: 15px; width: 20px; text-align: center; }
.nav a:hover { background: rgba(255,255,255,.1); }
.nav a.on {
    background: linear-gradient(90deg, var(--primary-2), transparent 130%);
    color: var(--side-on); font-weight: 700;
    box-shadow: inset 3px 0 0 var(--accent);
}
.mask { display: none; }

/* ---------- 内容区顶栏 ---------- */
.burger { display: none; background: none; border: 1px solid rgba(255,255,255,.3); border-radius: 8px; font-size: 17px; padding: 4px 10px; cursor: pointer; color: #fff; }
.site-head .today { color: rgba(255,255,255,.72); font-size: 13px; }
.user-menu { position: relative; display: flex; align-items: center; gap: 8px; cursor: pointer; }
.avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.avatar-text { display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; font-weight: 700; }
.dropdown {
    display: none; position: absolute; right: 0; top: 100%; min-width: 150px;
    background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
    box-shadow: var(--shadow); padding: 6px; z-index: 40; margin-top: 6px;
}
/* 悬停桥：覆盖菜单与面板之间的间隙，防止移动鼠标时弹窗消失 */
.dropdown::before { content: ''; position: absolute; left: 0; right: 0; top: -10px; height: 10px; }
.dropdown a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--text); font-size: 13px; }
.dropdown a:hover { background: var(--panel-2); }
.dropdown a.danger { color: #dc2626; }
.user-menu:hover .dropdown, .user-menu:focus-within .dropdown { display: block; }

/* ---------- 顶部主导航（全宽，从最左侧开始） ---------- */
.topnav {
    position: sticky; top: 64px; z-index: 30;
    display: flex; align-items: center; gap: 4px; padding: 8px 16px;
    background: var(--top); border-bottom: 1px solid var(--line);
    overflow-x: auto; overflow-y: hidden; scrollbar-width: none;
    box-shadow: 0 8px 16px -16px rgba(15, 23, 42, .8);
}
.topnav::-webkit-scrollbar { display: none; }
.topnav a {
    display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0;
    padding: 7px 13px; border-radius: 20px; font-size: 13px; color: var(--muted);
    border: 1px solid transparent; white-space: nowrap; transition: background .15s, color .15s;
}
.topnav a i { font-style: normal; font-size: 14px; line-height: 1; }
.topnav a:hover { background: var(--panel-2); color: var(--primary); }
.topnav a.on {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: #fff; font-weight: 600;
    box-shadow: 0 4px 12px color-mix(in srgb, var(--primary) 32%, transparent);
}
.topnav-sep { width: 1px; height: 18px; background: var(--line); margin: 0 6px; flex-shrink: 0; }

/* ---------- 头图（工作台） ---------- */
.hero {
    display: flex; justify-content: space-between; align-items: stretch; gap: 18px; flex-wrap: wrap;
    border-radius: var(--radius); padding: 26px 28px; margin-bottom: 18px;
    background-image: var(--hero-ov, linear-gradient(rgba(0,0,0,.4), rgba(0,0,0,.55))), var(--bg-img, none);
    background-size: cover, 300px; background-repeat: no-repeat, repeat; background-position: center; color: #fff;
    background-color: var(--primary); position: relative; overflow: hidden;
    box-shadow: var(--shadow);
}
.hero-left { position: relative; z-index: 1; max-width: 54%; }
.hero-hi { margin: 0 0 4px; opacity: .9; font-size: 13px; }
.hero h2 { margin: 0 0 6px; font-size: 24px; }
.hero-date { margin: 0 0 10px; font-size: 13px; opacity: .92; }
.hero-almanac { margin: 0; font-size: 12.5px; opacity: .95; line-height: 1.8; }
.hd-ok, .hd-no {
    display: inline-block; padding: 1px 8px; border-radius: 20px; font-size: 11.5px; margin-right: 4px;
}
.hd-ok { background: linear-gradient(135deg, #fbbf24, #f59e0b); color: #4c2a00; font-weight: 700; }
.hd-no { background: rgba(0,0,0,.35); color: #ddd; }
.hero-weather {
    display: flex; align-items: center; gap: 12px; position: relative; z-index: 1;
    background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22);
    padding: 14px 20px; border-radius: 14px; backdrop-filter: blur(4px);
}
.w-icon { font-size: 42px; }
.w-temp { font-size: 30px; font-weight: 800; margin: 0; line-height: 1.1; }
.w-text { margin: 2px 0; font-size: 13.5px; }
.w-extra { margin: 0; font-size: 12px; opacity: .85; }

/* ---------- KPI ---------- */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi {
    display: flex; flex-direction: column; gap: 3px; padding: 16px 18px;
    background: var(--panel); border-radius: var(--radius); border: 1px solid var(--line);
    box-shadow: var(--shadow); color: var(--text); position: relative; overflow: hidden;
    transition: transform .15s;
}
.kpi:hover { transform: translateY(-2px); }
.kpi::after {
    content: ""; position: absolute; right: -30px; top: -30px; width: 110px; height: 110px; border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-2), var(--accent)); opacity: .1;
}
.kpi-label { font-size: 12.5px; color: var(--muted); }
.kpi-value { font-size: 28px; font-weight: 800; color: var(--primary); }
.kpi.warn .kpi-value { color: #d97706; }
.kpi-sub { font-size: 12px; color: var(--muted); }
.kpi-sub2 { font-size: 11.5px; color: var(--muted); border-top: 1px dashed var(--line); padding-top: 4px; margin-top: 2px; }
.kpi-sub2 b { color: var(--text); font-size: 12.5px; }

/* ---------- 卡片与栅格 ---------- */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }

/* ---- 首页 · 项目概况 ---- */
.proj-card { margin-bottom: 18px; }
.proj-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(136px, 1fr)); gap: 10px; }
.proj-item { background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 13px; }
.proj-item span { display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.proj-item b { font-size: 15px; font-weight: 700; color: var(--text); letter-spacing: .2px; }
.proj-addr { margin: 12px 0 0; font-size: 12.5px; color: var(--muted); }

/* 人员编制架构图 */
.proj-org { margin-top: 16px; padding: 14px; border: 1px dashed var(--line); border-radius: 12px; background: var(--panel-2); }
.org-title { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 12px; }
.org-level { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }
.org-node {
    min-width: 118px; padding: 8px 14px; text-align: center; border-radius: 10px;
    background: var(--panel); border: 1px solid var(--line); box-shadow: 0 1px 3px rgba(0,0,0,.05);
}
.org-node span { display: block; font-size: 11.5px; color: var(--muted); margin-bottom: 2px; }
.org-node b { font-size: 13.5px; color: var(--text); }
.org-node.org-pm { background: linear-gradient(135deg, var(--primary), var(--primary-2)); border-color: transparent; min-width: 148px; }
.org-node.org-pm span, .org-node.org-pm b { color: #fff; }
.org-node.org-staff { border-style: dashed; }
.org-node.org-staff.out { background: var(--panel); }
.org-branch { width: 2px; height: 14px; background: var(--line); margin: 0 auto; }
.org-depts { gap: 16px; align-items: flex-start; }
.org-dept { display: flex; flex-direction: column; align-items: center; gap: 7px; }
.org-staff-chips { display: flex; flex-wrap: wrap; gap: 5px; justify-content: center; max-width: 190px; }
.org-staff-chip { font-size: 11.5px; padding: 2px 9px; border-radius: 999px; background: var(--panel); border: 1px solid var(--line); color: var(--muted); white-space: nowrap; }

/* 后台 · 项目概况编辑器 */
.grid-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 14px; }
.dept-list { display: flex; flex-direction: column; gap: 10px; }
.dept-card { border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); padding: 12px 14px; }
.dept-head-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.dept-head-row .d-dept { flex: 0 0 180px; }
.dept-head-row .d-head { flex: 0 0 140px; }
.dept-sep { font-size: 12.5px; color: var(--muted); }
.dept-del { margin-left: auto; font-size: 12.5px; color: #dc2626; }
.staff-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 8px; }
.staff-row { display: inline-flex; align-items: center; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 999px; padding: 3px 6px 3px 10px; }
.staff-row .s-name { border: none; background: none; padding: 2px 0; width: 96px; font-size: 13px; color: var(--text); outline: none; }
.staff-del { color: #dc2626; font-size: 14px; line-height: 1; padding: 0 4px; }
.staff-add { font-size: 12.5px; color: var(--primary); }

/* 消防 / 电梯维保 */
.maint-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 16px; }
.maint-item { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: var(--panel-2); }
.maint-head { display: flex; align-items: center; gap: 7px; margin-bottom: 8px; }
.maint-head b { font-size: 13.5px; }
.maint-head .badge { margin-left: auto; }
.maint-icon { font-size: 15px; }
.maint-line { margin: 3px 0; font-size: 12.5px; color: var(--muted); }
@media (max-width: 760px) { .maint-grid { grid-template-columns: 1fr; } }
.card {
    background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 18px 20px; box-shadow: var(--shadow); margin-bottom: 18px;
}
.card.narrow { max-width: 780px; }
.card-title { margin: 0 0 14px; font-size: 15.5px; display: flex; align-items: center; gap: 8px; }
.card-title .more { margin-left: auto; font-size: 12.5px; font-weight: 400; }
.empty { color: var(--muted); text-align: center; padding: 18px 0; font-size: 13px; }
.center { text-align: center; }
.err-code { font-size: 64px; font-weight: 800; color: var(--primary); margin: 20px 0 4px; }
.red { color: #dc2626; }
.muted { color: var(--muted); }
.inline { display: inline; }
button.link { background: none; border: 0; color: var(--primary); cursor: pointer; font-size: 13px; padding: 0; }
button.link.danger { color: #dc2626; }

/* 徽章 */
.badge {
    display: inline-block; padding: 2px 10px; border-radius: 20px; font-size: 11.5px; font-weight: 600; white-space: nowrap;
}
.badge.ok  { background: linear-gradient(135deg, #d1fae5, #a7f3d0); color: #065f46; }
.badge.run { background: linear-gradient(135deg, #dbeafe, #bfdbfe); color: #1e40af; }
.badge.wait{ background: linear-gradient(135deg, #fef3c7, #fde68a); color: #92400e; }
.badge.bad { background: linear-gradient(135deg, #fee2e2, #fecaca); color: #991b1b; }
.badge.lv1 { background: linear-gradient(135deg, #ede9fe, #ddd6fe); color: #5b21b6; }
.badge.lv2 { background: linear-gradient(135deg, #e0f2fe, #bae6fd); color: #075985; }
.badge.lv3 { background: linear-gradient(135deg, #dcfce7, #bbf7d0); color: #166534; }
.badge.gov { background: linear-gradient(135deg, #ffedd5, #fed7aa); color: #9a3412; }
.badge.night{ background: linear-gradient(135deg, #e0e7ff, #c7d2fe); color: #3730a3; }
.badge.day { background: linear-gradient(135deg, #fef9c3, #fef08a); color: #854d0e; }
.badge.mid { background: linear-gradient(135deg, #fce7f3, #fbcfe8); color: #9d174d; }

/* 列表条目 */
.plan-item, .duty-item { padding: 10px 2px; border-bottom: 1px dashed var(--line); font-size: 13px; }
.plan-item:last-child, .duty-item:last-child { border-bottom: 0; }
.plan-item.overdue { background: linear-gradient(90deg, rgba(220,38,38,.06), transparent); border-radius: 8px; }
.plan-top { display: flex; align-items: center; gap: 8px; margin-bottom: 5px; }
.plan-top b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar { height: 6px; border-radius: 6px; background: var(--panel-2); overflow: hidden; margin: 6px 0; }
.bar i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--primary), var(--primary-2)); }
.duty-item { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.duty-dept { margin-bottom: 6px; }
.duty-dept:last-child { margin-bottom: 0; }
.duty-dept-name { margin: 10px 0 2px; font-size: 12px; font-weight: 700; color: var(--primary); letter-spacing: .5px; }
.duty-dept-name::before { content: '▎'; }

/* 简易柱图 */
.bars { display: flex; align-items: flex-end; gap: 8px; height: 150px; padding-top: 8px; }
.bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.bar-col i { width: 70%; max-width: 34px; border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, var(--primary-2), var(--primary)); min-height: 4px; }
.bar-num { font-size: 10.5px; color: var(--muted); margin-bottom: 3px; }
.bar-label { font-size: 10.5px; color: var(--muted); margin-top: 4px; }

/* ---------- 表格 ---------- */
.tb { width: 100%; border-collapse: collapse; font-size: 13px; }
.tb th, .tb td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tb thead th {
    background: linear-gradient(180deg, var(--panel-2), transparent);
    color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .5px;
    position: sticky; top: 0;
}
.tb tbody tr:hover { background: var(--panel-2); }
.tb .ops { white-space: nowrap; text-align: right; }
.tb .ops a, .tb .ops button { margin-left: 8px; }
.tb .danger { color: #dc2626; }
.tb.detail th { width: 130px; background: var(--panel-2); color: var(--muted); }
.thumb { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; }
.view-img { max-width: 320px; max-height: 240px; border-radius: 10px; }
.pre { white-space: pre-wrap; line-height: 1.8; }
.perm-matrix td.center { text-align: center; }

/* 列表工具栏 / 筛选 */
.list-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.toolbar-actions { display: flex; gap: 8px; }
.filter-bar { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 14px; }
.filter-bar input[type="text"] { flex: 1; min-width: 160px; max-width: 300px; }
.pager { display: flex; gap: 6px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
.pager a {
    min-width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--line); border-radius: 8px; color: var(--text); font-size: 13px; padding: 0 6px;
}
.pager a.on { background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; border-color: transparent; }
.dots { color: var(--muted); align-self: center; }

/* ---------- 表单 ---------- */
.form-row { margin-bottom: 14px; }
.form-row label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 5px; }
.form-row .req { color: #dc2626; }
.form-row input[type="text"], .form-row input[type="password"], .form-row input[type="number"],
.form-row input[type="date"], .form-row input[type="month"], .form-row input[type="tel"],
.form-row input[type="email"], .form-row select, .form-row textarea, .filter-bar input, .filter-bar select {
    width: 100%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px;
    background: var(--panel); color: var(--text); font-size: 13.5px; font-family: var(--font);
    transition: border .15s, box-shadow .15s;
}
.filter-bar input, .filter-bar select { width: auto; }
.form-row input:focus, .form-row select:focus, .form-row textarea:focus, .filter-bar input:focus {
    outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent);
}
.form-row textarea { resize: vertical; line-height: 1.7; }
.hint { font-size: 12px; color: var(--muted); margin: 5px 0 0; }
.ta-wrap { position: relative; }
.ai-bar { display: flex; gap: 8px; margin-top: 8px; }
.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; }
.alert { padding: 10px 14px; border-radius: 10px; font-size: 13px; margin: 0 0 14px; }
.alert.ok { background: linear-gradient(135deg, #d1fae5, #ecfdf5); color: #065f46; }
.alert.bad { background: linear-gradient(135deg, #fee2e2, #fef2f2); color: #991b1b; }
[data-theme="dark"] .alert.ok { background: linear-gradient(135deg, #064e3b, #065f46); color: #a7f3d0; }
[data-theme="dark"] .alert.bad { background: linear-gradient(135deg, #7f1d1d, #991b1b); color: #fecaca; }

/* ---------- 按钮 ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 9px 18px; border-radius: 10px; border: 1px solid var(--line);
    background: var(--panel); color: var(--text); font-size: 13.5px; cursor: pointer;
    transition: all .15s; font-family: var(--font); text-decoration: none;
}
.btn:hover { border-color: var(--primary); color: var(--primary); }
.btn.primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: #fff; border: 0; box-shadow: 0 4px 14px color-mix(in srgb, var(--primary) 35%, transparent);
}
.btn.primary:hover { filter: brightness(1.06); color: #fff; }
.btn.ghost { background: transparent; }
.btn.block { width: 100%; }

/* ---------- 选项卡 ---------- */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; }
.tabs a {
    padding: 8px 18px; border-radius: 10px; color: var(--muted); font-size: 13.5px;
    border: 1px solid var(--line); background: var(--panel);
}
.tabs a.on {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: #fff; border-color: transparent; font-weight: 700;
}

/* ---------- 主题选择卡片 ---------- */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.theme-grid.small { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.theme-card {
    position: relative; height: 110px; border-radius: 14px; border: 2px solid transparent;
    padding: 14px; display: flex; flex-direction: column; justify-content: flex-end; gap: 2px;
    background-size: cover; background-position: center; cursor: pointer; text-align: left;
    color: #fff; font-family: var(--font); overflow: hidden; transition: transform .15s;
    box-shadow: var(--shadow);
}
.theme-card::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.55)); }
.theme-card b, .theme-card span, .theme-card i { position: relative; z-index: 1; }
.theme-card b { font-size: 15px; }
.theme-card span { font-size: 11.5px; opacity: .9; }
.theme-card:hover { transform: translateY(-3px); }
.theme-card.on { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 40%, transparent); }
.theme-card .cur {
    position: absolute; top: 10px; right: 10px; font-style: normal; font-size: 11px;
    background: var(--accent); color: #3d2318; padding: 2px 8px; border-radius: 20px; font-weight: 700;
}

/* ---------- 登录页 ---------- */
.login-body {
    display: flex; align-items: center; justify-content: center; min-height: 100vh; margin: 0;
    background-size: cover; background-position: center; position: relative;
}
.login-body::before { content: ""; position: absolute; inset: 0; backdrop-filter: blur(6px) brightness(.92); }
.login-card {
    position: relative; z-index: 1; width: min(400px, 92vw);
    background: var(--panel); border-radius: 18px; padding: 34px 36px 26px;
    box-shadow: 0 24px 70px rgba(0,0,0,.35); border: 1px solid var(--line);
}
.login-head { text-align: center; margin-bottom: 20px; }
.login-logo { width: 72px; height: 72px; border-radius: 16px; object-fit: contain; background: #fff; padding: 6px; box-shadow: 0 8px 20px rgba(0,0,0,.18); display: block; margin: 0 auto 10px; }
.login-head h1 { font-size: 20px; margin: 0 0 4px; color: var(--text); }
.login-head p { margin: 0; font-size: 12.5px; color: var(--muted); }
.login-error { background: linear-gradient(135deg, #fee2e2, #fef2f2); color: #991b1b; padding: 9px 12px; border-radius: 9px; font-size: 13px; }
.login-tip { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 16px; }

/* ---------- AI 面板 ---------- */
.ai-panel {
    position: fixed; right: 24px; bottom: 24px; width: min(480px, 94vw); z-index: 60;
    background: var(--panel); border: 1px solid var(--line); border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,.3); overflow: hidden;
}
.ai-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 12px 16px; background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; font-weight: 700;
}
.ai-close { background: none; border: 0; color: #fff; font-size: 20px; cursor: pointer; }
.ai-body { padding: 14px 16px 0; }
.ai-body textarea { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 10px; font-family: var(--font); font-size: 13px; background: var(--panel-2); color: var(--text); resize: vertical; }
.ai-status { font-size: 12px; color: var(--muted); padding: 6px 0; }
.ai-foot { display: flex; gap: 8px; justify-content: flex-end; padding: 10px 16px 14px; }

/* ---------- 收缴率同比柱图（今年 vs 去年） ---------- */
.bars.pairs .bar-col { gap: 0; }
.pair-bars { display: flex; align-items: flex-end; justify-content: center; gap: 3px; width: 100%; height: 100%; }
.pair-bars i { width: 42%; max-width: 16px; border-radius: 3px 3px 1px 1px; min-height: 3px; }
.pair-bars i.b-cur { background: linear-gradient(180deg, var(--primary-2), var(--primary)); }
.pair-bars i.b-last { background: repeating-linear-gradient(45deg, var(--muted) 0 3px, transparent 3px 6px); opacity: .45; }
.bar-legend { display: flex; gap: 16px; align-items: center; font-size: 12px; color: var(--muted); margin-bottom: 10px; }
.bar-legend .sw { display: inline-block; width: 14px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.sw.cur { background: linear-gradient(180deg, var(--primary-2), var(--primary)); }
.sw.last { background: repeating-linear-gradient(45deg, var(--muted) 0 3px, transparent 3px 6px); opacity: .6; }
.delta { font-size: 10.5px; margin-top: 2px; }
.delta.up { color: #16a34a; } .delta.down { color: #dc2626; } .delta.flat { color: var(--muted); }

/* 收缴率趋势图 · 悬停浮层（百分比 + 实收/应收具体金额） */
.bars.pairs .bar-col { position: relative; }
.bar-tip {
    position: absolute; bottom: calc(100% + 10px); left: 50%;
    transform: translateX(-50%) translateY(4px);
    min-width: 196px; padding: 8px 11px;
    background: var(--panel); color: var(--text);
    border: 1px solid var(--line); border-radius: 9px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, .16);
    font-size: 11.5px; line-height: 1.7; white-space: nowrap; text-align: left;
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity .14s ease, transform .14s ease;
    z-index: 60;
}
.bar-tip::after {
    content: ""; position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
    border: 5px solid transparent; border-top-color: var(--line);
}
.bar-tip b { display: block; font-size: 12px; margin-bottom: 3px; }
.bar-tip span { display: block; color: var(--muted); }
.bar-tip em { font-style: normal; font-weight: 700; color: var(--text); }
.bar-tip .tip-delta { margin-top: 4px; padding-top: 4px; border-top: 1px dashed var(--line); font-size: 11px; }
.bar-tip .tip-delta.up { color: #16a34a; } .bar-tip .tip-delta.down { color: #dc2626; } .bar-tip .tip-delta.flat { color: var(--muted); }
.bar-col:hover .bar-tip { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.bar-col:hover .pair-bars i { filter: brightness(1.06); }
/* 首末两列浮层向内收，避免溢出卡片边缘 */
.bars.pairs .bar-col:first-child .bar-tip { left: 0; transform: translateX(-40%) translateY(4px); }
.bars.pairs .bar-col:first-child:hover .bar-tip { transform: translateX(-40%) translateY(0); }
.bars.pairs .bar-col:last-child .bar-tip { left: auto; right: 0; transform: translateX(40%) translateY(4px); }
.bars.pairs .bar-col:last-child:hover .bar-tip { transform: translateX(40%) translateY(0); }

/* ---------- 节日温馨提醒 ---------- */
.fest-item { padding: 12px 2px; border-bottom: 1px dashed var(--line); }
.fest-item:last-child { border-bottom: 0; }
.fest-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.fest-head b { font-size: 14.5px; }
.fest-head .when { color: var(--muted); font-size: 12.5px; }
.fest-text {
    width: 100%; border: 1px dashed var(--line); border-radius: 10px; background: var(--panel-2);
    color: var(--text); font-family: var(--font); font-size: 12.5px; line-height: 1.8; padding: 10px 12px; resize: vertical;
}
.fest-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.fest-actions .btn { padding: 6px 12px; font-size: 12.5px; }

/* ---------- 移动端 ---------- */
@media (max-width: 1024px) {
    .sidebar { position: fixed; left: -240px; top: 0; transition: left .2s; height: 100dvh; }
    .sidebar.open { left: 0; }
    .mask.show { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 25; }
    .burger { display: inline-block; }
    .grid-2 { grid-template-columns: 1fr; }
    .hero-left { max-width: 100%; }
    .site-head { height: 58px; padding: 0 14px; }
    .topnav { top: 58px; }
    .sidebar { top: 0; }
}
@media (max-width: 760px) {
    .content { padding: 14px; }
    .topnav { padding: 6px 12px; gap: 2px; }
    .topnav a { padding: 6px 11px; font-size: 12.5px; }
    .today { display: none; }
    .user-name { display: none; }
    .brand-name { font-size: 14.5px; }
    .brand-sub { font-size: 11px; letter-spacing: .5px; }
    .brand-logo { width: 40px; height: 40px; }
    .brand-sub { display: none; }
    .site-head-right { gap: 10px; }
    .hero { padding: 20px; }
    .hero h2 { font-size: 20px; }
    .hero-weather { padding: 10px 14px; }
    .w-icon { font-size: 32px; }
    .w-temp { font-size: 24px; }
    /* 表格转卡片 */
    table.tb.responsive thead { display: none; }
    table.tb.responsive tbody tr {
        display: block; margin-bottom: 12px; border: 1px solid var(--line);
        border-radius: 12px; background: var(--panel); padding: 6px 12px;
    }
    table.tb.responsive tbody td {
        display: flex; justify-content: space-between; align-items: center; gap: 12px;
        border-bottom: 1px dashed var(--line); padding: 8px 2px;
    }
    table.tb.responsive tbody td:last-child { border-bottom: 0; }
    table.tb.responsive tbody td::before {
        content: attr(data-label); color: var(--muted); font-size: 12px; flex-shrink: 0;
    }
    table.tb.responsive tbody td.ops { justify-content: flex-end; }
    table.tb.responsive tbody td.ops::before { display: none; }
    .filter-bar input[type="text"] { max-width: none; }
}

/* ---- 值班排班 · 月历视图 ---- */
.cal-nav { display: inline-flex; align-items: center; gap: 8px; }
.cal-nav .btn.ghost { padding: 4px 12px; }
.shift-cal { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; }
.shift-tb { border-collapse: collapse; width: 100%; min-width: 720px; }
.shift-tb th, .shift-tb td { border: 1px solid var(--line); padding: 0; text-align: center; font-weight: inherit; }
.shift-tb thead th { padding: 6px 2px; font-size: 12px; background: var(--panel-2); color: var(--text); position: sticky; top: 0; }
.shift-tb thead th small { display: block; font-weight: 400; opacity: .6; font-size: 10px; }
.shift-tb thead th.wk, .shift-tb td.wk { background: rgba(220, 38, 38, .05); }
.shift-tb thead th.th-today { color: #2563eb; font-weight: 700; }
.shift-tb .staff-col { min-width: 72px; padding: 6px 10px; font-size: 13px; background: var(--panel-2); position: sticky; left: 0; z-index: 1; }
.shift-tb td { height: 40px; min-width: 34px; vertical-align: middle; }
.shift-tb td.td-today { box-shadow: inset 0 0 0 2px #2563eb; }
.day-chip { display: inline-block; min-width: 22px; padding: 3px 4px; border-radius: 7px; font-size: 11px; line-height: 1.3; font-weight: 600; vertical-align: middle; }
.chip-d { background: #fde68a; color: #92400e; }
.chip-m { background: #bfdbfe; color: #1e40af; }
.chip-n { background: #312e81; color: #e0e7ff; }
.shift-tb tbody tr:hover td { background: rgba(37, 99, 235, .04); }
.shift-tb tbody tr:hover td.wk { background: rgba(220, 38, 38, .07); }

/* ---- 通知与问候 · 模板库 ---- */
.tpl-library { margin: 4px 0 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); }
.tpl-library summary { cursor: pointer; padding: 10px 14px; font-weight: 600; font-size: 13.5px; color: var(--text); user-select: none; list-style: none; display: flex; align-items: center; gap: 6px; }
.tpl-library summary::-webkit-details-marker { display: none; }
.tpl-library summary::after { content: '▾'; margin-left: auto; opacity: .5; transition: transform .15s; }
.tpl-library:not([open]) summary::after { transform: rotate(-90deg); }
.tpl-lib-body { padding: 2px 14px 14px; border-top: 1px dashed var(--line); }
.tpl-group { margin-top: 10px; }
.tpl-group-name { font-size: 12.5px; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.tpl-chips { display: flex; flex-wrap: wrap; gap: 7px; }
.tpl-chip { padding: 5px 12px; border-radius: 999px; background: var(--panel); border: 1px solid var(--line); font-size: 12.5px; color: var(--text); line-height: 1.5; transition: all .12s; }
.tpl-chip:hover { border-color: var(--primary); color: var(--primary); background: var(--panel); transform: translateY(-1px); box-shadow: 0 2px 8px rgba(0,0,0,.08); }

/* ---------- 任务中心：从群消息生成任务 ---------- */
.chat-item { display: flex; gap: 12px; padding: 14px; margin-bottom: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); transition: border-color .12s, opacity .12s; }
.chat-item:hover { border-color: var(--primary); }
.chat-pick { flex: 0 0 auto; padding-top: 2px; }
.chat-pick input { width: 18px; height: 18px; cursor: pointer; accent-color: var(--primary); }
.chat-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.chat-head { display: flex; align-items: center; gap: 10px; }
.chat-title { flex: 1 1 auto; min-width: 0; font-weight: 700; font-size: 15px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--text); font-family: var(--font); }
.chat-meta { display: flex; flex-wrap: wrap; gap: 14px; }
.chat-meta label { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.chat-meta input, .chat-meta select { padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); color: var(--text); font-size: 13px; font-family: var(--font); }
.chat-meta input[name^="owner"] { width: 110px; }
.chat-content { width: 100%; box-sizing: border-box; padding: 10px; border: 1px solid var(--line); border-radius: 9px; background: var(--panel); color: var(--text); font-size: 13px; line-height: 1.6; resize: vertical; font-family: var(--font); }
.chat-actions { display: flex; gap: 10px; align-items: center; margin-top: 6px; }
.chat-item:not(:has(:checked)) { opacity: .5; }

/* ---------- 后台：维保单位编辑（可增删） ---------- */
.maint-list { display: flex; flex-direction: column; gap: 10px; }
.maint-card { border: 1px solid var(--line); border-radius: 12px; background: var(--panel-2); padding: 12px 14px; }
.maint-card-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.maint-card-head .m-name { flex: 0 0 220px; font-weight: 700; }
.maint-del { margin-left: auto; font-size: 12.5px; color: #dc2626; }
.maint-card .grid-form { margin: 0; }

/* ---------- 首页·今日值班（欢迎语区一行） ---------- */
.hero-duty { margin: 0; font-size: 13px; line-height: 1.95; opacity: .96; }
.hero-duty .hd-label { font-weight: 700; margin-right: 8px; letter-spacing: .5px; }
.hero-duty .hd-name { display: inline-block; }
.hero-duty .hd-name.is-night { color: #ffd977; font-weight: 700; }
.hero-duty .hd-name.is-night i { font-style: normal; font-size: 11px; margin-left: 1px; }
.hero-duty .hd-sep { opacity: .65; margin: 0 1px; }
.hero-duty .hd-empty { opacity: .8; }

/* ---------- 首页·黄道吉日（hero 内，与天气并排，位于天气之后） ---------- */
.hero-alm {
    display: flex; align-items: center; gap: 12px; position: relative; z-index: 1;
    background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.22);
    padding: 12px 18px; border-radius: 14px; backdrop-filter: blur(4px); max-width: 460px;
}
.hero-alm .al-mark { width: 46px; height: 46px; }
.hero-alm .al-mark b { font-size: 20px; }
.hero-alm .al-mark span { margin-top: 2px; }
.hero-alm .alm-info { min-width: 0; color: #fff; }
.hero-alm .alm-title {
    margin: 0 0 3px; font-size: 12.5px; font-weight: 700; color: #fff;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hero-alm .hd-ok, .hero-alm .hd-no { margin-right: 0; }
.hero-alm .alm-line { margin: 0; font-size: 11.5px; line-height: 1.65; color: #fff; display: flex; align-items: flex-start; gap: 6px; }
.hero-alm .alm-line span { min-width: 0; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.hero-alm .alm-line i {
    flex: 0 0 auto; font-style: normal; padding: 0 6px; border-radius: 8px;
    font-size: 10.5px; font-weight: 700; line-height: 1.5; margin-top: 1px;
}
.hero-alm .alm-line.yi i { background: rgba(74, 222, 128, .30); color: #bbf7d0; }
.hero-alm .alm-line.ji i { background: rgba(248, 113, 113, .30); color: #fecaca; }
.hero-alm .alm-extra { margin: 2px 0 0; font-size: 10.5px; opacity: .82; }
.al-mark {
    flex: 0 0 auto; width: 66px; height: 66px; border-radius: 50%;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    line-height: 1; box-shadow: 0 6px 16px rgba(15, 23, 42, .12);
}
.al-mark b { font-size: 26px; font-weight: 800; }
.al-mark span { font-size: 10.5px; letter-spacing: 1px; margin-top: 4px; opacity: .9; }
.al-mark.is-ok { background: linear-gradient(135deg, #fbd45c, #dd9a26); color: #4a2a00; }
.al-mark.is-no { background: linear-gradient(135deg, #b9c0c9, #7c8794); color: #fff; }
.al-info { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.al-title { margin: 0; font-size: 14px; font-weight: 700; color: var(--text); }
.al-line { margin: 0; font-size: 12.5px; color: var(--text); display: flex; align-items: flex-start; gap: 7px; line-height: 1.7; }
.al-line i {
    flex: 0 0 auto; width: 20px; height: 20px; border-radius: 6px;
    display: inline-flex; align-items: center; justify-content: center;
    font-style: normal; font-size: 12px; font-weight: 700;
}
.al-line.yi i { background: rgba(22, 163, 74, .14); color: #15803d; }
.al-line.ji i { background: rgba(220, 38, 38, .12); color: #b91c1c; }
.al-extra { margin: 0; font-size: 12px; color: var(--muted); }

/* ---------- 值班排班 · 月历 ---------- */
.flash-ok, .flash-err {
    padding: 10px 14px; margin-bottom: 14px; border-radius: 10px;
    background: var(--panel-2); border: 1px solid var(--line); font-size: 13px;
}
.flash-err { border-color: rgba(220, 38, 38, .35); color: #b91c1c; }
.duty-legend {
    display: flex; flex-wrap: wrap; gap: 16px; align-items: center;
    margin: 0 0 14px; font-size: 12.5px; color: var(--muted);
}
.duty-cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; }
.dcal-wk {
    text-align: center; font-size: 12px; font-weight: 700; letter-spacing: 2px;
    color: var(--muted); padding: 4px 0 8px;
}
.duty-day {
    position: relative; min-height: 96px; padding: 8px 9px 10px;
    border: 1px solid var(--line); border-radius: 10px; background: var(--panel);
    display: flex; flex-direction: column; gap: 6px;
    transition: border-color .12s, box-shadow .12s, transform .12s;
}
.duty-day[role="button"] { cursor: pointer; }
.duty-day[role="button"]:hover { border-color: var(--primary); box-shadow: var(--shadow); transform: translateY(-1px); }
.duty-day.blank { visibility: hidden; }
.duty-day.weekend { background: var(--panel-2); border-color: var(--accent); }
.duty-day.today { border: 2px solid var(--primary); box-shadow: 0 0 0 3px rgba(176, 19, 24, .10); }
.duty-day .dnum {
    font-size: 12.5px; font-weight: 700; color: var(--text);
    display: flex; align-items: baseline; gap: 5px;
}
.duty-day .dnum .rest { font-size: 10.5px; font-weight: 400; color: var(--muted); }
.duty-day .dusers { display: flex; flex-wrap: wrap; gap: 4px; }
.duty-day .duser {
    font-size: 11px; line-height: 1.5; padding: 1px 6px; border-radius: 20px;
    background: var(--panel-2); border: 1px solid var(--line); color: var(--text);
    white-space: nowrap;
}
.duty-day .duser em {
    font-style: normal; font-size: 9.5px; font-weight: 700; margin-left: 2px;
    opacity: .65;
}
.duty-day .duser.night { background: rgba(220, 38, 38, .10); border-color: rgba(220, 38, 38, .28); color: #b91c1c; }
.duty-day .duser.night em { opacity: 1; }
.duty-day .dempty { font-size: 11px; color: var(--muted); opacity: .55; }
.duty-day .addhint { margin-top: auto; font-size: 10.5px; color: var(--primary); opacity: 0; transition: opacity .12s; }
.duty-day[role="button"]:hover .addhint { opacity: 1; }

/* 本月排班统计 */
.dstat { display: flex; flex-direction: column; gap: 9px; }
.dstat-row { display: grid; grid-template-columns: 92px 1fr 52px; align-items: center; gap: 12px; font-size: 13px; }
.dstat-name { color: var(--text); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dstat-bar { height: 10px; border-radius: 6px; background: var(--panel-2); border: 1px solid var(--line); overflow: hidden; }
.dstat-bar > i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--primary), var(--accent)); }
.dstat-num { color: var(--muted); font-size: 12px; text-align: right; }

/* 排班弹窗 */
.duty-modal {
    position: fixed; inset: 0; z-index: 90; padding: 20px;
    background: rgba(15, 23, 42, .48); display: none; align-items: center; justify-content: center;
}
.duty-modal.on { display: flex; }
.duty-modal-box {
    width: min(540px, 100%); max-height: 88vh; overflow: auto;
    background: var(--panel); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow);
}
.duty-modal-hd {
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 18px; border-bottom: 1px solid var(--line); font-weight: 700; font-size: 14.5px;
}
.dm-close { border: 0; background: transparent; font-size: 20px; line-height: 1; color: var(--muted); cursor: pointer; }
.duty-modal-bd { padding: 16px 18px 18px; }
.dm-label { margin: 0 0 8px; font-size: 12.5px; color: var(--muted); }
.dm-list { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; min-height: 26px; }
.dm-item {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 3px 6px 3px 10px; border-radius: 20px;
    background: var(--panel-2); border: 1px solid var(--line); font-size: 12.5px;
}
.dm-item b { font-weight: 700; }
.dm-item i { font-style: normal; font-size: 11px; color: var(--muted); }
.dm-item u { text-decoration: none; font-size: 11px; color: var(--muted); }
.dm-item button { border: 0; background: transparent; color: #b91c1c; font-size: 15px; line-height: 1; cursor: pointer; padding: 0 2px; }
.dm-form { display: flex; flex-direction: column; gap: 10px; }
.dm-row { display: grid; grid-template-columns: 68px 1fr; align-items: center; gap: 10px; }
.dm-row label { font-size: 12.5px; color: var(--muted); }
.dm-row input, .dm-row select {
    width: 100%; padding: 8px 10px; border: 1px solid var(--line); border-radius: 9px;
    background: var(--panel); color: var(--text); font-size: 13px; font-family: var(--font);
}
.dm-row input:focus, .dm-row select:focus { outline: 2px solid rgba(176, 19, 24, .18); border-color: var(--primary); }
.dm-ft { display: flex; justify-content: flex-end; gap: 10px; margin-top: 14px; }

/* ---------- 物业新闻 ---------- */
.news-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 12px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.news-tab {
    display: inline-flex; align-items: center; gap: 4px; padding: 7px 14px; border-radius: 10px;
    font-size: 13px; color: var(--text); background: var(--panel-2); border: 1px solid var(--line);
}
.news-tab b { font-size: 11px; opacity: .7; }
.news-tab.on { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }
.news-regions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: -2px 0 12px; font-size: 12.5px; }
.news-regions-label { color: var(--muted); }
.news-chip { padding: 4px 12px; border-radius: 20px; border: 1px dashed var(--line); color: var(--muted); font-size: 12.5px; }
.news-chip.on { background: var(--panel-2); border-style: solid; border-color: var(--primary); color: var(--primary); font-weight: 600; }
.news-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.news-card {
    display: flex; flex-direction: column; gap: 8px; padding: 14px 16px;
    border: 1px solid var(--line); border-radius: 12px; background: var(--panel);
    transition: box-shadow .15s, transform .15s;
}
.news-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.news-card-top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.news-region {
    font-size: 11.5px; padding: 1px 8px; border-radius: 20px;
    background: var(--panel-2); color: var(--muted); border: 1px solid var(--line);
}
.news-region.sub { border-style: dashed; }
.news-date { margin-left: auto; font-size: 11.5px; color: var(--muted); }
.news-title { margin: 0; font-size: 15px; line-height: 1.5; }
.news-title a { color: var(--text); }
.news-title a:hover { color: var(--primary); }
.news-summary { margin: 0; font-size: 12.5px; color: var(--muted); line-height: 1.7; }
.news-meta { margin-top: auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); }
.news-auto { padding: 0 6px; border-radius: 6px; background: var(--panel-2); color: var(--primary); border: 1px solid var(--line); }
.news-ops { margin-left: auto; display: flex; gap: 8px; }
.news-pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 16px; }
.news-auto-tip { background: var(--panel-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 16px; font-size: 13px; line-height: 1.75; }
.news-auto-tip p { margin: 0 0 6px; }
.news-auto-tip p:last-child { margin: 0; }
.news-auto-form .na-row { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.news-auto-form .na-row > label:first-child { width: 76px; flex-shrink: 0; color: var(--muted); font-size: 13px; }
.na-cats { display: flex; gap: 10px; flex-wrap: wrap; }
.na-cat { position: relative; cursor: pointer; }
.na-cat input { position: absolute; opacity: 0; pointer-events: none; }
.na-cat span {
    display: inline-flex; flex-direction: column; gap: 2px; padding: 10px 18px;
    border: 1px solid var(--line); border-radius: 12px; background: var(--panel);
    font-size: 13.5px; font-weight: 600;
}
.na-cat span i { font-style: normal; font-size: 11px; color: var(--muted); font-weight: 400; }
.na-cat input:checked + span { border-color: var(--primary); background: var(--panel-2); color: var(--primary); }
.na-inline { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.na-actions { display: flex; align-items: center; gap: 12px; margin-top: 6px; flex-wrap: wrap; }
.news-auto-stat { margin: 0 0 10px; font-size: 13px; color: var(--muted); }
.news-auto-stat b.ok { color: #15803d; }
.news-result-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 12px; }
.news-result { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: var(--panel); }
.news-result-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 13.5px; }
.news-result p { margin: 4px 0 0; font-size: 12px; }
@media (max-width: 760px) {
    .news-grid { grid-template-columns: 1fr; }
    .news-auto-form .na-row > label:first-child { width: 100%; }
}

/* ---------- 新闻批量删除 ---------- */
.news-batch-bar { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; padding: 8px 12px; border: 1px dashed var(--line); border-radius: 10px; background: var(--panel-2); }
.news-batch-bar .na-inline { font-size: 13px; }
button.btn.danger, .btn.danger { background: #dc2626; border-color: #dc2626; color: #fff; }
.btn.danger:hover { background: #b91c1c; }
.news-card.selectable { position: relative; padding-left: 40px; }
.news-pick { position: absolute; left: 14px; top: 16px; cursor: pointer; }
.news-pick input { width: 17px; height: 17px; accent-color: var(--primary); cursor: pointer; }

/* ---------- 新闻弹层阅读 / 文章页 ---------- */
.art-mask {
    position: fixed; inset: 0; z-index: 300; background: rgba(15,23,42,.45);
    display: flex; align-items: flex-start; justify-content: center;
    padding: 40px 16px; overflow: hidden;
}
.art-mask[hidden] { display: none; }
.art-modal {
    position: relative; width: 100%; max-width: 780px; max-height: calc(100vh - 80px);
    overflow-y: auto; padding: 26px 30px;
}
.art-close {
    position: absolute; top: 12px; right: 14px; width: 32px; height: 32px;
    border: 1px solid var(--line); border-radius: 50%; background: var(--panel);
    cursor: pointer; font-size: 14px; color: var(--muted);
}
.art-close:hover { color: var(--primary); border-color: var(--primary); }
.art-title { margin: 10px 0 6px; font-size: 21px; line-height: 1.5; }
.art-meta { margin: 0 0 14px; font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.art-body { border-top: 1px solid var(--line); padding-top: 14px; }
.art-body p { margin: 0 0 12px; font-size: 14.5px; line-height: 1.9; }
.art-body p.art-h { font-weight: 700; color: var(--primary); margin-top: 18px; }
.art-body .art-fig { margin: 0 0 14px; text-align: center; }
.art-body .art-img { max-width: 100%; height: auto; border-radius: 8px; border: 1px solid var(--line); display: block; margin: 0 auto; cursor: zoom-in; }
@media (max-width: 640px) { .art-body .art-img { border-radius: 6px; } }
.art-foot { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--line); }
.art-page .art-title { font-size: 22px; }
