:root {
    --bg-color: #0d1117;
    --glass-bg: rgba(22, 27, 34, 0.65);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-primary: #f0f6fc;
    --text-secondary: #8b949e;
    --primary-color: #238636;
    --primary-hover: #2ea043;
    --secondary-color: #8957e5;
    --secondary-hover: #9e6cf2;
    --accent-color: #388bfd;
    --danger-color: #da3633;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
    overscroll-behavior-y: none;
}

.background-orbs {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: -1;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    animation: float 20s infinite alternate;
}

.orb-1 {
    width: 400px;
    height: 400px;
    background: #004d80;
    top: -100px;
    left: -100px;
    animation-delay: 0s;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: #4a1c6a;
    bottom: -150px;
    right: -100px;
    animation-delay: -5s;
}

.orb-3 {
    width: 300px;
    height: 300px;
    background: #104832;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation-delay: -10s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(50px, 50px) scale(1.1);
    }
}

.glass-container {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    width: 90%;
    max-width: 900px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    margin: 40px 0;
}

header {
    text-align: center;
    margin-bottom: 40px;
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #79c0ff, #d2a8ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.time-display {
    font-size: 3.5rem;
    font-weight: 300;
    letter-spacing: 2px;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

.date-display {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-top: 5px;
}

/* Employee Grid */
.employee-section {
    margin-bottom: 40px;
}

.employee-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

h2 {
    font-size: 1.5rem;
    font-weight: 600;
}

.employee-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 16px;
}

.emp-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 24px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.emp-card:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-3px);
}

.emp-card:active {
    transform: scale(0.95);
}

.emp-name {
    font-size: 1.4rem;
    font-weight: 600;
}

.emp-status {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

.status-indicator-in {
    background: rgba(35, 134, 54, 0.2);
    color: #46c85b;
    box-shadow: 0 0 10px rgba(70, 200, 91, 0.2);
}

.status-indicator-out {
    background: rgba(137, 87, 229, 0.2);
    color: #b392f0;
}

.btn {
    padding: 14px 24px;
    font-size: 1.1rem;
    font-weight: 600;
    font-family: inherit;
    color: #ffffff;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn:active {
    transform: scale(0.96);
}

.primary-btn {
    background: var(--primary-color);
    box-shadow: 0 4px 14px rgba(35, 134, 54, 0.4);
}

.primary-btn:hover {
    background: var(--primary-hover);
}

.secondary-btn {
    background: var(--secondary-color);
    box-shadow: 0 4px 14px rgba(137, 87, 229, 0.4);
}

.secondary-btn:hover {
    background: var(--secondary-hover);
}

.outline-btn {
    background: transparent;
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    font-size: 0.95rem;
    padding: 10px 16px;
}

.outline-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.action-btn {
    background: rgba(255, 255, 255, 0.1);
    font-size: 0.95rem;
    padding: 10px 16px;
    border: 1px solid var(--glass-border);
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal.active {
    opacity: 1;
    pointer-events: all;
}

.modal-content {
    background: var(--bg-color);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    width: 90%;
    max-width: 420px;
    text-align: center;
    transform: translateY(30px) scale(0.95);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
}

.modal.active .modal-content {
    transform: translateY(0) scale(1);
}

.modal-title {
    margin-bottom: 10px;
    font-size: 2.2rem;
    color: white;
    display: block;
}

.modal-subtitle {
    color: var(--text-secondary);
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.modal-btn {
    width: 100%;
    padding: 20px;
    font-size: 1.3rem;
    border-radius: 16px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.close-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.large-input {
    width: 100%;
    padding: 20px;
    font-size: 1.5rem;
    border-radius: 16px;
    text-align: center;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--glass-border);
    color: white;
    outline: none;
    font-family: inherit;
    transition: all 0.3s ease;
}

.large-input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(56, 139, 253, 0.3);
}

/* Toast */
.toast {
    position: fixed;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%) translateY(150px);
    color: white;
    padding: 16px 32px;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 600;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 2000;
    opacity: 0;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.toast-success {
    background: var(--primary-color);
    box-shadow: 0 10px 30px rgba(35, 134, 54, 0.5);
    border: 1px solid #2ea043;
}

.toast-error {
    background: var(--danger-color);
    box-shadow: 0 10px 30px rgba(218, 54, 51, 0.5);
    border: 1px solid #f85149;
}

.mt-20 {
    margin-top: 20px;
}

.mt-40 {
    margin-top: 40px;
}

/* Records Section */
.records-section {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 16px;
    padding: 24px;
    border: 1px solid var(--glass-border);
}

.records-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

th,
td {
    padding: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    white-space: nowrap;
}

th {
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

tbody tr {
    transition: background 0.2s ease;
}

tbody tr:hover {
    background: rgba(255, 255, 255, 0.03);
}

.status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.status-in {
    background: rgba(35, 134, 54, 0.2);
    color: #46c85b;
}

.status-out {
    background: rgba(137, 87, 229, 0.2);
    color: #b392f0;
}

.delete-btn {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.9rem;
    transition: color 0.2s;
    padding: 4px;
}

.delete-btn:hover {
    color: var(--danger-color);
}

@media (max-width: 600px) {
    .glass-container {
        padding: 24px 20px;
        border-radius: 0;
        border: none;
        border-bottom: 1px solid var(--glass-border);
        width: 100%;
        margin: 0;
        min-height: 100vh;
    }

    .employee-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .emp-card {
        padding: 20px 10px;
    }

    .records-header {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    .modal-content {
        width: 95%;
        padding: 30px 20px;
    }

    .modal-btn {
        padding: 16px;
    }
}