        .form-group { margin-bottom: 20px; }

        .form-group label {
            display: block;
            margin-bottom: 10px;
            font-weight: 600;
            color: var(--water-dark);
            font-size: 13px;
            letter-spacing: 0.5px;
            font-family: var(--font-display);
        }

        .form-group input,
        .form-group select,
        .form-group textarea {
            width: 100%;
            padding: 12px 16px;
            border: 2px solid rgba(15, 76, 92, 0.1);
            border-radius: var(--radius-sm);
            background: var(--surface-white);
            color: var(--ink-black);
            font-size: 14px;
            font-family: inherit;
            transition: var(--transition-base);
            font-weight: 500;
        }

        .form-group input:hover,
        .form-group select:hover,
        .form-group textarea:hover {
            border-color: var(--water-light);
        }

        .form-group input:focus,
        .form-group select:focus,
        .form-group textarea:focus {
            outline: none;
            border-color: var(--gold-primary);
            box-shadow: 0 0 0 4px rgba(201, 162, 39, 0.1), 0 4px 16px rgba(201, 162, 39, 0.08);
            background: #fff;
        }

        .btn {
            padding: 12px 24px;
            border: none;
            border-radius: var(--radius-sm);
            cursor: pointer;
            font-size: 14px;
            font-weight: 700;
            font-family: inherit;
            transition: var(--transition-bounce);
            letter-spacing: 1px;
            position: relative;
            overflow: hidden;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            -webkit-tap-highlight-color: transparent;
            font-family: var(--font-display);
        }

        .btn::before {
            content: "";
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
            transition: left 0.7s var(--ease-water);
            z-index: 1;
        }

        .btn:hover::before { left: 100%; }

        .btn > * { position: relative; z-index: 2; }

        .btn:active { transform: translateY(1px) scale(0.97); }

        .btn-primary {
            background: var(--gradient-water);
            color: #fff;
            box-shadow: 0 6px 20px var(--shadow-water), inset 0 1px 0 rgba(255, 255, 255, 0.2);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }
        .btn-primary:hover {
            box-shadow: 0 10px 32px rgba(15, 76, 92, 0.35), 0 4px 16px rgba(15, 76, 92, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.3);
            transform: translateY(-3px);
        }

        .btn-success {
            background: linear-gradient(135deg, #1a7d4b 0%, #28a065 100%);
            color: #fff;
            box-shadow: 0 6px 20px rgba(26, 125, 75, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }
        .btn-success:hover {
            box-shadow: 0 10px 32px rgba(26, 125, 75, 0.4), 0 4px 16px rgba(26, 125, 75, 0.2);
            transform: translateY(-3px);
        }

        .btn-danger {
            background: linear-gradient(135deg, #a02830 0%, #c93e48 100%);
            color: #fff;
            box-shadow: 0 6px 20px rgba(160, 40, 48, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }
        .btn-danger:hover {
            box-shadow: 0 10px 32px rgba(160, 40, 48, 0.4), 0 4px 16px rgba(160, 40, 48, 0.2);
            transform: translateY(-3px);
        }

        .btn-checkin {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
            position: relative;
            overflow: hidden;
        }
        .btn-checkin .btn-ico {
            width: 22px;
            height: 22px;
            flex-shrink: 0;
            display: flex;
            align-items: center;
            justify-content: center;
        }
        .btn-checkin .btn-ico svg {
            width: 100%;
            height: 100%;
        }
        .btn-checkin::after {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
            transition: left 0.5s;
        }
        .btn-checkin:hover::after {
            left: 100%;
        }
        .btn-checkin:active {
            transform: translateY(-1px) scale(0.98);
        }

        /* 补卡管理统计卡片 - 正方形图标按钮 */
        .makeup-stat-grid {
            display: grid;
            grid-template-columns: repeat(4, 1fr);
            gap: 16px;
            margin-bottom: 24px;
            max-width: 400px;
        }
        .makeup-stat-card {
            cursor: pointer;
            border-radius: var(--radius);
            padding: 0;
            text-align: center;
            border: 2px solid transparent;
            transition: all 0.28s var(--ease-smooth);
            display: flex;
            align-items: center;
            justify-content: center;
            background: var(--surface-white);
            position: relative;
            aspect-ratio: 1 / 1;
            width: 100%;
        }
        .makeup-stat-card .stat-icon-wrap {
            width: 56px;
            height: 56px;
            border-radius: 16px;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: transform 0.28s var(--ease-bounce);
        }
        .makeup-stat-card .stat-icon-wrap svg {
            width: 28px;
            height: 28px;
        }
        .makeup-stat-card .stat-badge {
            position: absolute;
            top: 6px;
            right: 6px;
            min-width: 22px;
            height: 22px;
            border-radius: 11px;
            background: #fff;
            font-size: 12px;
            font-weight: 700;
            display: flex;
            align-items: center;
            justify-content: center;
            padding: 0 6px;
            box-shadow: 0 2px 6px rgba(0,0,0,0.12);
            line-height: 1;
        }
        .makeup-stat-card .stat-text { display: none; }
        .makeup-stat-card:hover {
            transform: translateY(-4px) scale(1.03);
            box-shadow: var(--shadow-lg);
        }
        .makeup-stat-card:hover .stat-icon-wrap {
            transform: scale(1.12) rotate(-5deg);
        }
        .makeup-stat-card.active {
            transform: translateY(-2px) scale(1.02);
            box-shadow: var(--shadow-md);
        }
        .makeup-stat-card.active .stat-icon-wrap {
            transform: scale(1.08);
        }

        /* 待审 - 橙色沙漏 */
        .stat-pending {
            background: linear-gradient(145deg, #fff9f0, #fff3e0);
            border-color: rgba(230,126,34,0.25);
            box-shadow: 0 4px 12px rgba(230,126,34,0.1);
        }
        .stat-pending .stat-icon-wrap { background: linear-gradient(135deg, #f39c12, #e67e22); color: #fff; box-shadow: 0 6px 16px rgba(230,126,34,0.35); }
        .stat-pending .stat-badge { color: #d35400; border: 1.5px solid rgba(230,126,34,0.3); }
        .stat-pending:hover { border-color: rgba(230,126,34,0.5); box-shadow: 0 10px 28px rgba(230,126,34,0.22); }
        .stat-pending.active {
            border-color: #e67e22;
            box-shadow: 0 8px 24px rgba(230,126,34,0.3);
            background: linear-gradient(145deg, #fff3e0, #ffe0b2);
        }

        /* 通过 - 绿色对勾 */
        .stat-approved {
            background: linear-gradient(145deg, #f0faf4, #e8f5e9);
            border-color: rgba(39,174,96,0.25);
            box-shadow: 0 4px 12px rgba(39,174,96,0.1);
        }
        .stat-approved .stat-icon-wrap { background: linear-gradient(135deg, #2ecc71, #27ae60); color: #fff; box-shadow: 0 6px 16px rgba(39,174,96,0.35); }
        .stat-approved .stat-badge { color: #1e8449; border: 1.5px solid rgba(39,174,96,0.3); }
        .stat-approved:hover { border-color: rgba(39,174,96,0.5); box-shadow: 0 10px 28px rgba(39,174,96,0.22); }
        .stat-approved.active {
            border-color: #27ae60;
            box-shadow: 0 8px 24px rgba(39,174,96,0.3);
            background: linear-gradient(145deg, #e8f5e9, #c8e6c9);
        }

        /* 驳回 - 红色叉 */
        .stat-rejected {
            background: linear-gradient(145deg, #fef5f5, #ffebee);
            border-color: rgba(231,76,60,0.25);
            box-shadow: 0 4px 12px rgba(231,76,60,0.1);
        }
        .stat-rejected .stat-icon-wrap { background: linear-gradient(135deg, #e74c3c, #c0392b); color: #fff; box-shadow: 0 6px 16px rgba(231,76,60,0.35); }
        .stat-rejected .stat-badge { color: #922b21; border: 1.5px solid rgba(231,76,60,0.3); }
        .stat-rejected:hover { border-color: rgba(231,76,60,0.5); box-shadow: 0 10px 28px rgba(231,76,60,0.22); }
        .stat-rejected.active {
            border-color: #e74c3c;
            box-shadow: 0 8px 24px rgba(231,76,60,0.3);
            background: linear-gradient(145deg, #ffebee, #ffcdd2);
        }

        /* 全部 - 蓝灰列表 */
        .stat-all {
            background: linear-gradient(145deg, #f5f8fa, #eceff1);
            border-color: rgba(84,110,122,0.25);
            box-shadow: 0 4px 12px rgba(84,110,122,0.1);
        }
        .stat-all .stat-icon-wrap { background: linear-gradient(135deg, #607d8b, #455a64); color: #fff; box-shadow: 0 6px 16px rgba(84,110,122,0.35); }
        .stat-all .stat-badge { color: #37474f; border: 1.5px solid rgba(84,110,122,0.3); }
        .stat-all:hover { border-color: rgba(84,110,122,0.5); box-shadow: 0 10px 28px rgba(84,110,122,0.22); }
        .stat-all.active {
            border-color: #546e7a;
            box-shadow: 0 8px 24px rgba(84,110,122,0.3);
            background: linear-gradient(145deg, #eceff1, #cfd8dc);
        }

        /* 刷新按钮 */
        .btn-refresh-makeup {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 9px 18px;
            border-radius: 10px;
            border: 1.5px solid #b0c4ce;
            background: linear-gradient(135deg, #f8fbfc, #eef4f7);
            color: #3a5a6c;
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s cubic-bezier(0.4,0,0.2,1);
            box-shadow: 0 2px 6px rgba(15,76,92,0.06);
        }
        .btn-refresh-makeup:hover {
            background: linear-gradient(135deg, #0f4c5c, #1a6b7a);
            color: #fff;
            border-color: #0f4c5c;
            box-shadow: 0 4px 12px rgba(15,76,92,0.25);
            transform: translateY(-1px);
        }
        .btn-refresh-makeup:active {
            transform: translateY(0) scale(0.97);
        }
        .btn-refresh-makeup svg {
            width: 15px;
            height: 15px;
            transition: transform 0.4s cubic-bezier(0.4,0,0.2,1);
        }
        .btn-refresh-makeup:hover svg {
            transform: rotate(180deg);
        }

        /* 页面标题图标 */
        .page-title-icon {
            width: 44px;
            height: 44px;
            border-radius: 13px;
            background: linear-gradient(135deg, #e67e22, #f5b041);
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 4px 12px rgba(230,126,34,0.28);
            flex-shrink: 0;
        }
        .page-title-icon svg {
            width: 24px;
            height: 24px;
            color: #fff;
        }
        .btn-accent {
            background: linear-gradient(135deg, #b8860b 0%, #d4a017 50%, #f0c848 100%);
            color: #fff;
            box-shadow: 0 6px 20px rgba(212, 160, 23, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
            border: 1px solid rgba(255, 255, 255, 0.15);
            font-weight: 600;
        }
        .btn-accent:hover {
            box-shadow: 0 10px 32px rgba(212, 160, 23, 0.5), 0 4px 16px rgba(212, 160, 23, 0.25);
            transform: translateY(-2px);
        }
        .btn-export {
            background: linear-gradient(135deg, #1a7a3a, #2d9e4a) !important;
            color: #fff !important;
        }
        .btn-export:hover {
            box-shadow: 0 6px 20px rgba(29,132,65,0.4) !important;
        }
        .btn-outline {
            background: transparent;
            color: var(--water-primary);
            border: 2px solid var(--water-primary);
            box-shadow: none;
        }
        .btn-outline:hover {
            background: var(--water-primary);
            color: #fff;
            transform: translateY(-2px);
            box-shadow: 0 6px 20px var(--shadow-water);
        }

        .btn-warning {
            background: var(--gradient-gold);
            color: #2a1f00;
            box-shadow: var(--shadow-gold-md), inset 0 1px 0 rgba(255, 255, 255, 0.35);
            border: 1px solid rgba(255, 255, 255, 0.2);
        }
        .btn-warning:hover {
            box-shadow: 0 12px 36px rgba(201, 162, 39, 0.5), 0 4px 20px rgba(201, 162, 39, 0.3);
            transform: translateY(-3px);
        }

        .btn-info {
            background: var(--gradient-water-light);
            color: #fff;
            box-shadow: 0 6px 20px rgba(42, 147, 168, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2);
            border: 1px solid rgba(255, 255, 255, 0.1);
        }
        .btn-info:hover {
            box-shadow: 0 10px 32px rgba(42, 147, 168, 0.4), 0 4px 16px rgba(42, 147, 168, 0.2);
            transform: translateY(-3px);
        }

        .list-group { margin-top: 20px; }

        .list-group-item {
            padding: 18px 20px;
            background: var(--surface-white);
            border: 1px solid rgba(201, 162, 39, 0.1);
            border-radius: var(--radius);
            margin-bottom: 14px;
            cursor: pointer;
            transition: var(--transition-base);
            box-shadow: var(--shadow-xs);
            position: relative;
            overflow: hidden;
        }

        .list-group-item::before {
            content: "";
            position: absolute;
            left: 0;
            top: 50%;
            transform: translateY(-50%);
            width: 5px;
            height: 0;
            background: var(--gradient-gold);
            border-radius: 0 5px 5px 0;
            transition: height 0.4s var(--ease-bounce);
            box-shadow: 0 0 12px var(--shadow-gold);
        }

        .list-group-item::after {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            height: 100%;
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.03), rgba(201, 162, 39, 0.02));
            opacity: 0;
            transition: opacity 0.3s ease;
            pointer-events: none;
        }

        .list-group-item:hover {
            background: linear-gradient(145deg, var(--surface-white) 0%, var(--paper-cream) 100%);
            border-color: var(--gold-primary);
            box-shadow: var(--shadow-md), 0 0 0 1px rgba(201, 162, 39, 0.15);
            transform: translateY(-4px);
        }

        .list-group-item:hover::before { height: 70%; }
        .list-group-item:hover::after { opacity: 1; }

        .map-container {
            flex: 1;
            position: relative;
            background: var(--gradient-sky);
            overflow: hidden;
        }

        #map, #worker-map { width: 100%; height: 100%; }

        .status-badge {
            display: inline-flex;
            align-items: center;
            padding: 6px 14px;
            border-radius: 30px;
            font-size: 11px;
            font-weight: 700;
            letter-spacing: 0.5px;
            border: 2px solid transparent;
        }

        .status-badge::before {
            content: "";
            display: inline-block;
            width: 8px;
            height: 8px;
            border-radius: 50%;
            margin-right: 8px;
            animation: statusPulse 2s ease-in-out infinite;
        }

        @keyframes statusPulse {
            0%, 100% { box-shadow: 0 0 0 0 currentColor; transform: scale(1); }
            50% { box-shadow: 0 0 0 6px transparent; transform: scale(1.1); }
        }

        .status-active {
            background: linear-gradient(135deg, #d4ede2, #b8dfce);
            color: #156b3f;
            border-color: #7bc4a1;
        }
        .status-active::before { background: #1a7d4b; color: #1a7d4b; }

        .status-inactive {
            background: linear-gradient(135deg, #f5d9dc, #edc2c7);
            color: #8a2229;
            border-color: #d4959b;
        }
        .status-inactive::before { background: #a02830; color: #a02830; animation: none; }

        .status-working {
            background: linear-gradient(135deg, #d0e8ef, #b8dbe5);
            color: #0f4c5c;
            border-color: #7ab4c4;
        }
        .status-working::before { background: var(--water-primary); color: var(--water-primary); }

        .status-leave {
            background: linear-gradient(135deg, #faecc4, #f5e0a0);
            color: #6b5000;
            border-color: #dbb84a;
        }
        .status-leave::before { background: var(--gold-primary); color: var(--gold-primary); animation: none; }

        .check-in-panel {
            position: absolute;
            bottom: 20px;
            left: 20px;
            background: linear-gradient(145deg, rgba(255,255,255,0.96) 0%, rgba(250,247,240,0.98) 100%);
            backdrop-filter: blur(24px);
            -webkit-backdrop-filter: blur(24px);
            padding: 12px;
            border-radius: var(--radius);
            box-shadow:
                0 10px 32px rgba(15, 76, 92, 0.18),
                inset 0 1px 0 rgba(255, 255, 255, 0.9),
                0 0 0 1px rgba(201, 162, 39, 0.15);
            z-index: 1000;
            width: 260px;
            border: 1px solid rgba(201, 162, 39, 0.2);
            animation: panelSlideUp 0.7s var(--ease-bounce);
        }

        @keyframes panelSlideUp {
            from { opacity: 0; transform: translateY(30px) scale(0.95); }
            to { opacity: 1; transform: translateY(0) scale(1); }
        }

        .checkin-btn-group {
            display: flex;
            gap: 10px;
        }

        .checkin-btn-group .btn-checkin {
            flex: 1;
            padding: 14px 8px;
            font-size: 15px;
            font-weight: 700;
            border-radius: 14px;
            border: none;
            cursor: pointer;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            gap: 6px;
            transition: all 0.2s ease;
            letter-spacing: 1px;
            min-height: 72px;
            box-shadow: 0 4px 12px rgba(0,0,0,0.15);
        }

        .checkin-btn-group .btn-checkin .btn-ico {
            width: 28px;
            height: 28px;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .checkin-btn-group .btn-checkin .btn-ico svg {
            width: 24px;
            height: 24px;
        }

        .checkin-btn-group .btn-success {
            background: linear-gradient(135deg, #27ae60, #2ecc71);
            color: #fff;
        }

        .checkin-btn-group .btn-success:hover {
            background: linear-gradient(135deg, #229954, #27ae60);
            transform: translateY(-2px);
            box-shadow: 0 6px 16px rgba(39, 174, 96, 0.35);
        }

        .checkin-btn-group .btn-success:active {
            transform: translateY(0);
        }

        .checkin-btn-group .btn-danger {
            background: linear-gradient(135deg, #c0392b, #e74c3c);
            color: #fff;
        }

        .checkin-btn-group .btn-danger:hover {
            background: linear-gradient(135deg, #a93226, #c0392b);
            transform: translateY(-2px);
            box-shadow: 0 6px 16px rgba(231, 76, 60, 0.35);
        }

        .checkin-btn-group .btn-danger:active {
            transform: translateY(0);
        }

        .checkin-btn-group .btn-checkin:disabled {
            opacity: 0.5;
            cursor: not-allowed;
            transform: none !important;
        }

        .worker-schedule-float {
            position: absolute;
            top: 16px;
            left: 20px;
            right: 20px;
            max-width: 340px;
            z-index: 1000;
            box-shadow: 0 6px 20px rgba(15, 76, 92, 0.15);
        }

        .worker-schedule-mobile-wrap { display: none; }

        .location-info {
            margin-bottom: 20px;
            font-size: 13px;
            color: var(--ink-mid);
            padding: 14px 16px;
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.06), rgba(201, 162, 39, 0.04));
            border-radius: var(--radius-sm);
            border-left: 4px solid var(--gold-primary);
            cursor: pointer;
            transition: var(--transition-base);
            line-height: 1.7;
            font-weight: 500;
        }

        .location-info:hover {
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.1), rgba(201, 162, 39, 0.08));
            border-left-color: var(--water-primary);
            transform: translateX(4px);
            box-shadow: var(--shadow-sm);
        }

        .btn-group { display: flex; gap: 14px; }
        .btn-group .btn {
            flex: 1;
            padding: 16px;
            font-size: 14px;
            border-radius: var(--radius-sm);
        }

        .modal {
            display: none;
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(10, 46, 56, 0.6);
            backdrop-filter: blur(12px);
            -webkit-backdrop-filter: blur(12px);
            z-index: 9999;
            justify-content: center;
            align-items: center;
        }

        .modal.open { animation: modalFadeIn 0.4s var(--ease-smooth); }

        @keyframes modalFadeIn {
            from { opacity: 0; backdrop-filter: blur(0px); }
            to { opacity: 1; backdrop-filter: blur(12px); }
        }

        .modal-content {
            background: linear-gradient(145deg, var(--surface-white) 0%, var(--paper-cream) 100%);
            padding: 36px;
            border-radius: var(--radius-lg);
            width: 460px;
            max-width: 92%;
            box-shadow: var(--shadow-xl), 0 0 0 1px rgba(201, 162, 39, 0.15) inset;
            position: relative;
            animation: modalPopIn 0.5s var(--ease-bounce);
            max-height: 90vh;
            overflow-y: auto;
            border: 1px solid rgba(201, 162, 39, 0.2);
        }

        @keyframes modalPopIn {
            from { opacity: 0; transform: translateY(40px) scale(0.92); }
            to { opacity: 1; transform: translateY(0) scale(1); }
        }

        .site-img-upload-area {
            margin-top: 10px;
        }
        .site-img-upload-btn {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 8px 16px;
            background: linear-gradient(135deg, rgba(42,147,168,0.1), rgba(91,192,222,0.1));
            border: 1.5px dashed rgba(42,147,168,0.4);
            border-radius: 10px;
            color: var(--water-primary);
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        .site-img-upload-btn:hover {
            background: linear-gradient(135deg, rgba(42,147,168,0.15), rgba(91,192,222,0.15));
            border-color: var(--water-primary);
            transform: translateY(-1px);
        }
        .site-img-upload-btn svg {
            width: 18px;
            height: 18px;
        }
        .site-img-preview-list {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-top: 10px;
        }
        .site-img-preview-item {
            position: relative;
            width: 90px;
            height: 90px;
            border-radius: 10px;
            overflow: hidden;
            border: 2px solid rgba(201,162,39,0.2);
            box-shadow: 0 2px 8px rgba(0,0,0,0.1);
        }
        .site-img-preview-item img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }
        .site-img-remove {
            position: absolute;
            top: 4px;
            right: 4px;
            width: 22px;
            height: 22px;
            border-radius: 50%;
            background: rgba(220,53,69,0.9);
            color: #fff;
            border: none;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            font-weight: bold;
            line-height: 1;
            transition: all 0.2s ease;
        }
        .site-img-remove:hover {
            background: #c82333;
            transform: scale(1.1);
        }

        .site-detail-toggle {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 8px 14px;
            background: linear-gradient(135deg, rgba(42,147,168,0.08), rgba(201,162,39,0.08));
            border: 1px solid rgba(42,147,168,0.2);
            border-radius: 20px;
            color: var(--water-primary);
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.25s ease;
            margin-top: 10px;
            user-select: none;
        }
        .site-detail-toggle:hover {
            background: linear-gradient(135deg, rgba(42,147,168,0.12), rgba(201,162,39,0.12));
            border-color: var(--water-primary);
            transform: translateY(-1px);
            box-shadow: 0 2px 8px rgba(42,147,168,0.15);
        }
        .site-detail-toggle .toggle-arrow {
            transition: transform 0.3s ease;
            font-size: 12px;
        }
        .site-detail-toggle.expanded .toggle-arrow {
            transform: rotate(180deg);
        }
        .site-detail-content {
            max-height: 0;
            overflow: hidden;
            transition: max-height 0.35s ease, opacity 0.3s ease, margin 0.3s ease;
            opacity: 0;
        }
        .site-detail-content.show {
            max-height: 2000px;
            opacity: 1;
            margin-top: 10px;
        }

        .site-detail-section {
            margin-top: 10px;
            padding: 12px;
            background: linear-gradient(135deg, rgba(255,252,240,0.8), rgba(255,248,220,0.5));
            border-radius: 12px;
            border-left: 3px solid var(--gold-primary);
        }
        .site-detail-title {
            font-size: 13px;
            font-weight: 700;
            color: var(--gold-dark);
            margin-bottom: 8px;
            display: flex;
            align-items: center;
            gap: 6px;
        }
        .site-detail-text {
            font-size: 13px;
            color: #444;
            line-height: 1.6;
            white-space: pre-wrap;
            word-break: break-word;
        }
        .site-detail-images {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            margin-top: 8px;
        }
        .site-detail-img {
            width: 100px;
            height: 100px;
            border-radius: 8px;
            object-fit: cover;
            cursor: pointer;
            border: 2px solid rgba(201,162,39,0.15);
            transition: transform 0.2s ease;
        }
        .site-detail-img:hover {
            transform: scale(1.05);
            border-color: var(--gold-primary);
        }

        .modal-content h3 {
            margin-bottom: 28px;
            font-family: var(--font-display);
            color: var(--water-dark);
            font-size: 20px;
            font-weight: 700;
            padding-bottom: 16px;
            border-bottom: 2px solid rgba(201, 162, 39, 0.15);
            position: relative;
            letter-spacing: 1px;
        }

        .modal-content h3::after {
            content: "";
            position: absolute;
            left: 0;
            bottom: -2px;
            width: 64px;
            height: 4px;
            background: var(--gradient-gold);
            border-radius: 4px;
            box-shadow: 0 2px 12px var(--shadow-gold);
        }

        .close-modal {
            position: absolute;
            top: 12px;
            right: 12px;
            cursor: pointer;
            font-size: 20px;
            color: var(--ink-mid);
            line-height: 1;
            transition: all 0.2s ease;
            width: 44px;
            height: 44px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 50%;
            background: rgba(0,0,0,0.05);
            font-weight: 300;
            z-index: 10;
            -webkit-tap-highlight-color: transparent;
            user-select: none;
        }

        .close-modal:hover {
            color: #fff;
            background: var(--water-primary);
            transform: scale(1.1);
            box-shadow: 0 4px 12px rgba(26,107,124,0.3);
        }

        .close-modal:active {
            transform: scale(0.92);
            background: var(--water-dark);
        }

        .modal-content h3:first-of-type {
            padding-right: 56px;
            margin-top: 0;
        }

        .alert {
            padding: 14px 18px;
            border-radius: var(--radius-sm);
            margin-bottom: 20px;
            font-size: 13px;
            font-weight: 600;
            animation: alertSlide 0.5s var(--ease-bounce);
            border: 2px solid transparent;
        }

        @keyframes alertSlide {
            from { opacity: 0; transform: translateY(-12px); }
            to { opacity: 1; transform: translateY(0); }
        }

        .alert-success {
            background: linear-gradient(135deg, #d4ede2, #b8dfce);
            color: #125c35;
            border-color: #7bc4a1;
        }

        .alert-danger {
            background: linear-gradient(135deg, #f5d9dc, #edc2c7);
            color: #701b21;
            border-color: #d4959b;
        }

        .search-box { margin-bottom: 18px; }

        .search-box input {
            padding: 14px 18px;
            width: 100%;
            border: 2px solid rgba(15, 76, 92, 0.08);
            border-radius: var(--radius-sm);
            background: linear-gradient(145deg, var(--surface-white), var(--paper-cream));
            color: var(--ink-black);
            font-size: 14px;
            font-family: inherit;
            transition: var(--transition-base);
            font-weight: 500;
        }

        .search-box input:focus {
            outline: none;
            background: var(--surface-white);
            border-color: var(--gold-primary);
            box-shadow: 0 0 0 4px rgba(201, 162, 39, 0.1), 0 4px 16px rgba(201, 162, 39, 0.08);
        }

        .leaflet-popup-content-wrapper {
            border-radius: var(--radius) !important;
            box-shadow: var(--shadow-lg) !important;
            border: 1px solid rgba(201, 162, 39, 0.15);
        }
        .leaflet-popup-content {
            font-family: var(--font-body) !important;
            color: var(--ink-black);
            font-weight: 500;
        }

        .worker-tab-hint {
            text-align: center;
            color: var(--ink-mid);
            padding: 50px 20px;
            line-height: 2;
        }
        .worker-tab-hint .hint-icon {
            font-size: 56px;
            margin-bottom: 16px;
            filter: drop-shadow(0 6px 16px rgba(15, 76, 92, 0.2));
            animation: hintFloat 2.5s ease-in-out infinite;
        }

        @keyframes hintFloat {
            0%, 100% { transform: translateY(0) rotate(0deg); }
            50% { transform: translateY(-12px) rotate(3deg); }
        }

        .worker-tab-hint .hint-title {
            font-family: var(--font-display);
            font-weight: 700;
            color: var(--water-dark);
            font-size: 18px;
            letter-spacing: 2px;
        }
        .worker-tab-hint .hint-desc {
            font-size: 14px;
            margin-top: 12px;
            font-weight: 500;
            color: var(--ink-light);
        }

        .mobile-nav {
            display: none;
            position: fixed;
            bottom: 0;
            left: 0;
            right: 0;
            height: 56px;
            padding-bottom: env(safe-area-inset-bottom, 0px);
            background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(250,247,240,0.99) 100%);
            backdrop-filter: blur(24px);
            -webkit-backdrop-filter: blur(24px);
            border-top: 2px solid transparent;
            border-image: linear-gradient(90deg, transparent, var(--gold-primary), transparent) 1;
            z-index: 500;
            box-shadow: 0 -8px 32px rgba(15, 76, 92, 0.12);
        }

        .mobile-nav::before {
            content: "";
            position: absolute;
            top: -2px;
            left: 50%;
            transform: translateX(-50%);
            width: 120px;
            height: 4px;
            background: var(--gradient-gold);
            border-radius: 0 0 4px 4px;
            box-shadow: 0 0 20px var(--shadow-gold);
        }

        .mobile-nav-item {
            flex: 1;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            gap: 3px;
            font-size: 10px;
            color: var(--ink-light);
            cursor: pointer;
            transition: var(--transition-bounce);
            padding: 4px 0;
            user-select: none;
            -webkit-user-select: none;
            -webkit-tap-highlight-color: transparent;
            -webkit-touch-callout: none;
            touch-action: manipulation;
            position: relative;
            font-weight: 600;
        }

        .mobile-nav-item::before {
            content: "";
            position: absolute;
            top: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 0;
            height: 4px;
            background: var(--gradient-gold);
            border-radius: 0 0 4px 4px;
            transition: width 0.4s var(--ease-bounce);
            box-shadow: 0 2px 12px var(--shadow-gold);
        }

        .mobile-nav-item.active {
            color: var(--water-dark);
            font-weight: 700;
            transform: translateY(-2px);
        }

        .mobile-nav-item.active::before { width: 28px; }

        .mobile-nav-item.active .mobile-nav-icon {
            transform: scale(1.1);
            filter: drop-shadow(0 4px 8px rgba(201, 162, 39, 0.4));
        }

        .mobile-nav-icon {
            font-size: 22px;
            line-height: 1;
            transition: var(--transition-bounce);
        }

        @media (max-width: 768px) {
            html, body {
                overflow: hidden !important;
                width: 100% !important;
                max-width: 100% !important;
                position: relative;
                margin: 0;
                padding: 0;
                height: 100%;
            }
            #app {
                overflow: hidden !important;
                width: 100% !important;
                max-width: 100% !important;
                min-width: 0 !important;
                height: 100% !important;
                min-height: 100% !important;
                box-sizing: border-box !important;
                position: relative;
            }
            #app * {
                box-sizing: border-box;
            }
            body { font-size: 15px; -webkit-text-size-adjust: 100%; }

            .header {
                padding: 12px 16px;
                padding-top: calc(12px + env(safe-area-inset-top, 0px));
                min-height: calc(64px + env(safe-area-inset-top, 0px));
                position: fixed;
                top: 0;
                left: 0;
                right: 0;
                z-index: 600;
            }
            .header h1 {
                font-size: 15px;
                gap: 8px;
                letter-spacing: 1px;
                min-width: 0;
            }
            .header h1::before {
                width: 30px;
                height: 30px;
                border-radius: 8px;
            }
            .header #current-time,
            .header #worker-current-time { display: none; }
            .user-name { display: none; }
            .header-user {
                gap: 6px;
                flex-shrink: 0;
                min-width: 0;
            }
            .btn-logout {
                padding: 6px 12px;
                font-size: 12px;
                border-radius: 20px;
                white-space: nowrap;
            }
            .btn-change-pwd {
                padding: 0;
                font-size: 16px;
                border-radius: 50%;
                width: 36px;
                height: 36px;
                display: flex;
                align-items: center;
                justify-content: center;
                line-height: 1;
            }
            .btn-change-pwd .pwd-text {
                display: none;
            }
            .btn-change-pwd .pwd-icon {
                display: block;
            }
            .role-badge {
                padding: 4px 10px;
                font-size: 10px;
                white-space: nowrap;
                flex-shrink: 0;
            }
            /* 移动端员工徽标隐藏，给铃铛/修改密码/退出登录留出空间，避免退出登录被挤压 */
            .role-worker { display: none; }

            #change-password-modal {
                align-items: flex-start !important;
                padding-top: env(safe-area-inset-top, 0px);
            }
            #change-password-modal .modal-overlay {
                background: #fff;
            }
            .change-pwd-modal {
                width: 100% !important;
                max-width: 100% !important;
                border-radius: 0 !important;
                min-height: calc(100vh - env(safe-area-inset-top, 0px));
                padding: calc(24px + env(safe-area-inset-top, 20px)) 20px 24px !important;
                box-shadow: none !important;
            }

            .main-container {
                flex-direction: column;
                display: block;
                height: auto !important;
                min-height: auto !important;
                padding-top: calc(64px + env(safe-area-inset-top, 0px));
                padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px));
                overflow-x: hidden;
                width: 100% !important;
                max-width: 100% !important;
                min-width: 0 !important;
                box-sizing: border-box !important;
            }

            .sidebar {
                width: 100%;
                border-right: none;
                display: none;
                position: fixed;
                top: calc(64px + env(safe-area-inset-top, 0px));
                left: 0;
                right: 0;
                bottom: calc(56px + env(safe-area-inset-bottom, 0px));
                overflow-y: auto;
                overflow-x: hidden;
                min-width: 0 !important;
                max-width: 100% !important;
                box-sizing: border-box !important;
                -webkit-overflow-scrolling: touch;
                -webkit-transform: translateZ(0);
                transform: translateZ(0);
                backface-visibility: hidden;
                -webkit-backface-visibility: hidden;
                z-index: 50;
                background: linear-gradient(180deg, var(--surface-white) 0%, var(--paper-cream) 100%);
                contain: layout style paint;
            }

            .sidebar.mobile-visible {
                display: block !important;
            }

            .nav-tabs {
                display: none !important;
            }
            .nav-tabs::-webkit-scrollbar { display: none; }
            .nav-tab {
                padding: 12px 20px;
                font-size: 14px;
                white-space: nowrap;
                border-radius: var(--radius-sm);
                flex-shrink: 0;
                border-bottom: none;
            }
            .nav-tab::after { display: none; }
            .nav-tab.active {
                background: var(--gradient-water);
                color: #fff;
                border-radius: var(--radius-sm);
                box-shadow: 0 4px 16px var(--shadow-water);
            }
            .nav-tab.active::before { border-radius: var(--radius-sm); }
            .nav-tab-indicator { display: none; }

            .tab-content {
                padding: 18px;
                overflow-x: hidden;
                overflow-y: visible;
                width: 100%;
                max-width: 100%;
                min-width: 0 !important;
                animation: none !important;
                transform: none !important;
                -webkit-transform: none !important;
                transition: none !important;
                box-sizing: border-box;
            }
            .tab-content.active {
                display: block !important;
            }

            .map-container {
                display: none;
                position: fixed;
                top: calc(64px + env(safe-area-inset-top, 0px));
                left: 0;
                right: 0;
                bottom: calc(56px + env(safe-area-inset-bottom, 0px));
                z-index: 50;
                -webkit-transform: translateZ(0);
                transform: translateZ(0);
                backface-visibility: hidden;
                -webkit-backface-visibility: hidden;
                contain: layout style paint;
            }

            .map-container.mobile-visible { display: block; }

            .check-in-panel {
                left: 12px;
                right: 12px;
                bottom: 12px;
                width: auto;
                padding: 14px;
                border-radius: 18px;
                max-height: 48%;
                overflow-y: auto;
                box-shadow: 0 10px 32px rgba(15, 76, 92, 0.22);
            }
            .checkin-btn-group {
                gap: 12px;
            }
            .checkin-btn-group .btn-checkin {
                padding: 16px 10px;
                font-size: 16px;
                min-height: 80px;
                border-radius: 16px;
                gap: 8px;
            }
            .checkin-btn-group .btn-checkin .btn-ico {
                width: 32px;
                height: 32px;
            }
            .checkin-btn-group .btn-checkin .btn-ico svg {
                width: 28px;
                height: 28px;
            }

            /* 手机端：显示地图顶部浮动排班卡片，隐藏侧边栏排班卡片 */
            .worker-schedule-mobile-wrap { display: block; }
            .worker-schedule-sidebar { display: none !important; }

            .worker-schedule-float {
                top: 10px;
                left: 10px;
                right: 10px;
                max-width: none;
                padding: 10px 12px !important;
            }
            .worker-schedule-float h4 {
                font-size: 13px !important;
                margin-bottom: 6px !important;
            }
            .worker-schedule-float h4 span { font-size: 15px !important; }
            .worker-schedule-float #worker-schedule-status-mobile,
            .worker-schedule-float #worker-schedule-content-mobile {
                font-size: 12px !important;
            }
            .btn-group .btn {
                padding: 16px;
                font-size: 15px;
                min-height: 54px;
            }

            .btn {
                min-height: 48px !important;
                font-size: 15px !important;
                padding: 12px 20px !important;
            }

            .list-group-item .btn {
                min-height: 44px !important;
                font-size: 14px !important;
                padding: 8px 16px !important;
            }

            /* 考勤页筛选器和导出按钮 - 手机端适配 */
            .attendance-filters {
                grid-template-columns: 1fr 1fr;
                gap: 10px;
                margin-bottom: 10px;
            }
            .attendance-filters .form-group:first-child {
                grid-column: 1 / -1;
            }
            .attendance-export-btns {
                gap: 10px;
                margin-bottom: 14px;
            }
            .attendance-export-btns .btn {
                padding: 12px 10px !important;
                font-size: 14px !important;
                min-height: 46px !important;
            }

            .list-group-item {
                padding: 20px;
                margin-bottom: 16px;
                border-radius: 16px;
            }
            .list-group-item:hover {
                transform: none;
            }
            .list-group-item::before { display: none; }

            .form-group input,
            .form-group select,
            .form-group textarea {
                padding: 14px 16px;
                font-size: 16px;
                min-height: 52px;
                border-radius: 12px;
                -webkit-appearance: none;
                max-width: 100%;
                transition: none !important;
            }

            #worker-makeup input,
            #worker-makeup textarea,
            #worker-makeup select {
                box-sizing: border-box !important;
                max-width: 100% !important;
                min-width: 0;
            }

            #worker-makeup-schedule-list button {
                min-width: 0;
                white-space: nowrap;
                overflow: hidden;
            }

            .search-box input {
                padding: 14px 16px;
                font-size: 16px;
                border-radius: 12px;
            }

            .modal {
                z-index: 9999;
                -webkit-overflow-scrolling: touch;
            }
            .modal-content {
                width: 100%;
                max-width: 100%;
                height: 100%;
                max-height: 100%;
                border-radius: 0;
                padding: 28px;
                padding-top: calc(28px + env(safe-area-inset-top, 0px));
            }
            .close-modal {
                top: calc(18px + env(safe-area-inset-top, 0px));
                right: 18px;
                width: 48px;
                height: 48px;
                font-size: 26px;
                -webkit-tap-highlight-color: transparent;
                touch-action: manipulation;
                user-select: none;
                -webkit-user-select: none;
                z-index: 10;
            }
            .close-modal:active {
                transform: scale(0.9);
                background: var(--gradient-gold);
                color: #fff;
            }

            .mobile-nav { display: flex; }

            #login-page,
            #server-config-page {
                padding: 20px;
                padding-top: calc(20px + env(safe-area-inset-top, 0px));
                overflow-y: auto;
                -webkit-overflow-scrolling: touch;
            }
            .login-card {
                padding: 44px 28px 36px;
                border-radius: 28px;
                width: 100%;
                margin: 20px 0;
                max-width: 420px;
            }
            .login-card h2 { font-size: 20px; letter-spacing: 2px; }
            .login-icon img {
                width: 100px;
                height: 100px;
                border-radius: 20px;
            }
            .login-card .btn-primary {
                padding: 18px;
                font-size: 16px;
            }
            .login-card .form-group input {
                padding: 18px;
                font-size: 16px;
            }

            .status-badge {
                padding: 6px 12px;
                font-size: 12px;
            }

            .leaflet-control-zoom a {
                width: 44px !important;
                height: 44px !important;
                line-height: 44px !important;
                font-size: 22px !important;
                border-radius: 12px !important;
            }
        }

        @media (max-width: 380px) {
            .header h1 { font-size: 13px; }
            .nav-tab {
                padding: 10px 16px;
                font-size: 13px;
            }
            .check-in-panel { padding: 16px; }
            .btn-group { flex-direction: column; gap: 10px; }
            .mobile-nav-item { font-size: 10px; }
            .mobile-nav-icon { font-size: 24px; }
        }

        .custom-div-icon {
            background: transparent !important;
            border: none !important;
        }

        .employee-marker {
            width: 40px;
            height: 40px;
            background: var(--gradient-water);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-weight: 700;
            font-size: 16px;
            box-shadow: 0 6px 20px var(--shadow-water), 0 0 0 3px rgba(255,255,255,0.9);
            border: 3px solid var(--gold-primary);
            animation: markerPulse 2s ease-in-out infinite;
            font-family: var(--font-display);
        }

        @keyframes markerPulse {
            0%, 100% { box-shadow: 0 6px 20px var(--shadow-water), 0 0 0 3px rgba(255,255,255,0.9), 0 0 0 0 rgba(201, 162, 39, 0.4); }
            50% { box-shadow: 0 6px 20px var(--shadow-water), 0 0 0 3px rgba(255,255,255,0.9), 0 0 0 12px rgba(201, 162, 39, 0); }
        }

        @keyframes pulse {
            0% {
                transform: scale(0.95);
                box-shadow: 0 0 0 0 rgba(26, 107, 124, 0.7);
            }
            70% {
                transform: scale(1);
                box-shadow: 0 0 0 12px rgba(26, 107, 124, 0);
            }
            100% {
                transform: scale(0.95);
                box-shadow: 0 0 0 0 rgba(26, 107, 124, 0);
            }
        }

        .location-marker {
            width: 40px;
            height: 40px;
            background: linear-gradient(135deg, #1a6b7c, #0d4f5e);
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 20px;
            color: #ffffff;
            box-shadow: 0 4px 16px rgba(26, 107, 124, 0.5);
            border: 3px solid #d4a017;
        }

        .item-meta {
            font-size: 12px;
            color: var(--ink-light);
            margin-top: 6px;
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            align-items: center;
        }

        .item-meta span {
            display: inline-flex;
            align-items: center;
            gap: 4px;
        }

        .item-actions {
            margin-top: 12px;
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
        }

        .item-actions .btn {
            font-size: 12px !important;
            padding: 6px 14px !important;
            min-height: 34px !important;
            border-radius: 8px !important;
        }

        .trade-tag {
            display: inline-flex;
            align-items: center;
            padding: 4px 12px;
            border-radius: 20px;
            font-size: 11px;
            font-weight: 600;
            letter-spacing: 0.5px;
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.1), rgba(201, 162, 39, 0.1));
            color: var(--water-primary);
            border: 1px solid rgba(42, 147, 168, 0.2);
        }

        .report-preview {
            font-size: 12px;
            color: var(--ink-mid);
            margin-top: 8px;
            padding: 10px 12px;
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.04), rgba(201, 162, 39, 0.03));
            border-radius: var(--radius-xs);
            border-left: 3px solid var(--gold-primary);
            line-height: 1.6;
            max-height: 48px;
            overflow: hidden;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
        }

        .attachment-count {
            display: inline-flex;
            align-items: center;
            gap: 4px;
            padding: 4px 10px;
            border-radius: 20px;
            font-size: 11px;
            font-weight: 600;
            background: linear-gradient(135deg, rgba(91, 192, 212, 0.15), rgba(42, 147, 168, 0.1));
            color: var(--water-dark);
        }

        .empty-state {
            text-align: center;
            padding: 48px 24px;
            color: var(--ink-light);
        }

        .empty-state-icon {
            font-size: 56px;
            margin-bottom: 16px;
            filter: drop-shadow(0 6px 16px rgba(15, 76, 92, 0.15));
            animation: emptyFloat 3s ease-in-out infinite;
        }

        @keyframes emptyFloat {
            0%, 100% { transform: translateY(0) rotate(0deg); }
            50% { transform: translateY(-8px) rotate(-3deg); }
        }

        .empty-state-title {
            font-family: var(--font-display);
            font-weight: 700;
            color: var(--water-dark);
            font-size: 16px;
            margin-bottom: 8px;
            letter-spacing: 1px;
        }

        .empty-state-desc {
            font-size: 13px;
            font-weight: 500;
        }

        #report-content {
            min-height: 160px;
            resize: vertical;
        }

        .address-results {
            border: 2px solid rgba(201, 162, 39, 0.2);
            border-radius: var(--radius-sm);
            background: var(--surface-white);
            box-shadow: var(--shadow-sm);
            overflow: hidden;
        }

        .address-item {
            padding: 12px 16px;
            cursor: pointer;
            border-bottom: 1px solid rgba(201, 162, 39, 0.08);
            transition: var(--transition-fast);
        }

        .address-item:last-child { border-bottom: none; }

        .address-item:hover {
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.08), rgba(201, 162, 39, 0.05));
        }

        .address-item strong {
            color: var(--water-dark);
            font-size: 13px;
            display: block;
            margin-bottom: 2px;
        }

        .address-item span {
            font-size: 11px;
            color: var(--ink-light);
        }

        .attachment-grid {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            margin-top: 12px;
        }

        .attachment-thumb {
            position: relative;
            width: 90px;
        }

        .attachment-thumb img {
            width: 90px;
            height: 90px;
            object-fit: cover;
            border-radius: var(--radius-sm);
            border: 2px solid rgba(201, 162, 39, 0.15);
            cursor: pointer;
            transition: var(--transition-base);
            box-shadow: var(--shadow-xs);
        }

        .attachment-thumb img:hover {
            transform: scale(1.05);
            border-color: var(--gold-primary);
            box-shadow: var(--shadow-sm), 0 0 0 3px rgba(201, 162, 39, 0.1);
        }

        .attachment-thumb .btn-delete-attach {
            position: absolute;
            top: -8px;
            right: -8px;
            width: 24px;
            height: 24px;
            border-radius: 50%;
            background: linear-gradient(135deg, #a02830, #c93e48);
            color: white;
            border: 2px solid white;
            font-size: 14px;
            line-height: 1;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            padding: 0;
            box-shadow: 0 4px 12px rgba(160, 40, 48, 0.4);
            transition: var(--transition-bounce);
        }

        .attachment-thumb .btn-delete-attach:hover {
            transform: scale(1.15) rotate(90deg);
        }

        .attachment-name {
            font-size: 10px;
            color: var(--ink-light);
            margin-top: 4px;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
            text-align: center;
        }

        /* ==================== 现场勘探（备忘录） ==================== */
        .site-sub-tabs {
            display: flex;
            gap: 8px;
            margin-bottom: 16px;
            background: var(--surface-white);
            border-radius: var(--radius);
            padding: 4px;
            box-shadow: var(--shadow-sm);
        }
        .site-sub-tab {
            flex: 1;
            text-align: center;
            padding: 10px 8px;
            border-radius: 12px;
            font-size: 14px;
            font-weight: 600;
            color: var(--ink-mid);
            cursor: pointer;
            transition: all 0.25s ease;
            user-select: none;
            -webkit-tap-highlight-color: transparent;
        }
        .site-sub-tab.active {
            background: linear-gradient(135deg, var(--water-primary), var(--water-dark));
            color: #fff;
            box-shadow: 0 4px 12px rgba(42, 147, 168, 0.3);
        }
        .site-sub-tab:active { transform: scale(0.97); }

        .survey-card-main { cursor: pointer; padding: 2px 0; }
        .survey-card-title {
            font-size: 15px;
            font-weight: 700;
            color: var(--water-dark);
        }
        .survey-card-meta {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            margin-top: 6px;
            font-size: 12px;
            color: var(--ink-mid);
        }
        .survey-card-summary {
            margin-top: 6px;
            font-size: 12.5px;
            color: var(--ink-light);
            line-height: 1.5;
        }
        .survey-card-thumbs {
            display: flex;
            gap: 6px;
            margin-top: 10px;
        }
        .survey-card-thumbs img {
            width: 58px;
            height: 58px;
            object-fit: cover;
            border-radius: 8px;
            cursor: pointer;
            border: 1px solid rgba(201, 162, 39, 0.15);
            background: #f5f5f5;
        }
        .survey-thumb-more {
            width: 58px;
            height: 58px;
            border-radius: 8px;
            background: #eef2f5;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 12px;
            font-weight: 600;
            color: var(--ink-mid);
        }

        .survey-img-upload-area { margin-top: 6px; }
        .survey-img-upload-btn {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 9px 16px;
            background: linear-gradient(135deg, rgba(42,147,168,0.1), rgba(91,192,222,0.1));
            border: 1.5px dashed rgba(42,147,168,0.4);
            border-radius: 10px;
            color: var(--water-primary);
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        .survey-img-upload-btn:hover {
            background: linear-gradient(135deg, rgba(42,147,168,0.15), rgba(91,192,222,0.15));
            border-color: var(--water-primary);
            transform: translateY(-1px);
        }
        .survey-img-upload-btn svg { width: 18px; height: 18px; }
        .survey-img-preview-list {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-top: 10px;
        }
        .survey-img-preview-item {
            position: relative;
            width: 90px;
            height: 90px;
            border-radius: 10px;
            overflow: hidden;
            border: 2px solid rgba(201,162,39,0.2);
            box-shadow: 0 2px 8px rgba(0,0,0,0.1);
        }
        .survey-img-preview-item img { width: 100%; height: 100%; object-fit: cover; }
        .survey-img-remove {
            position: absolute;
            top: 4px;
            right: 4px;
            width: 22px;
            height: 22px;
            border-radius: 50%;
            background: rgba(220,53,69,0.9);
            color: #fff;
            border: none;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 14px;
            font-weight: bold;
            line-height: 1;
            transition: all 0.2s ease;
        }
        .survey-img-remove:hover { background: #c82333; transform: scale(1.1); }

        .survey-detail-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            flex-wrap: wrap;
            margin-bottom: 16px;
        }
        .survey-detail-card {
            background: var(--surface-white);
            border-radius: var(--radius-lg);
            padding: 24px;
            box-shadow: var(--shadow-sm);
            border-top: 4px solid var(--gold-primary);
        }
        .survey-detail-title {
            font-size: 20px;
            font-weight: 800;
            color: var(--water-dark);
            margin: 0 0 12px;
            line-height: 1.4;
        }
        .survey-detail-meta {
            display: flex;
            flex-wrap: wrap;
            gap: 14px;
            font-size: 13px;
            color: var(--ink-mid);
            padding-bottom: 16px;
            margin-bottom: 16px;
            border-bottom: 1px dashed rgba(107, 130, 153, 0.25);
        }
        .survey-detail-content {
            font-size: 15px;
            line-height: 1.8;
            color: var(--ink-dark);
            white-space: pre-wrap;
            word-break: break-word;
            margin-bottom: 20px;
        }
        .survey-detail-images {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
            gap: 10px;
        }
        .survey-detail-images img {
            width: 100%;
            aspect-ratio: 1;
            object-fit: cover;
            border-radius: 10px;
            cursor: pointer;
            border: 1px solid rgba(201, 162, 39, 0.15);
            background: #f5f5f5;
            transition: transform 0.2s ease;
        }
        .survey-detail-images img:hover { transform: scale(1.02); }

        /* ==================== 现场勘探记事本编辑器 ==================== */
        .survey-editor-topbar {
            display: flex;
            align-items: center;
            gap: 12px;
            margin-bottom: 12px;
        }
        .survey-editor-title {
            flex: 1;
            border: none;
            outline: none;
            font-size: 20px;
            font-weight: 700;
            color: var(--water-dark);
            background: transparent;
            padding: 8px 4px;
            border-bottom: 2px solid transparent;
            transition: border-color 0.2s ease;
        }
        .survey-editor-title:focus { border-bottom-color: var(--gold-primary); }
        .survey-editor-title::placeholder { color: #b6c0ca; font-weight: 500; }

        .survey-editor-meta {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            margin-bottom: 12px;
        }
        .survey-editor-meta-item {
            display: flex;
            align-items: center;
            gap: 6px;
            background: var(--surface-white);
            border-radius: 10px;
            padding: 6px 12px;
            box-shadow: var(--shadow-sm);
            font-size: 13px;
            color: var(--ink-mid);
        }
        .survey-editor-meta-item input {
            border: none;
            outline: none;
            background: transparent;
            font-size: 13px;
            color: var(--ink-dark);
            min-width: 140px;
        }
        .survey-editor-meta-item input[type="date"] { min-width: auto; }

        .survey-editor-formatbar {
            display: flex;
            align-items: center;
            gap: 6px;
            flex-wrap: wrap;
            background: var(--surface-white);
            border-radius: 10px;
            padding: 6px 10px;
            box-shadow: var(--shadow-sm);
            margin-bottom: 12px;
        }
        .survey-fmt-btn {
            min-width: 34px;
            height: 34px;
            border: none;
            background: transparent;
            border-radius: 8px;
            cursor: pointer;
            font-size: 14px;
            color: var(--ink-mid);
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: all 0.15s ease;
        }
        .survey-fmt-btn:hover {
            background: rgba(42, 147, 168, 0.12);
            color: var(--water-primary);
        }
        .survey-fmt-btn:active { transform: scale(0.94); }
        .survey-editor-sep {
            width: 1px;
            height: 20px;
            background: rgba(107, 130, 153, 0.25);
            margin: 0 4px;
        }

        .survey-editor-body {
            background: var(--surface-white);
            border-radius: var(--radius-lg);
            box-shadow: var(--shadow-sm);
            padding: 20px;
            min-height: 360px;
        }
        .survey-editor-content {
            min-height: 320px;
            outline: none;
            font-size: 15px;
            line-height: 1.8;
            color: var(--ink-dark);
            word-break: break-word;
        }
        .survey-editor-content:empty:before {
            content: attr(data-placeholder);
            color: #b6c0ca;
            pointer-events: none;
        }
        .survey-editor-content h2 {
            font-size: 18px;
            margin: 12px 0 8px;
            color: var(--water-dark);
        }
        .survey-editor-content ul, .survey-editor-content ol {
            padding-left: 24px;
            margin: 8px 0;
        }

        .survey-inline-img {
            display: block;
            max-width: 100%;
            max-height: 420px;
            border-radius: 10px;
            margin: 10px 0;
            cursor: pointer;
            border: 1px solid rgba(201, 162, 39, 0.2);
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
        }
        .survey-detail-content img, .survey-detail-content .survey-inline-img {
            display: block;
            max-width: 100%;
            max-height: 420px;
            border-radius: 10px;
            margin: 12px 0;
            cursor: pointer;
            border: 1px solid rgba(201, 162, 39, 0.2);
        }

        .survey-editor-footer {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 10px;
            margin-top: 10px;
            font-size: 12px;
            color: var(--ink-mid);
            flex-wrap: wrap;
        }

        /* 全屏记事本：编辑器视图独立覆盖整屏，避免被侧栏宽度挤压 */
        #survey-editor-view {
            position: fixed;
            inset: 0;
            z-index: 90000;
            background: #eef3f5;
            padding: 16px clamp(12px, 4vw, 40px) calc(16px + env(safe-area-inset-bottom, 0px));
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }
        #survey-editor-view .survey-editor-topbar,
        #survey-editor-view .survey-editor-meta,
        #survey-editor-view .survey-editor-formatbar,
        #survey-editor-view .survey-editor-body,
        #survey-editor-view .survey-editor-footer {
            max-width: 960px;
            margin-left: auto;
            margin-right: auto;
        }
        #survey-editor-view .survey-editor-topbar .btn,
        #survey-editor-view .survey-editor-topbar .btn-back {
            flex-shrink: 0;
            white-space: nowrap;
        }
        #survey-editor-view .survey-editor-title { min-width: 0; }
        #survey-editor-view .survey-editor-formatbar {
            position: sticky;
            top: 0;
            z-index: 5;
        }

        /* ==================== 现场手记 ==================== */
        #survey-panel {
            width: 100%;
            min-width: 0;
            max-width: 100%;
            container: survey-journal / inline-size;
        }
        .survey-journal-hero {
            display: flex;
            align-items: flex-end;
            justify-content: space-between;
            gap: 24px;
            padding: 26px 28px;
            margin-bottom: 16px;
            color: #fff;
            border-radius: 22px;
            background:
                radial-gradient(circle at 82% 18%, rgba(255,255,255,.2), transparent 28%),
                linear-gradient(135deg, #124d65 0%, #247c8c 58%, #c39b32 140%);
            box-shadow: 0 14px 34px rgba(22, 77, 101, .2);
            overflow: hidden;
        }
        .survey-journal-eyebrow {
            display: block;
            margin-bottom: 7px;
            color: rgba(255,255,255,.72);
            font-size: 12px;
            font-weight: 700;
            letter-spacing: .16em;
        }
        .survey-journal-hero h2 {
            margin: 0 0 7px;
            font-family: var(--font-display);
            font-size: clamp(25px, 4vw, 34px);
            letter-spacing: .04em;
        }
        .survey-journal-hero p {
            max-width: 660px;
            margin: 0;
            color: rgba(255,255,255,.82);
            font-size: 14px;
            line-height: 1.7;
        }
        .survey-new-button {
            flex-shrink: 0;
            min-width: 132px;
            border-color: rgba(255,255,255,.35) !important;
            color: var(--water-dark) !important;
            background: #fff !important;
            box-shadow: 0 8px 20px rgba(0,0,0,.16) !important;
        }
        .survey-stat-grid {
            display: grid;
            grid-template-columns: repeat(4, minmax(0, 1fr));
            gap: 12px;
            margin-bottom: 16px;
        }
        .survey-stat-card {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            min-width: 0;
            padding: 16px 18px;
            border: 1px solid rgba(31,106,126,.1);
            border-radius: 16px;
            background: rgba(255,255,255,.9);
            box-shadow: 0 5px 16px rgba(25,72,86,.07);
        }
        .survey-stat-card span { color: var(--ink-mid); font-size: 13px; }
        .survey-stat-card strong { color: var(--water-dark); font-size: 24px; }
        .survey-journal-toolbar {
            display: grid;
            grid-template-columns: minmax(220px, 1.7fr) repeat(5, minmax(120px, 1fr)) auto auto;
            gap: 10px;
            align-items: center;
            padding: 14px;
            margin-bottom: 10px;
            border-radius: 16px;
            background: #fff;
            box-shadow: var(--shadow-sm);
        }
        .survey-journal-toolbar > * {
            min-width: 0;
            max-width: 100%;
        }
        .survey-journal-toolbar select,
        .survey-journal-toolbar input[type="month"] {
            display: block;
            width: 100%;
            min-width: 0 !important;
            max-width: 100%;
            min-height: 42px;
            padding: 9px 10px;
            border: 1.5px solid #dce7eb;
            border-radius: 10px;
            box-sizing: border-box;
            color: var(--ink-dark);
            background: #f9fbfc;
            font-size: 13px;
        }
        .survey-journal-toolbar input[type="month"] {
            -webkit-appearance: none;
            appearance: none;
        }
        .survey-journal-search { margin: 0; }
        .survey-journal-search input { min-height: 42px; }
        .survey-favorite-filter {
            display: flex;
            align-items: center;
            gap: 5px;
            white-space: nowrap;
            color: var(--ink-mid);
            font-size: 13px;
        }
        .survey-result-line {
            padding: 5px 4px 12px;
            color: var(--ink-mid);
            font-size: 13px;
        }
        .survey-loading {
            padding: 56px 20px;
            text-align: center;
            color: var(--ink-mid);
        }
        .survey-month-group { margin-bottom: 24px; }
        .survey-month-title {
            display: flex;
            align-items: center;
            gap: 12px;
            margin: 0 0 10px;
            color: var(--water-dark);
            font-size: 14px;
            font-weight: 800;
        }
        .survey-month-title::after {
            content: '';
            height: 1px;
            flex: 1;
            background: linear-gradient(90deg, rgba(30,107,138,.18), transparent);
        }
        .survey-journal-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 14px;
        }
        .survey-journal-card {
            display: grid;
            grid-template-columns: 50px minmax(0, 1fr) minmax(96px, 28%);
            min-width: 0;
            min-height: 176px;
            overflow: hidden;
            border: 1px solid rgba(29,96,119,.1);
            border-radius: 18px;
            background: #fff;
            box-shadow: 0 7px 20px rgba(20,69,84,.08);
            cursor: pointer;
            transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
        }
        .survey-journal-card:hover {
            transform: translateY(-2px);
            border-color: rgba(42,147,168,.28);
            box-shadow: 0 12px 28px rgba(20,69,84,.13);
        }
        .survey-journal-card.no-cover { grid-template-columns: 50px minmax(0, 1fr); }
        .survey-journal-date {
            display: flex;
            flex-direction: column;
            align-items: center;
            padding: 18px 5px;
            color: var(--water-dark);
            border-right: 1px solid rgba(31,106,126,.09);
            background: linear-gradient(180deg, rgba(42,147,168,.08), rgba(255,255,255,0));
        }
        .survey-journal-date strong { font-size: 24px; line-height: 1; }
        .survey-journal-date span { margin-top: 7px; color: var(--ink-mid); font-size: 11px; }
        .survey-journal-card-body { min-width: 0; padding: 16px 14px; }
        .survey-journal-card-head {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 8px;
        }
        .survey-journal-card h3 {
            margin: 10px 0 7px;
            color: var(--water-dark);
            font-family: var(--font-display);
            font-size: 18px;
            line-height: 1.35;
        }
        .survey-journal-card p {
            display: -webkit-box;
            overflow: hidden;
            margin: 8px 0 0;
            color: var(--ink-mid);
            font-size: 12.5px;
            line-height: 1.65;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
        }
        .survey-journal-card p.muted { color: var(--ink-light); }
        .survey-journal-meta {
            display: flex;
            flex-wrap: wrap;
            gap: 5px 10px;
            color: var(--ink-mid);
            font-size: 11.5px;
        }
        .survey-journal-cover { min-width: 0; background: #eaf1f3; }
        .survey-journal-cover img { width: 100%; height: 100%; object-fit: cover; }
        .survey-category-badge,
        .survey-progress-badge {
            display: inline-flex;
            align-items: center;
            min-height: 24px;
            margin-right: 5px;
            padding: 3px 8px;
            border-radius: 999px;
            font-size: 11px;
            font-weight: 700;
        }
        .survey-category-badge { color: #17677d; background: #e6f4f7; }
        .survey-progress-badge.draft { color: #667985; background: #edf1f3; }
        .survey-progress-badge.observing { color: #9a6810; background: #fff1c9; }
        .survey-progress-badge.completed { color: #227249; background: #dff4e7; }
        .survey-favorite-btn,
        .survey-editor-favorite {
            border: none;
            color: #aab4ba;
            background: transparent;
            cursor: pointer;
            transition: color .15s ease, transform .15s ease;
        }
        .survey-favorite-btn { padding: 2px; font-size: 21px; line-height: 1; }
        .survey-editor-favorite { flex-shrink: 0; width: 38px; height: 38px; font-size: 25px; }
        .survey-favorite-btn:hover,
        .survey-editor-favorite:hover { transform: scale(1.08); }
        .survey-favorite-btn.active,
        .survey-editor-favorite.active { color: #d7a91f; }
        .survey-tag-list { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
        .survey-tag-list span {
            padding: 2px 7px;
            border-radius: 999px;
            color: #52727e;
            background: #edf4f5;
            font-size: 10.5px;
        }
        .survey-editor-context {
            display: grid;
            grid-template-columns: repeat(3, minmax(0, 1fr));
            gap: 10px;
            max-width: 960px;
            margin: 0 auto 12px;
        }
        .survey-editor-context label {
            display: flex;
            flex-direction: column;
            gap: 5px;
            min-width: 0;
            padding: 10px 12px;
            border: 1px solid rgba(31,106,126,.1);
            border-radius: 12px;
            background: #fff;
            box-shadow: var(--shadow-sm);
        }
        .survey-editor-context label > span { color: var(--ink-mid); font-size: 11px; font-weight: 700; }
        .survey-editor-context input,
        .survey-editor-context select {
            width: 100%;
            min-width: 0;
            max-width: 100%;
            border: none;
            outline: none;
            box-sizing: border-box;
            color: var(--ink-dark);
            background: transparent;
            font-size: 13px;
        }
        .survey-editor-context input[type="date"] {
            display: block;
            min-width: 0 !important;
            max-width: 100%;
            -webkit-appearance: none;
            appearance: none;
        }
        .survey-editor-context .survey-editor-tags { grid-column: span 3; }
        .survey-prompt-bar {
            display: flex;
            align-items: center;
            flex-wrap: wrap;
            gap: 7px;
            max-width: 960px;
            margin: 0 auto 12px;
            padding: 10px 12px;
            border: 1px solid rgba(201,162,39,.16);
            border-radius: 12px;
            background: #fffdf6;
        }
        .survey-prompt-bar > span { margin-right: 3px; color: #8a6b19; font-size: 12px; font-weight: 800; }
        .survey-prompt-bar button {
            padding: 6px 10px;
            border: 1px solid rgba(201,162,39,.22);
            border-radius: 999px;
            color: #6f5a20;
            background: #fff;
            font-size: 12px;
            cursor: pointer;
        }
        .survey-prompt-bar button:hover { border-color: #c9a227; background: #fff8df; }
        .survey-prompt-bar .survey-template-button { margin-left: auto; color: var(--water-primary); border-color: rgba(42,147,168,.25); }
        .survey-photo-button { width: auto; padding: 0 10px; }
        .survey-inline-figure { margin: 14px 0; }
        .survey-inline-figure figcaption {
            margin-top: 5px;
            color: var(--ink-light);
            font-size: 12px;
            text-align: center;
        }
        .survey-detail-kicker { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin-bottom: 10px; }
        .survey-detail-favorite { color: #b18412; font-size: 12px; font-weight: 700; }
        .survey-detail-tags { margin: -5px 0 18px; }
        .survey-detail-actions { display: flex; flex-wrap: wrap; gap: 8px; }
        .survey-empty-copy { padding: 20px 0; color: var(--ink-light); }

        @media (max-width: 1180px) {
            .survey-journal-toolbar { grid-template-columns: repeat(4, minmax(0, 1fr)); }
            .survey-journal-search { grid-column: span 2; }
            .survey-journal-grid { grid-template-columns: minmax(0, 1fr); }
        }

        @media (max-width: 700px) {
            .survey-journal-hero { align-items: stretch; flex-direction: column; padding: 21px 19px; }
            .survey-new-button { width: 100%; }
            .survey-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
            .survey-journal-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
            .survey-journal-search { grid-column: span 2; }
            .survey-journal-card { grid-template-columns: 42px minmax(0, 1fr) 94px; }
            .survey-journal-card.no-cover { grid-template-columns: 42px minmax(0, 1fr); }
            .survey-editor-context { grid-template-columns: minmax(0, 1fr); }
            .survey-editor-context .survey-editor-tags { grid-column: auto; }
            .survey-prompt-bar .survey-template-button { width: 100%; margin-left: 0; }
            #survey-editor-view { padding-top: 10px; }
            .survey-editor-topbar { gap: 6px; }
            .survey-editor-title { font-size: 16px; }
        }

        @media (max-width: 430px) {
            .survey-journal-toolbar { grid-template-columns: minmax(0, 1fr); }
            .survey-journal-search { grid-column: auto; }
            .survey-journal-card,
            .survey-journal-card.no-cover { grid-template-columns: 40px minmax(0, 1fr); }
            .survey-journal-cover { display: none; }
            .survey-stat-card { padding: 13px; }
            .survey-stat-card strong { font-size: 20px; }
        }

        /*
         * 电脑端的工地内容位于固定宽度侧栏中，不能只按浏览器视窗判断。
         * 这里按现场手记自身的可用宽度重排，避免宽视窗里的窄侧栏继续套用宽版网格。
         */
        @container survey-journal (max-width: 700px) {
            .survey-journal-hero {
                align-items: stretch;
                flex-direction: column;
                gap: 18px;
                padding: 21px 19px;
            }
            .survey-journal-hero h2 { font-size: clamp(25px, 8cqw, 34px); }
            .survey-new-button { width: 100%; }
            .survey-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
            .survey-journal-toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
            .survey-journal-search { grid-column: span 2; }
            .survey-journal-grid { grid-template-columns: minmax(0, 1fr); }
            .survey-editor-context { grid-template-columns: minmax(0, 1fr); }
            .survey-editor-context .survey-editor-tags { grid-column: auto; }
            .survey-prompt-bar .survey-template-button { width: 100%; margin-left: 0; }
        }

        @container survey-journal (max-width: 430px) {
            .survey-journal-toolbar { grid-template-columns: minmax(0, 1fr); }
            .survey-journal-search { grid-column: auto; }
            .survey-journal-card,
            .survey-journal-card.no-cover {
                grid-template-columns: 42px minmax(0, 1fr);
                min-height: 0;
            }
            .survey-journal-cover {
                display: block;
                grid-column: 1 / -1;
                width: 100%;
                height: clamp(150px, 54cqw, 210px);
                border-top: 1px solid rgba(31,106,126,.09);
            }
            .survey-stat-card { padding: 13px; }
            .survey-stat-card strong { font-size: 20px; }
        }

        /* 旧浏览器不支持容器查询时，桌面侧栏仍采用安全的单栏排版。 */
        @supports not (container-type: inline-size) {
            .sidebar #survey-panel .survey-journal-hero {
                align-items: stretch;
                flex-direction: column;
            }
            .sidebar #survey-panel .survey-new-button { width: 100%; }
            .sidebar #survey-panel .survey-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
            .sidebar #survey-panel .survey-journal-toolbar,
            .sidebar #survey-panel .survey-journal-grid { grid-template-columns: minmax(0, 1fr); }
            .sidebar #survey-panel .survey-journal-search { grid-column: auto; }
            .sidebar #survey-panel .survey-journal-card,
            .sidebar #survey-panel .survey-journal-card.no-cover { grid-template-columns: 42px minmax(0, 1fr); }
            .sidebar #survey-panel .survey-journal-cover { display: none; }
        }

        @media print {
            body * { visibility: hidden !important; }
            .survey-print-area,
            .survey-print-area * { visibility: visible !important; }
            .survey-print-area {
                position: absolute;
                inset: 0;
                width: 100%;
                box-shadow: none !important;
                border: none !important;
            }
            .survey-print-hide { display: none !important; }
        }

        .detail-image-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
            gap: 16px;
            margin-top: 12px;
        }

        .detail-image-item {
            text-align: center;
        }

        .detail-image-item img {
            width: 100%;
            aspect-ratio: 1;
            object-fit: cover;
            border-radius: var(--radius);
            border: 2px solid rgba(201, 162, 39, 0.15);
            cursor: pointer;
            transition: var(--transition-base);
            box-shadow: var(--shadow-sm);
        }

        .detail-image-item img:hover {
            transform: translateY(-4px) scale(1.02);
            border-color: var(--gold-primary);
            box-shadow: var(--shadow-md);
        }

        .detail-image-name {
            font-size: 11px;
            color: var(--ink-light);
            margin-top: 8px;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
        }

        .modal-detail-meta {
            font-size: 12px;
            color: var(--ink-light);
            margin-bottom: 20px;
            padding: 14px 16px;
            background: linear-gradient(135deg, rgba(42, 147, 168, 0.05), rgba(201, 162, 39, 0.04));
            border-radius: var(--radius-sm);
            border-left: 4px solid var(--gold-primary);
            line-height: 1.8;
            font-weight: 500;
        }

        .modal-detail-content {
            white-space: pre-wrap;
            line-height: 1.9;
            margin-bottom: 24px;
            padding: 20px;
            background: linear-gradient(145deg, var(--paper-cream), var(--surface-white));
            border-radius: var(--radius);
            border: 1px solid rgba(201, 162, 39, 0.1);
            color: var(--ink-dark);
            font-size: 14px;
        }

        .modal-section-title {
            font-family: var(--font-display);
            font-size: 16px;
            font-weight: 700;
            color: var(--water-dark);
            margin-bottom: 14px;
            padding-bottom: 10px;
            border-bottom: 2px solid rgba(201, 162, 39, 0.15);
            letter-spacing: 1px;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .modal-section-title::before {
            content: "◈";
            color: var(--gold-primary);
            text-shadow: 0 2px 8px var(--shadow-gold);
        }

        .time-display-digits {
            font-family: 'Courier New', monospace;
            font-variant-numeric: tabular-nums;
            font-weight: 700;
            letter-spacing: 2px;
        }

        .login-building {
            position: absolute;
            bottom: 0;
            left: 0;
            right: 0;
            height: 100%;
            pointer-events: none;
            opacity: 0.03;
            background-image:
                linear-gradient(90deg, var(--gold-light) 1px, transparent 1px),
                linear-gradient(180deg, var(--gold-light) 1px, transparent 1px);
            background-size: 60px 60px;
        }

        .list-group-item strong {
            font-family: var(--font-display);
            color: var(--water-dark);
            font-size: 15px;
            letter-spacing: 0.3px;
        }

        .leaflet-popup-content-wrapper {
            background: linear-gradient(145deg, var(--surface-white), var(--paper-cream)) !important;
        }

        .leaflet-popup-tip {
            background: var(--paper-cream) !important;
        }

        .leaflet-bar a {
            background: linear-gradient(145deg, var(--surface-white), var(--paper-cream)) !important;
            color: var(--water-dark) !important;
            border-bottom: 1px solid rgba(201, 162, 39, 0.15) !important;
            font-weight: 600 !important;
            transition: var(--transition-fast) !important;
        }

        .leaflet-bar a:hover {
            background: var(--gradient-water) !important;
            color: white !important;
        }

        input[type="file"] {
            padding: 12px !important;
            background: linear-gradient(145deg, var(--paper-cream), var(--surface-white)) !important;
            border: 2px dashed rgba(201, 162, 39, 0.3) !important;
            border-radius: var(--radius-sm) !important;
            cursor: pointer;
            transition: var(--transition-base);
        }

        input[type="file"]:hover {
            border-color: var(--gold-primary) !important;
            background: linear-gradient(145deg, rgba(201, 162, 39, 0.05), var(--paper-cream)) !important;
        }

        select option {
            padding: 10px;
            background: var(--surface-white);
            color: var(--ink-black);
        }

        .loading-spinner {
            display: inline-block;
            width: 20px;
            height: 20px;
            border: 2px solid rgba(201, 162, 39, 0.2);
            border-top-color: var(--gold-primary);
            border-radius: 50%;
            animation: spin 0.8s linear infinite;
        }

        @keyframes spin {
            to { transform: rotate(360deg); }
        }

        .text-muted {
            color: var(--ink-light) !important;
            font-weight: 500;
        }

        /* ==================== 站内消息通知 ==================== */
        .notif-bell {
            position: relative;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 38px;
            height: 38px;
            border-radius: 50%;
            border: 1px solid rgba(255, 255, 255, 0.32);
            background: rgba(255, 255, 255, 0.1);
            color: #fff;
            cursor: pointer;
            transition: var(--transition-base);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
            flex-shrink: 0;
            font-family: inherit;
        }
        .notif-bell:hover {
            background: rgba(201, 162, 39, 0.28);
            border-color: var(--gold-primary);
            transform: translateY(-2px);
            box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2), 0 0 18px rgba(201, 162, 39, 0.25);
        }
        .notif-bell svg {
            display: block;
            pointer-events: none;
        }
        .notif-badge {
            position: absolute;
            top: -5px;
            right: -5px;
            min-width: 17px;
            height: 17px;
            padding: 0 5px;
            border-radius: 9px;
            background: linear-gradient(135deg, #ff5a5f, #e0242e);
            color: #fff;
            font-size: 10px;
            font-weight: 700;
            line-height: 17px;
            text-align: center;
            box-sizing: border-box;
            box-shadow: 0 2px 8px rgba(224, 36, 46, 0.5);
            border: 1.5px solid #fff;
            pointer-events: none;
            white-space: nowrap;
        }

        .notif-drawer-overlay {
            position: fixed;
            inset: 0;
            background: rgba(10, 46, 56, 0.4);
            z-index: 95900;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.3s ease;
        }
        .notif-drawer-overlay.open {
            opacity: 1;
            pointer-events: auto;
        }

        .notif-drawer {
            position: fixed;
            top: 0;
            right: 0;
            bottom: 0;
            width: 380px;
            max-width: 100vw;
            background: var(--paper-cool);
            z-index: 96000;
            box-shadow: -12px 0 48px rgba(10, 46, 56, 0.22);
            transform: translateX(105%);
            transition: transform 0.32s var(--ease-smooth);
            display: flex;
            flex-direction: column;
            padding-top: env(safe-area-inset-top, 0px);
        }
        .notif-drawer.open {
            transform: translateX(0);
        }

        .notif-drawer-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            padding: 16px 20px;
            background: var(--gradient-water);
            color: #fff;
            flex-shrink: 0;
        }
        .notif-drawer-title {
            display: flex;
            align-items: center;
            gap: 8px;
            font-size: 16px;
            font-weight: 700;
            letter-spacing: 1px;
            min-width: 0;
        }
        .notif-drawer-title svg {
            flex-shrink: 0;
        }
        .notif-drawer-actions {
            display: flex;
            align-items: center;
            gap: 8px;
            flex-shrink: 0;
        }
        .notif-mark-all {
            background: rgba(255, 255, 255, 0.12);
            color: #fff;
            border: 1px solid rgba(255, 255, 255, 0.3);
            padding: 6px 14px;
            border-radius: 20px;
            font-size: 12px;
            cursor: pointer;
            white-space: nowrap;
            transition: var(--transition-fast);
            font-family: inherit;
        }
        .notif-mark-all:hover {
            background: rgba(255, 255, 255, 0.22);
        }
        .notif-close {
            width: 32px;
            height: 32px;
            border-radius: 50%;
            border: none;
            background: rgba(255, 255, 255, 0.12);
            color: #fff;
            font-size: 20px;
            line-height: 1;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: var(--transition-fast);
            font-family: inherit;
        }
        .notif-close:hover {
            background: rgba(255, 255, 255, 0.25);
            transform: rotate(90deg);
        }

        .notif-list {
            flex: 1;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
            padding: 12px;
        }
        .notif-empty,
        .notif-loading {
            text-align: center;
            color: var(--ink-light);
            font-size: 14px;
            padding: 48px 20px;
        }

        .notif-item {
            display: flex;
            align-items: flex-start;
            gap: 12px;
            padding: 14px 16px;
            margin-bottom: 10px;
            background: var(--surface-white);
            border-radius: 14px;
            box-shadow: var(--shadow-sm);
            cursor: pointer;
            transition: var(--transition-fast);
            border: 1px solid transparent;
        }
        .notif-item:hover {
            transform: translateY(-2px);
            box-shadow: var(--shadow-md);
            border-color: rgba(201, 162, 39, 0.25);
        }
        .notif-item.notif-unread {
            background: linear-gradient(135deg, #fffdf6, #fff8e6);
            border-color: rgba(201, 162, 39, 0.3);
        }
        .notif-item-icon {
            width: 34px;
            height: 34px;
            border-radius: 10px;
            display: flex;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
        }
        .notif-item-icon svg {
            display: block;
        }
        .notif-icon-ok {
            background: linear-gradient(135deg, #e6f7ec, #d2f0dd);
            color: #1e9e4a;
        }
        .notif-icon-bad {
            background: linear-gradient(135deg, #fdeaea, #fad6d6);
            color: #d63a3a;
        }
        .notif-icon-info {
            background: linear-gradient(135deg, #e8f1f8, #d8e8f5);
            color: #2f6f9f;
        }
        .notif-item-body {
            flex: 1;
            min-width: 0;
        }
        .notif-item-title {
            font-size: 14px;
            font-weight: 700;
            color: var(--water-dark);
            margin-bottom: 2px;
            letter-spacing: 0.3px;
        }
        .notif-item-content {
            font-size: 13px;
            color: var(--ink-mid);
            line-height: 1.6;
            word-break: break-word;
        }
        .notif-item-time {
            font-size: 11px;
            color: var(--ink-light);
            margin-top: 6px;
        }

        @media (max-width: 768px) {
            .notif-bell {
                width: 36px;
                height: 36px;
            }
            .notif-drawer {
                width: 100vw;
            }
            /* 手机端：报告页顶部已有「工地报告/档案管理/仓库管理」，
               移入的档案内容里不再重复显示内部子标签条 */
            #archive-sub-tabs {
                display: none;
            }
        }

/* Keep the fixed admin header from covering site tabs on very narrow phones. */
@media (max-width: 360px) {
    #admin-app .header h1::before { flex-shrink: 0; }
    #admin-app .admin-header-title {
        min-width: 0;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 2;
        overflow: hidden;
        line-height: 20px;
    }
}
