/* CoCo Rental 渠道运营后台 - 全局样式 */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Noto+Sans+SC:wght@400;500;600;700&display=swap');

* {
    font-family: 'Inter', 'Noto Sans SC', system-ui, -apple-system, sans-serif;
}

/* Sidebar */
.sidebar-link {
    transition: background-color 0.15s ease, color 0.15s ease;
}
.sidebar-link:hover {
    background-color: rgba(255, 255, 255, 0.08);
}
.sidebar-link.active {
    background-color: rgba(78, 155, 116, 0.2);
    color: #79B897;
}

/* Table */
.data-row:hover { background-color: #f9fafb; }

/* Toast */
.toast {
    position: fixed; top: 1rem; right: 1rem; z-index: 9999;
    padding: 0.75rem 1.25rem; border-radius: 0.75rem;
    font-size: 0.875rem; font-weight: 500;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    transform: translateX(120%); transition: transform 0.3s ease;
}
.toast.show { transform: translateX(0); }
.toast.success { background-color: #f0f7f3; color: #33654c; border: 1px solid #bbdecb; }
.toast.error { background-color: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* Spinner */
.spinner {
    border: 3px solid #e5e7eb; border-top: 3px solid #4e9b74; border-radius: 50%;
    width: 24px; height: 24px; animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Form input focus */
.f-input:focus, .f-input:focus-within {
    border-color: #4e9b74; box-shadow: 0 0 0 3px rgba(78, 155, 116, 0.1); outline: none;
}

/* Modal */
.modal-overlay {
    position: fixed; inset: 0; z-index: 10000; display: flex;
    align-items: center; justify-content: center;
    background: rgba(0, 0, 0, 0.35); opacity: 0; transition: opacity 0.2s ease;
}
.modal-overlay.show { opacity: 1; }
.modal-dialog {
    background: #fff; border-radius: 1rem; padding: 1.5rem 1.75rem;
    width: 640px; max-width: 94vw; max-height: 88vh; overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    transform: scale(0.95) translateY(10px); transition: transform 0.2s ease;
}
.modal-overlay.show .modal-dialog { transform: scale(1) translateY(0); }

/* Calendar */
.cal-wrap {
    overflow-x: auto;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.cal-table { border-collapse: separate; border-spacing: 0; }
.cal-table th, .cal-table td {
    border-bottom: 1px solid #eef1f4;
    border-right: 1px solid #eef1f4;
}

/* 左上角 + 车辆列（横向滚动时固定） */
.cal-corner {
    position: sticky; left: 0; z-index: 6;
    background: #f8fafc; min-width: 190px; max-width: 190px;
    text-align: left; padding: 8px 14px;
    font-size: 0.75rem; color: #6b7280; font-weight: 600;
    border-right: 2px solid #e5e7eb;
}
.cal-veh {
    position: sticky; left: 0; z-index: 4; background: #fff;
    min-width: 190px; max-width: 190px; text-align: left;
    padding: 8px 14px; border-right: 2px solid #e5e7eb;
}
.cal-veh-name { font-size: 0.8125rem; font-weight: 600; color: #1f2937; }
.cal-veh-sub { font-size: 0.7rem; color: #9ca3af; margin-top: 2px; }

/* 月份分组行 */
.cal-month {
    background: #f8fafc; text-align: center; font-weight: 600;
    font-size: 0.72rem; color: #64748b; padding: 5px 0;
    border-right: 1px solid #e5e7eb;
}

/* 日期行（日号 + 星期） */
.cal-day {
    background: #fff; width: 38px; min-width: 38px; padding: 4px 0;
    text-align: center;
}
.cal-day-num { font-size: 0.78rem; font-weight: 600; color: #374151; line-height: 1.15; }
.cal-day-wk { font-size: 0.62rem; color: #9ca3af; }
.cal-day.weekend { background: #f8fafc; }
.cal-day.weekend .cal-day-wk { color: #f59e0b; }
.cal-day.today .cal-day-num { color: #4e9b74; }
.cal-day.today { box-shadow: inset 0 -2px 0 #4e9b74; }

/* 状态格子 */
.cal-cell {
    width: 38px; min-width: 38px; height: 40px;
    cursor: pointer; transition: background-color 0.12s ease;
}
.cal-cell.weekend { background-color: #fcfcfd; }
.cal-cell.today { box-shadow: inset 1px 0 0 rgba(78,155,116,.5), inset -1px 0 0 rgba(78,155,116,.5); }
.cal-cell.available { background-color: #e7f5ee; }
.cal-cell.available:hover { background-color: #cfead9; }
.cal-cell.blocked {
    background-color: #b8c0cc;
    background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.35) 0 4px, rgba(255,255,255,0) 4px 8px);
}
.cal-cell.blocked:hover { background-color: #a7b0bd; }
.cal-cell.occupied { background-color: #f7a8a8; cursor: not-allowed; }

/* 图例 */
.cal-legend { display: flex; gap: 1.25rem; align-items: center; font-size: 0.8125rem; color: #4b5563; }
.cal-legend .dot { display: inline-block; width: 14px; height: 14px; border-radius: 4px; margin-right: 5px; vertical-align: -2px; border: 1px solid rgba(0,0,0,.06); }
.cal-legend .dot.available { background: #e7f5ee; }
.cal-legend .dot.blocked { background: #b8c0cc; background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.4) 0 3px, rgba(255,255,255,0) 3px 6px); }
.cal-legend .dot.occupied { background: #f7a8a8; }

