/* ==========================================================================
   native-app.css — अवनि App ko native app jaisa feel dene ke liye
   Sirf additive styles: existing design ko nahi badalta.
   ========================================================================== */

/* Phone ki font-size setting / double-tap zoom se layout na hile */
html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    touch-action: manipulation;
}

/* Images drag na ho (app jaisa) */
img {
    -webkit-user-drag: none;
}

/* Button dabane par turant feedback (native ripple jaisa) */
.btn:active,
button:active,
[role="button"]:active,
input[type="submit"]:active,
input[type="button"]:active {
    filter: brightness(.92);
}

/* Browser me link dabate hi upar patli progress line
   (App me Flutter apni progress line dikhata hai) */
#avni-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0;
    background: linear-gradient(90deg, #5D5FEF, #7C5CF5);
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: width .4s ease, opacity .3s ease;
}
#avni-progress.active {
    opacity: 1;
}

/* ==========================================================================
   Ek jaisa rang poori app me — app ka primary purple (header / bottom menu)
   Pehle kahin blue (Bootstrap / SweetAlert default), kahin orange, kahin teal tha.
   ========================================================================== */
:root {
    --avni-primary: #5D5FEF;
    --avni-primary-2: #7C5CF5;
    --avni-primary-dark: #4547D7;
}

.btn-primary,
.btn-primary:focus {
    background: linear-gradient(135deg, var(--avni-primary) 0%, var(--avni-primary-2) 100%) !important;
    border-color: var(--avni-primary) !important;
    color: #fff !important;
}
.btn-primary:hover,
.btn-primary:active {
    background: var(--avni-primary-dark) !important;
    border-color: var(--avni-primary-dark) !important;
}

/* SweetAlert ka "ठीक है / हाँ" button (inline confirmButtonColor ko bhi override) */
.swal2-styled.swal2-confirm {
    background: var(--avni-primary) !important;
    border-color: var(--avni-primary) !important;
    box-shadow: none !important;
}

/* Sahayata chitra / info popups ka header (pehle teal bg-info tha) */
.modal-header.bg-info {
    background: linear-gradient(135deg, var(--avni-primary) 0%, var(--avni-primary-2) 100%) !important;
    color: #fff !important;
}

/* Form ke (i) sahayata buttons — pehle laal the (galti jaisa lagta tha) */
.info-btn,
.info-btn.btn-outline-info {
    color: var(--avni-primary) !important;
    border-color: var(--avni-primary) !important;
    background-color: transparent !important;
}
.info-btn:active,
.info-btn:hover {
    color: #fff !important;
    background-color: var(--avni-primary) !important;
}

/* Popup ka "समझ गया" button bhi app ke rang me */
.modal-footer .btn-secondary[data-bs-dismiss="modal"] {
    background: var(--avni-primary) !important;
    border-color: var(--avni-primary) !important;
    color: #fff !important;
    padding: 6px 22px;
    border-radius: 10px;
}

/* Upar ka page title scroll karte waqt sawalon ke upar na chadhe */
.learning-main-header {
    background-color: #ffffff !important;
    box-shadow: 0 2px 12px rgba(35, 39, 73, .06);
}

/* Template ka theme-color (orange tha) → app ka purple. Isse template ke
   saare buttons / links / highlights ek hi rang me aa jaate hain. */
body.learning {
    --theme-color: 93, 95, 239;
}
