/* GetYourTutorsHub — Custom Styles */

/* ===== Navigation Links ===== */
.nav-link {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: #4b5563;
    transition: all 0.15s ease;
}
.nav-link:hover {
    background-color: #f3f4f6;
    color: #111827;
}
.nav-link.active {
    background-color: #eff6ff;
    color: #2563eb;
}
.nav-link.active svg {
    color: #2563eb;
}

/* ===== Bottom Navigation (Tutor Mobile) ===== */
.bottom-nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    transition: color 0.15s ease;
}
.bottom-nav-link:hover,
.bottom-nav-link.active {
    color: #2563eb;
}
.bottom-nav-link.active {
    color: #2563eb;
}

/* ===== Flash Messages ===== */
.flash-message {
    animation: flashIn 0.3s ease-out;
}
@keyframes flashIn {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Auto-dismiss flash messages */
.flash-message {
    animation: flashIn 0.3s ease-out, flashOut 0.3s ease-in 4.7s forwards;
}
@keyframes flashOut {
    from { opacity: 1; max-height: 100px; margin-bottom: 0.5rem; }
    to   { opacity: 0; max-height: 0; margin-bottom: 0; padding-top: 0; padding-bottom: 0; overflow: hidden; }
}

/* ===== Loading State on Buttons ===== */
.btn-loading {
    position: relative;
}
.btn-loading.is-loading {
    color: transparent !important;
    pointer-events: none;
}
.btn-loading.is-loading::after {
    content: '';
    position: absolute;
    width: 1.25rem;
    height: 1.25rem;
    top: 50%;
    left: 50%;
    margin-left: -0.625rem;
    margin-top: -0.625rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===== Form Focus Styles ===== */
input:focus, select:focus, textarea:focus {
    outline: none;
}

/* ===== Table Responsive ===== */
@media (max-width: 640px) {
    .overflow-x-auto {
        -webkit-overflow-scrolling: touch;
    }
}

/* ===== Tutor Desktop Layout ===== */
@media (min-width: 640px) {
    .pb-20.sm\:pb-0 main.max-w-4xl {
        margin-left: 14rem;
    }
}

/* ===== Smooth Transitions ===== */
* {
    -webkit-tap-highlight-color: transparent;
}

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

/* ===== Modal / Overlay ===== */
.modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: fadeIn 0.2s ease-out;
}
.modal-content {
    background: white;
    border-radius: 0.75rem;
    max-width: 28rem;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.2s ease-out;
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(1rem); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ===== File Drop Zone ===== */
#drop-zone.drag-over {
    border-color: #2563eb;
    background-color: #eff6ff;
}

/* ===== Proof Upload Cards ===== */
.proof-card {
    transition: border-color 0.2s ease, background-color 0.2s ease;
}
.proof-card.border-red-300 {
    animation: proofShake 0.4s ease;
}
@keyframes proofShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}
.proof-upload-area {
    min-height: 80px;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}
.proof-thumb {
    object-fit: cover;
    max-width: 100%;
}
#proof-cards-container::-webkit-scrollbar {
    width: 4px;
}
#proof-cards-container::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 2px;
}
