/* Flight Board Styles */
.flight-board-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 80px 0;
}

.flight-board-section .container {
    max-width: 1400px;
    width: 100%;
    padding: 0 20px;
}

.flight-board-section .section-heading {
    color: #212529 !important;
}

.flight-board-tabs {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    overflow: hidden;
    margin-bottom: 2rem;
}

.tab-buttons {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}

.tab-btn {
    flex: 1;
    padding: 20px 30px;
    background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    font-size: 20px;
    font-weight: 600;
    color: #6c757d;
    transition: all 0.3s ease;
    position: relative;
    text-transform: capitalize !important;
}

.tab-btn:hover {
    background: #e9ecef;
    color: #495057;
}

.tab-btn.active {
    background: #fff;
    color: #082971;
    border-bottom: 3px solid #082971;
}

.tab-btn i {
    font-size: 22px;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.flight-board-header {
    display: grid;
    grid-template-columns: 180px 280px 160px 240px 160px 1fr;
    gap: 24px;
    padding: 28px 32px;
    background: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
    font-weight: 700;
    font-size: 16px;
    color: #495057;
    text-transform: capitalize;
    letter-spacing: 0.3px;
    text-align: center;
}

/* Căn trái cho cột airline trong header */
.flight-board-header > div:nth-child(2) {
    text-align: left;
}

.flight-board-body {
    max-height: 600px;
    overflow-y: auto;
}

.flight-row {
    display: grid;
    grid-template-columns: 180px 280px 160px 240px 160px 1fr;
    gap: 24px;
    padding: 24px 32px;
    border-bottom: 1px solid #f1f3f4;
    cursor: pointer;
    transition: all 0.2s ease;
    align-items: center;
    text-align: center;
}

/* Căn trái cho cột airline trong các hàng dữ liệu */
.flight-row > div:nth-child(2) {
    text-align: left;
}

.flight-row2 {
    display: table-row;
}

.flight-row:hover {
    background: #f8f9fa;
/*    transform: translateX(4px);*/
}

.flight-time {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.planned-time {
    font-weight: 600;
    font-size: 18px;
    color: #212529;
}

.actual-time {
    font-size: 18px;
    color: #dc3545;
    font-weight: 500;
}

.flight-airline {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    text-align: left;
}

.airline-logo {
    width: 58px;
    height: 58px;
    object-fit: contain;
    border-radius: 4px;
}

.airline-name {
    font-weight: 500;
    color: #495057;
    font-size: 18px;
}

.flight-code {
    font-weight: 700;
    font-size: 20px;
    color: #212529;
    font-family: 'Courier New', monospace;
}

.flight-from, .flight-to {
    font-weight: 500;
    color: #495057;
    font-size: 18px;
}

.flight-status {
    display: flex;
    justify-content: center;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.status-on-time {
    background: #d4edda;
    color: #155724;
}

.status-delayed {
    background: #f8d7da;
    color: #721c24;
}

.status-boarding {
    background: #d1ecf1;
    color: #0c5460;
}

.status-departed {
    background: #e2e3e5;
    color: #383d41;
}

.status-arrived {
    background: #d4edda;
    color: #155724;
}

.status-cancelled {
    background: #f8d7da;
    color: #721c24;
}

.status-unknown {
    background: #e2e3e5;
    color: #6c757d;
}

.flight-baggage, .flight-gate {
    font-weight: 600;
    color: #495057;
    text-align: center;
    font-size: 18px;
}

.no-flights {
    text-align: center;
    padding: 60px 30px;
    color: #6c757d;
}

.no-flights i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.no-flights p {
    font-size: 18px;
    margin: 0;
}

/* Refresh Button - Simple Design */
.refresh-flights-btn {
    background: none;
    border: none;
    color: #6c757d;
    cursor: pointer;
    padding: 6px;
    border-radius: 4px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    outline: none;
    margin: 0;
}

.refresh-flights-btn:hover {
    background-color: #f8f9fa;
    color: #082971;
    transform: scale(1.1);
}

.refresh-flights-btn:active {
    transform: scale(0.95);
}

.refresh-flights-btn:focus {
    outline: 2px solid #082971;
    outline-offset: 2px;
}

.refresh-flights-btn i {
    font-size: 12px;
}

.refresh-flights-btn.loading i {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Responsive refresh button */
@media (max-width: 768px) {
    .refresh-flights-btn {
        width: 22px;
        height: 22px;
        padding: 4px;
    }
    
    .refresh-flights-btn i {
        font-size: 11px;
    }
    
    .last-updated {
        font-size: 11px;
        gap: 6px;
    }
}

@media (max-width: 576px) {
    .refresh-flights-btn {
        width: 20px;
        height: 20px;
        padding: 3px;
    }
    
    .refresh-flights-btn i {
        font-size: 10px;
    }
    
    .last-updated {
        font-size: 10px;
        gap: 5px;
    }
}

.last-updated {
    margin-top: 0;
    font-size: 12px;
    text-align: center;
    color: #6c757d;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Responsive Design */
@media (max-width: 1400px) {
    .flight-board-section .container {
        max-width: 1200px;
        padding: 0 15px;
    }
    
    .flight-board-header,
    .flight-row {
        grid-template-columns: 160px 260px 140px 200px 140px 1fr;
        gap: 20px;
        padding: 20px 24px;
    }
}

@media (max-width: 1200px) {
    .flight-board-header,
    .flight-row {
        grid-template-columns: 120px 200px 120px 160px 100px 1fr;
        gap: 16px;
        padding: 18px 25px;
    }

    .flight-board-header {
        font-size: 14px;
    }

    .planned-time {
        font-size: 18px;
    }

    .flight-code {
        font-size: 18px;
    }

    .airline-name {
        font-size: 16px;
    }

    .flight-from, .flight-to {
        font-size: 16px;
    }
}

@media (max-width: 992px) {
    .flight-board-section {
        padding: 30px 0;
    }
    
    .flight-board-header,
    .flight-row {
        grid-template-columns: 100px 180px 100px 150px 80px 1fr;
        gap: 12px;
        padding: 16px 20px;
    }
    
    .flight-board-header {
        font-size: 13px;
    }
    
    .planned-time {
        font-size: 16px;
    }
    
    .flight-code {
        font-size: 16px;
    }
    
    .airline-name {
        font-size: 14px;
    }
    
    .flight-from, .flight-to {
        font-size: 14px;
    }
}

/* Responsive for 768px to 793px - Show full table without horizontal scroll */
@media (min-width: 768px) and (max-width: 793px) {
    .flight-board-section .container {
        max-width: 100%;
        padding: 0 8px;
        overflow-x: hidden;
    }
    
    .flight-board-tabs {
        transform: scale(0.8);
        transform-origin: top center;
        margin-bottom: 0.8rem;
    }
    
    .flight-board-header,
    .flight-row {
        grid-template-columns: 80px 180px 80px 140px 70px 1fr;
        gap: 6px;
        padding: 10px 12px;
        font-size: 11px;
        min-width: 0;
    }
    
    .flight-board-header {
        font-size: 10px;
        font-weight: 600;
    }
    
    .planned-time {
        font-size: 13px;
    }
    
    .flight-code {
        font-size: 13px;
    }
    
    .airline-name {
        font-size: 11px;
    }
    
    .flight-from, .flight-to {
        font-size: 11px;
    }
    
    .status-badge {
        font-size: 9px;
        padding: 3px 6px;
    }
    
    .flight-baggage, .flight-gate {
        font-size: 11px;
    }
    
    .tab-btn {
        padding: 10px 14px;
        font-size: 13px;
        gap: 5px;
    }
    
    .tab-btn i {
        font-size: 15px;
    }
}

/* Responsive for 794px to 843px - Show full table but scaled down */
@media (min-width: 794px) and (max-width: 843px) {
    .flight-board-section .container {
        max-width: 100%;
        padding: 0 10px;
    }
    
    .flight-board-tabs {
        transform: scale(0.85);
        transform-origin: top center;
        margin-bottom: 1rem;
    }
    
    .flight-board-header,
    .flight-row {
        grid-template-columns: 100px 200px 100px 150px 80px 1fr;
        gap: 8px;
        padding: 12px 16px;
        font-size: 12px;
    }
    
    .flight-board-header {
        font-size: 11px;
        font-weight: 600;
    }
    
    .planned-time {
        font-size: 14px;
    }
    
    .flight-code {
        font-size: 14px;
    }
    
    .airline-name {
        font-size: 12px;
    }
    
    .flight-from, .flight-to {
        font-size: 12px;
    }
    
    .status-badge {
        font-size: 10px;
        padding: 4px 8px;
    }
    
    .flight-baggage, .flight-gate {
        font-size: 12px;
    }
    
    .tab-btn {
        padding: 12px 16px;
        font-size: 14px;
        gap: 6px;
    }
    
    .tab-btn i {
        font-size: 16px;
    }
}

@media (max-width: 767px) {
    .flight-board-section {
        padding: 40px 0;
    }

    .tab-btn {
        padding: 16px 20px;
        font-size: 16px;
        gap: 8px;
    }

    .tab-btn i {
        font-size: 18px;
    }

    .flight-board-header {
        display: none;
    }

    .flight-row {
        display: block;
        padding: 20px;
        margin-bottom: 12px;
        background: #fff;
        border-radius: 8px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
        position: relative;
    }

    .flight-row:hover {
        transform: none;
        box-shadow: 0 4px 16px rgba(0,0,0,0.15);
    }

    /* Mobile Flight Info Layout - Incheon Style */
    .flight-row .flight-time {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 16px;
        padding-bottom: 12px;
        border-bottom: 1px solid #e9ecef;
    }

    .flight-row .planned-time {
        font-size: 24px;
        font-weight: 700;
        color: #000;
    }

    .flight-row .actual-time {
        font-size: 18px;
        color: #6c757d;
        font-weight: 500;
    }

    .flight-row .flight-airline {
        display: flex;
        align-items: center;
        margin-bottom: 16px;
    }

    .flight-row .airline-logo {
        width: 32px;
        height: 32px;
        margin-right: 12px;
        border-radius: 4px;
    }

    .flight-row .airline-name {
        font-size: 16px;
        font-weight: 600;
        color: #000;
    }

    .flight-row .flight-code {
        font-size: 18px;
        font-weight: 700;
        color: #000;
        margin-bottom: 16px;
    }

    .flight-row .flight-from, 
    .flight-row .flight-to {
        display: block;
        margin-bottom: 8px;
        font-size: 16px;
        color: #495057;
    }

    .flight-row .flight-baggage, 
    .flight-row .flight-gate {
        display: block;
        margin-bottom: 8px;
        font-size: 16px;
        color: #495057;
        font-weight: 600;
    }

    .flight-row .flight-status {
        position: absolute;
        top: 20px;
        right: 20px;
        margin: 0;
    }

    .flight-row .status-badge {
        padding: 6px 12px;
        border-radius: 20px;
        font-size: 14px;
        font-weight: 600;
    }

    /* Mobile Flight Info Layout - Incheon Style */
    .flight-row .flight-info-mobile {
        display: block;
        margin-top: 16px;
    }

    .flight-row .flight-info-item {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 12px;
        padding: 8px 0;
        border-bottom: 1px solid #f1f3f4;
    }

    .flight-row .flight-info-item:last-child {
        border-bottom: none;
        margin-bottom: 0;
    }

    .flight-row .flight-info-label {
        font-size: 14px;
        color: #6c757d;
        font-weight: 500;
        flex: 0 0 auto;
        margin-right: 16px;
    }

    .flight-row .flight-info-value {
        font-size: 16px;
        color: #000;
        font-weight: 600;
        flex: 1;
        text-align: right;
        display: flex;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
    }

    .airline-logo-mobile {
        width: 36px;
        height: 36px;
        object-fit: contain;
        border-radius: 3px;
    }

    /* Specific styling for different flight types */
    .flight-row[data-flight-type="arrival"] .flight-info-mobile {
        display: block;
    }

    .flight-row[data-flight-type="departure"] .flight-info-mobile {
        display: block;
    }
}

/* Custom scrollbar */
.flight-board-body::-webkit-scrollbar {
    width: 8px;
}

.flight-board-body::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.flight-board-body::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.flight-board-body::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* View More Button Styling */
.view-more-section {
    padding: 20px 0;
    border-top: 1px solid #dee2e6;
    background: #f8f9fa;
}

.view-more-section .btn {
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s ease;
    background-color: #082971;
    border-color: #082971;
    color: white;
    box-shadow: none;
}

.view-more-section .btn:hover {
    transform: translateY(-4px) scale(1.05);
    background-color: #082971;
    border-color: #082971;
    color: white;
    box-shadow: none;
}
