/* 全域樣式 */
:root {
    --primary-color: #4a90d9;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --dark-color: #343a40;
    --light-color: #f8f9fa;
    --border-color: #dee2e6;
}

* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans TC", sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    color: #333;
}

/* 打卡頁面樣式 */
.punch-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

.punch-header {
    text-align: center;
    margin-bottom: 30px;
}

.punch-header h1 {
    color: var(--dark-color);
    margin-bottom: 10px;
}

.current-time {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-color);
}

.current-date {
    font-size: 1.2rem;
    color: #666;
}

/* 攝影機區域 */
.camera-section {
    position: relative;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
}

#video-container {
    position: relative;
    width: 100%;
    aspect-ratio: 4/3;
}

#video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scaleX(-1);
}

#overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: scaleX(-1);
}

/* 狀態顯示 */
.status-panel {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.1rem;
    position: relative;
}

/* 同步狀態燈號 */
.sync-indicator {
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    gap: 5px;
    cursor: help;
}

.sync-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background-color: #6c757d;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
    transition: background-color 0.3s ease;
}

.sync-dot.syncing {
    background-color: #ffc107;
    animation: sync-pulse 1s infinite;
}

.sync-dot.success {
    background-color: #28a745;
    box-shadow: 0 0 8px rgba(40, 167, 69, 0.5);
}

.sync-dot.warning {
    background-color: #ffc107;
    box-shadow: 0 0 8px rgba(255, 193, 7, 0.5);
}

.sync-dot.error {
    background-color: #dc3545;
    box-shadow: 0 0 8px rgba(220, 53, 69, 0.5);
    animation: error-pulse 1.5s infinite;
}

@keyframes sync-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(0.9); }
}

@keyframes error-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

.status-dot.loading {
    background-color: var(--warning-color);
}

.status-dot.ready {
    background-color: var(--success-color);
}

.status-dot.error {
    background-color: var(--danger-color);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* 打卡結果 */
.punch-result {
    background: white;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    display: none;
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    min-width: 280px;
    max-width: 90%;
}

.punch-result.show {
    display: block;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.punch-result.success {
    border-left: 5px solid var(--success-color);
}

.punch-result.error {
    border-left: 5px solid var(--danger-color);
}

.punch-result.warning {
    border-left: 5px solid var(--warning-color);
}

.punch-result.info {
    border-left: 5px solid #17a2b8;
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
}

.punch-result h2 {
    margin: 0 0 10px 0;
    font-size: 1.2rem;
}

/* 閒置遮罩 */
.idle-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
    cursor: pointer;
    border-radius: 12px;
}

.idle-overlay .idle-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: pulse-idle 2s infinite;
}

.idle-overlay .idle-text {
    color: white;
    font-size: 1.5rem;
    font-weight: bold;
    text-align: center;
}

.idle-overlay .idle-subtext {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    margin-top: 10px;
}

@keyframes pulse-idle {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(1.1);
    }
}

.punch-result .employee-name {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
}

.punch-result .punch-type {
    font-size: 1.2rem;
    margin: 10px 0;
}

.punch-result .punch-time {
    color: #666;
}

/* 最近打卡記錄 */
.recent-punches {
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.recent-punches h3 {
    margin: 0 0 15px 0;
    color: var(--dark-color);
}

.punch-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.punch-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
}

.punch-list li:last-child {
    border-bottom: none;
}

.punch-list .name {
    font-weight: 500;
}

.punch-list .type {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
}

.punch-list .type.in {
    background-color: #d4edda;
    color: #155724;
}

.punch-list .type.out {
    background-color: #cce5ff;
    color: #004085;
}

/* 後台樣式 */
.admin-container {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: var(--dark-color);
    color: white;
    padding: 20px 0;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    padding: 0 20px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 20px;
}

.sidebar-header h2 {
    margin: 0;
    font-size: 1.2rem;
}

.sidebar-nav {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav li a {
    display: block;
    padding: 12px 20px;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: all 0.2s;
}

.sidebar-nav li a:hover,
.sidebar-nav li a.active {
    background: rgba(255,255,255,0.1);
    color: white;
}

.sidebar-nav li a i {
    margin-right: 10px;
    width: 20px;
}

.sidebar-nav li a .badge {
    float: right;
    margin-top: 2px;
}

.main-content {
    flex: 1;
    margin-left: 250px;
    padding: 30px;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.page-header h1 {
    margin: 0;
    color: var(--dark-color);
}

/* 卡片樣式 */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.card-header {
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h3 {
    margin: 0;
}

.card-body {
    padding: 20px;
}

/* 表格樣式 */
.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.table th {
    background: var(--light-color);
    font-weight: 600;
    color: var(--dark-color);
}

.table tbody tr:hover {
    background: #f8f9fa;
}

/* 按鈕樣式 */
.btn {
    display: inline-block;
    padding: 8px 16px;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #3a7fc9;
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-success:hover {
    background: #218838;
}

.btn-danger {
    background: var(--danger-color);
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 0.8rem;
}

/* 表單樣式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--dark-color);
}

.form-control {
    width: 100%;
    padding: 10px 12px;
    font-size: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    transition: border-color 0.2s;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 217, 0.1);
}

.form-row {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.form-row .form-group {
    flex: 1;
    min-width: 150px;
}

.form-text {
    font-size: 0.85rem;
    color: #666;
    margin-top: 5px;
}

.form-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
}

.required {
    color: var(--danger-color);
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 10px center;
    background-repeat: no-repeat;
    background-size: 20px;
    padding-right: 40px;
}

/* Modal 樣式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* 人臉註冊區域 */
.face-register-area {
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    margin-top: 10px;
}

.face-preview {
    width: 200px;
    height: 200px;
    margin: 0 auto 15px;
    border-radius: 8px;
    overflow: hidden;
    background: #eee;
}

.face-preview img,
.face-preview video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.face-status {
    margin-top: 10px;
    font-size: 0.9rem;
}

.face-status.success {
    color: var(--success-color);
}

.face-status.error {
    color: var(--danger-color);
}

/* 分頁樣式 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 5px;
    margin-top: 20px;
}

.pagination button {
    padding: 8px 12px;
    border: 1px solid var(--border-color);
    background: white;
    cursor: pointer;
    border-radius: 4px;
}

.pagination button:hover {
    background: var(--light-color);
}

.pagination button.active {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.pagination button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 篩選區域 */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 20px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.filter-bar .form-group {
    margin-bottom: 0;
    min-width: 150px;
}

/* 登入頁面 */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    width: 100%;
    max-width: 400px;
}

.login-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: var(--dark-color);
}

.login-box .form-group {
    margin-bottom: 20px;
}

.login-box .btn {
    width: 100%;
    padding: 12px;
    font-size: 1rem;
}

/* Badge 樣式 */
.badge {
    display: inline-block;
    padding: 3px 8px;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 4px;
}

.badge-success {
    background: #d4edda;
    color: #155724;
}

.badge-warning {
    background: #fff3cd;
    color: #856404;
}

.badge-danger {
    background: #f8d7da;
    color: #721c24;
}

.badge-info {
    background: #cce5ff;
    color: #004085;
}

.badge-secondary {
    background: #e9ecef;
    color: #495057;
}

/* 警告按鈕 */
.btn-warning {
    background: var(--warning-color);
    color: #212529;
}

.btn-warning:hover {
    background: #e0a800;
}

/* 資料表格樣式 */
.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.data-table th {
    background: var(--light-color);
    font-weight: 600;
    color: var(--dark-color);
}

.data-table tbody tr:hover {
    background: #f8f9fa;
}

.text-center {
    text-align: center;
}

/* 篩選表單 */
.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
}

.filter-form .form-group {
    margin-bottom: 0;
    min-width: 150px;
}

/* 表格響應式 */
.table-responsive {
    overflow-x: auto;
}

/* 公司 Logo 預覽 */
.company-logo {
    max-width: 150px;
    max-height: 150px;
    object-fit: contain;
}

/* 打卡頁面公司 Logo */
.punch-header .company-logo {
    max-width: 120px;
    max-height: 80px;
    margin-bottom: 15px;
}

/* Alert 樣式 */
.alert {
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-danger {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.alert-info {
    background: #cce5ff;
    color: #004085;
    border: 1px solid #b8daff;
}

/* 漢堡選單按鈕 */
.hamburger-btn {
    display: none;
    position: fixed;
    top: 15px;
    right: 15px;
    z-index: 1001;
    background: var(--dark-color);
    border: none;
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.hamburger-btn span {
    display: block;
    width: 24px;
    height: 3px;
    background: white;
    margin: 5px 0;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.hamburger-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.hamburger-btn.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* 側邊欄遮罩 */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}

.sidebar-overlay.show {
    display: block;
}

/* 匯出下拉選單 */
.export-dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 5px;
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    min-width: 160px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    z-index: 100;
    margin-top: 5px;
    overflow: hidden;
}

.dropdown-menu.show {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 12px 16px;
    color: #333;
    text-decoration: none;
    transition: background 0.2s ease;
}

.dropdown-menu a:hover {
    background: #f5f5f5;
}

.dropdown-menu a:first-child {
    border-bottom: 1px solid #eee;
}

/* 響應式設計 */
@media (max-width: 768px) {
    .hamburger-btn {
        display: block;
    }

    .sidebar {
        position: fixed;
        right: -280px;
        left: auto;
        width: 280px;
        height: 100vh;
        z-index: 1000;
        transition: right 0.3s ease;
    }

    .sidebar.show {
        right: 0;
    }

    .main-content {
        margin-left: 0;
        padding: 70px 15px 15px;
    }

    .admin-container {
        flex-direction: column;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .page-header h1 {
        font-size: 1.5rem;
    }

    .filter-bar,
    .filter-form {
        flex-direction: column;
    }

    .filter-form .form-group {
        width: 100%;
    }

    .form-row {
        flex-direction: column;
    }

    .form-row .form-group {
        width: 100%;
    }

    .table {
        display: block;
        overflow-x: auto;
    }

    .data-table {
        min-width: 600px;
    }

    .current-time {
        font-size: 1.8rem;
    }

    .card-body {
        padding: 15px;
    }

    .modal-content {
        width: 95%;
        margin: 10px;
    }

    .btn {
        padding: 10px 16px;
    }

    .btn-sm {
        padding: 6px 10px;
    }
}

/* 公司切換器樣式 */
.company-switcher {
    display: flex;
    align-items: center;
    gap: 8px;
}

.company-switcher select {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    background: rgba(255,255,255,0.1);
    color: #fff;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='white' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}

.company-switcher select:focus {
    outline: none;
    border-color: rgba(255,255,255,0.6);
}

.company-switcher select option {
    background: #2c3e50;
    color: #fff;
}

.btn-add-company {
    width: 32px;
    height: 32px;
    border: 1px dashed rgba(255,255,255,0.5);
    border-radius: 6px;
    background: transparent;
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.btn-add-company:hover {
    background: rgba(255,255,255,0.1);
    border-style: solid;
}

/* Modal 基本樣式增強 */
.modal .input-with-prefix {
    display: flex;
    align-items: center;
}

.modal .input-prefix {
    background: #e9ecef;
    border: 1px solid #ced4da;
    border-right: none;
    padding: 8px 12px;
    border-radius: 4px 0 0 4px;
    color: #495057;
    font-size: 14px;
    white-space: nowrap;
}

.modal .input-with-prefix .form-control {
    border-radius: 0 4px 4px 0;
}

/* 打卡選擇對話框 */
.punch-dialog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.punch-dialog {
    background: white;
    border-radius: 16px;
    padding: 30px;
    width: 90%;
    max-width: 360px;
    text-align: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.punch-dialog-header {
    margin-bottom: 20px;
}

.punch-dialog-greeting {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 5px;
}

.punch-dialog-name {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.punch-dialog-time {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--dark-color);
}

.punch-dialog-status {
    font-size: 0.95rem;
    color: #666;
    margin-bottom: 25px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 8px;
}

.punch-dialog-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
}

.punch-dialog-btn {
    flex: 1;
    padding: 15px 10px;
    font-size: 1.1rem;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.punch-dialog-btn small {
    font-size: 0.75rem;
    font-weight: normal;
    opacity: 0.8;
}

.punch-dialog-btn.primary {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.4);
}

.punch-dialog-btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.5);
}

.punch-dialog-btn.secondary {
    background: #f8f9fa;
    color: #495057;
    border: 2px solid #dee2e6;
}

.punch-dialog-btn.secondary:hover {
    background: #e9ecef;
    border-color: #ced4da;
}

.punch-dialog-btn.disabled {
    background: #e9ecef;
    color: #adb5bd;
    cursor: not-allowed;
    box-shadow: none;
}

.punch-dialog-btn.disabled:hover {
    transform: none;
}

.punch-dialog-close {
    width: 100%;
    padding: 12px;
    font-size: 1rem;
    font-weight: 500;
    background: transparent;
    color: #6c757d;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.punch-dialog-close:hover {
    background: #f8f9fa;
    color: #495057;
}

/* 響應式調整 */
@media (max-width: 400px) {
    .punch-dialog {
        padding: 20px;
    }

    .punch-dialog-name {
        font-size: 1.5rem;
    }

    .punch-dialog-time {
        font-size: 2rem;
    }

    .punch-dialog-btn {
        padding: 12px 8px;
        font-size: 1rem;
    }
}
