﻿:root {
    --byd-red: #FF0000;
    --byd-red-soft: #ff3333;
    --byd-blue: #0000FF;
    --byd-black: #000000;
    --byd-dark-gray: #333333;
    --byd-light-gray: #F5F5F5;
    --byd-white: #FFFFFF;
    --transition-speed: 0.3s;
}

html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

/* Media query cho điện thoại */
@media (max-width: 768px) {
    .camera-container {
        width: 100%;
        max-width: 100%;
        aspect-ratio: 3/4; /* Tỉ lệ dọc cho điện thoại */
    }
}

body {
    margin-bottom: 60px;
    background-color: var(--byd-white);
    color: var(--byd-dark-gray);
    font-family: 'Segoe UI', Arial, sans-serif;
}

.bydtitle {
    border-radius: 8px;
}

.dropdown-menu {
    background-color: var(--byd-white);
    border: none;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    padding: 0.5rem;
    margin-top: 10px;
}

.dropdown-item {
    color: var(--byd-black) !important;
    border-radius: 10px;
    padding: 0.7rem 1.2rem;
    transition: all var(--transition-speed) ease;
}

.dropdown-item:hover {
    background-color: var(--byd-red-soft);
    color: var(--byd-white) !important;
    transform: translateX(5px);
}

/* Button styling */
.btn-primary {
    background-color: var(--byd-blue);
    border: none;
    border-radius: 25px;
    padding: 0.8rem 1.5rem;
    transition: all var(--transition-speed) ease;
    box-shadow: 0 4px 15px rgba(255,0,0,0.2);
}

.btn-primary:hover {
    background-color: var(--byd-red-soft);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255,0,0,0.3);
}

/* Focus states */
.btn:focus, 
.btn:active:focus, 
.btn-link.nav-link:focus, 
.form-control:focus, 
.form-check-input:focus {
    box-shadow: 0 0 0 0.2rem rgba(255,0,0,0.2);
}

/* Footer styling */
.footer {
    background-color: var(--byd-dark-gray);
    color: var(--byd-white) !important;
    border-top: none !important;
    padding: 0.2rem 0;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--byd-red), transparent);
}

/* Table styling */
.table {
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.table thead th {
    background-color: var(--byd-black);
    color: var(--byd-white);
    border: none;
    padding: 1rem;
}

.table tbody tr {
    transition: all var(--transition-speed) ease;
}

.table tbody tr:hover {
    background-color: rgba(255,0,0,0.05);
}

/* Card styling */
.card {
    border: none;
    border-radius: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: all var(--transition-speed) ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.card-header {
    background-color: var(--byd-black);
    color: var(--byd-white);
    border-radius: 20px 20px 0 0 !important;
    padding: 1rem 1.5rem;
}

/* Form controls */
.form-control {
    border-radius: 15px;
    border: 2px solid var(--byd-light-gray);
    padding: 0.8rem 1.2rem;
    transition: all var(--transition-speed) ease;
}

.form-control:focus {
    border-color: var(--byd-red);
    box-shadow: 0 0 0 0.2rem rgba(255,0,0,0.1);
}

/* Custom animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn var(--transition-speed) ease;
}

body.remote-attendance-bg {
    background-color: white;
}

/* Container cho video/ảnh */
.camera-container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
}

/* Style cho video, canvas và ảnh */
#video, #canvas, #photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    top: 0;
    left: 0;
}
