body { font-family: 'Cairo', sans-serif; }

.nav-link {
    display: block;
    padding: 0.7rem 0.9rem;
    border-radius: 0.75rem;
    color: rgba(255,255,255,0.86);
    font-size: 0.95rem;
}
.nav-link:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav-active { background: rgba(255,255,255,0.14); color: #fff; font-weight: 700; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    min-height: 2.75rem;
    padding: 0.55rem 1rem;
    border-radius: 0.8rem;
    font-weight: 600;
    font-size: 0.95rem;
    transition: 0.15s ease;
}
.btn-primary { background: #0f766e; color: #fff; }
.btn-primary:hover { background: #115e59; }
.btn-secondary { background: #fff; color: #0f766e; border: 1px solid #99f6e4; }
.btn-secondary:hover { background: #f0fdfa; }
.btn-danger { background: #be123c; color: #fff; }
.btn-danger:hover { background: #9f1239; }
.btn-ghost { background: #f8fafc; color: #334155; border: 1px solid #e2e8f0; }

.card { background: #fff; border: 1px solid #e2e8f0; border-radius: 1rem; }

.form-label { display: block; margin-bottom: 0.35rem; font-weight: 600; font-size: 0.9rem; }
.form-input, .form-select, textarea.form-input {
    width: 100%;
    min-height: 2.85rem;
    border: 1px solid #cbd5e1;
    border-radius: 0.8rem;
    padding: 0.55rem 0.85rem;
    background: #fff;
    font-size: 1rem;
}
.form-input:focus, .form-select:focus, textarea.form-input:focus {
    outline: none;
    border-color: #0d9488;
    box-shadow: 0 0 0 3px rgba(13,148,136,0.15);
}

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th { text-align: right; background: #f8fafc; color: #475569; font-size: 0.8rem; padding: 0.75rem; border-bottom: 1px solid #e2e8f0; }
.data-table td { padding: 0.8rem 0.75rem; border-bottom: 1px solid #f1f5f9; vertical-align: top; }

.qr-box { background: #fff; padding: 0.75rem; border-radius: 1rem; border: 1px solid #e2e8f0; display: inline-block; }
.qr-box img { display: block; width: 220px; height: 220px; object-fit: contain; }

#sidebar.open { transform: translateX(0); }

div.dt-container { font-family: 'Cairo', sans-serif; }
div.dt-container .dt-search input,
div.dt-container .dt-length select {
    border: 1px solid #cbd5e1;
    border-radius: 0.7rem;
    padding: 0.4rem 0.7rem;
    min-height: 2.4rem;
}
div.dt-container .dt-paging .dt-paging-button {
    border-radius: 0.6rem !important;
}

.pwa-install-banner {
    position: fixed;
    z-index: 60;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    background: #115e59;
    color: #fff;
    border-radius: 1.25rem;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.25);
    padding: 1rem 1.15rem;
}
.pwa-install-banner.hidden { display: none !important; }
@media (min-width: 640px) {
    .pwa-install-banner {
        right: auto;
        width: 22rem;
    }
}
table.dataTable thead th { text-align: right; }

.add-tab {
    padding: 0.95rem 1rem;
    font-weight: 700;
    color: #64748b;
    background: #f8fafc;
}
.add-tab:hover { color: #0f766e; background: #f0fdfa; }
.add-tab-active {
    color: #0f766e;
    background: #fff;
    box-shadow: inset 0 -3px 0 #0f766e;
}

.scan-frame {
    position: relative;
    min-height: 260px;
    border: 2px dashed #99f6e4;
    border-radius: 1.1rem;
    background: #f8fafc;
    overflow: hidden;
}
.scan-placeholder {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #64748b;
    pointer-events: none;
}
