:root {
    --red: #c2272d;
    --red-soft: #e88a8e;
    --red-dark: #a81f24;
    --red-tint: #fceeee;
    --red-deep: #8b1a1f;
    --black: #1a1a1a;
    --grey: #6b6b6b;
    --grey-light: #e8e8e8;
    --grey-mid: #d0d0d0;
    --white: #ffffff;
    --charcoal: #2c2c2c;
    --note-bg: #fff8e7;
    --note-border: #f0d78c;
    --note-text: #8a7340;
}

* {
    box-sizing: border-box;
    scrollbar-width: thin;
    scrollbar-color: #c96a72 transparent;
}

    *::-webkit-scrollbar {
        width: 10px;
        height: 10px;
    }

    *::-webkit-scrollbar-track {
        background: transparent;
    }

    *::-webkit-scrollbar-thumb {
        background-color: #c96a72;
        border-radius: 999px;
        border: 4px solid transparent;
        background-clip: content-box;
    }

        *::-webkit-scrollbar-thumb:hover {
            background-color: #c2272d;
        }

    *::-webkit-scrollbar-corner {
        background: transparent;
    }

    *::-webkit-scrollbar-button {
        display: none;
        width: 0;
        height: 0;
    }

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    min-height: 100dvh;
    font-family: "Plus Jakarta Sans", "Poppins", sans-serif;
    color: var(--grey);
    overflow-x: hidden;
}

.portal-page {
    min-height: 100vh;
    min-height: 100dvh;
    max-height: 100vh;
    max-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    padding: max(32px, env(safe-area-inset-top)) max(20px, env(safe-area-inset-right)) max(32px, env(safe-area-inset-bottom)) max(20px, env(safe-area-inset-left));
    overflow: auto;
    box-sizing: border-box;
    background: linear-gradient(rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.72)), url("../images/campus-bg.png") center / cover no-repeat fixed;
}

.portal-card {
    width: 100%;
    max-width: 980px;
    max-height: calc(100vh - 64px);
    background: transparent;
    border-radius: 16px;
    overflow: visible;
    filter: drop-shadow(0 20px 50px rgba(0, 0, 0, 0.35));
}

    .portal-card > .row {
        max-height: calc(100vh - 64px);
        border-radius: 16px;
        overflow: hidden;
    }

/* ===== Left panel — glass blur ===== */
.portal-info {
    min-height: 560px;
    height: 100%;
    max-height: calc(100vh - 64px);
    padding: 40px 42px;
    display: flex;
    flex-direction: column;
    color: var(--white);
    position: relative;
    isolation: isolate;
    overflow-y: auto;
    background: linear-gradient( 160deg, rgba(45, 45, 45, 0.55) 0%, rgba(70, 40, 45, 0.5) 45%, rgba(120, 30, 40, 0.55) 100% );
    backdrop-filter: blur(18px) saturate(1.2);
    -webkit-backdrop-filter: blur(18px) saturate(1.2);
    border-right: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 36px;
}

.brand-icon {
    height: 72px;
    width: auto;
    border-radius: 8px;
    background: transparent;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    padding: 0;
    box-sizing: border-box;
    box-shadow: none;
}

    .brand-icon img {
        height: 100%;
        width: auto;
        max-width: 100%;
        display: block;
        object-fit: contain;
    }

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-name {
    font-size: 22px;
    font-weight: 700;
    color: var(--white);
}

.brand-tag {
    font-size: 13px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 2px;
}

.portal-heading {
    margin: 0 0 14px;
    font-size: 28px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--white);
}

.portal-desc {
    margin: 0 0 36px;
    font-size: 14px;
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.88);
    max-width: 420px;
}

.feature-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.feature-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--red);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

    .feature-icon svg {
        width: 18px;
        height: 18px;
        color: var(--white);
    }

.feature-item strong {
    display: block;
    font-size: 15px;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 3px;
}

.feature-item span:last-child {
    display: block;
    font-size: 12.5px;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.75);
}

/* ===== Right panel — form ===== */
.portal-form {
    min-height: 560px;
    height: 100%;
    max-height: calc(100vh - 64px);
    padding: 44px 40px 30px;
    display: flex;
    flex-direction: column;
    position: relative;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(24px) saturate(1.2);
    -webkit-backdrop-filter: blur(24px) saturate(1.2);
    border-left: 1px solid rgba(255, 255, 255, 0.5);
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.login-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 30px;
    padding: 4px;
    background: #f4f4f5;
    border: 1px solid #e8e8ea;
    border-radius: 10px;
}

.login-tab {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: none;
    background: transparent;
    color: #6b6b70;
    font-size: 12px;
    font-weight: 600;
    padding: 11px 10px;
    border-radius: 7px;
    cursor: pointer;
    line-height: 1.25;
    transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

    .login-tab svg {
        width: 14px;
        height: 14px;
        flex-shrink: 0;
        opacity: 0.85;
    }

    .login-tab.active {
        background: var(--white);
        color: var(--red);
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.04);
    }

        .login-tab.active svg {
            opacity: 1;
        }

    .login-tab:not(.active):hover {
        color: #333338;
        background: rgba(255, 255, 255, 0.55);
    }

.tab-panel {
    display: none;
}

    .tab-panel.active {
        display: block;
    }

.field {
    margin-bottom: 18px;
}

    .field label {
        display: block;
        margin-bottom: 7px;
        font-size: 12.5px;
        font-weight: 600;
        letter-spacing: 0.01em;
        color: #3a3a3a;
    }

.input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 13px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    color: #9a9a9a;
    pointer-events: none;
    z-index: 1;
}

    .input-icon svg {
        width: 17px;
        height: 17px;
    }

.boxed-input {
    height: 46px;
    border: 1px solid #e2e2e5;
    border-radius: 8px;
    background: #fafafa;
    box-shadow: none !important;
    padding: 10px 14px 10px 42px;
    color: #1a1a1a;
    font-size: 14px;
    transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.password-wrap .boxed-input {
    padding-right: 42px;
}

.boxed-input::placeholder {
    color: #a8a8a8;
}

.boxed-input:hover {
    border-color: #d0d0d4;
    background: #ffffff;
}

.boxed-input:focus {
    border-color: var(--red);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(194, 39, 45, 0.08) !important;
}

.toggle-password {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #9a9a9a;
    padding: 0;
    border-radius: 6px;
}

    .toggle-password:hover {
        color: var(--charcoal);
        background: #f0f0f0;
    }

    .toggle-password svg {
        width: 17px;
        height: 17px;
    }

.btn-login,
.capture-link {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 8px;
    height: 50px;
    padding: 0 24px;
    border: none;
    border-radius: 999px;
    background: linear-gradient(180deg, #d4363c 0%, #a81f24 100%);
    color: var(--white);
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: background 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease, transform 0.15s ease;
    box-shadow: 0 8px 22px rgba(194, 39, 45, 0.35);
}

    .btn-login svg,
    .capture-link svg {
        width: 16px;
        height: 16px;
        opacity: 0.95;
    }

    .btn-login:hover,
    .btn-login:focus,
    .capture-link:hover,
    .capture-link:focus {
        background: linear-gradient(180deg, #dc4046 0%, #a81f24 100%);
        color: var(--white);
        filter: brightness(1.02);
        transform: translateY(-1px);
        box-shadow: 0 10px 26px rgba(194, 39, 45, 0.42);
    }

    .btn-login:active,
    .capture-link:active {
        filter: brightness(0.97);
        transform: translateY(0);
        box-shadow: 0 4px 14px rgba(194, 39, 45, 0.28);
    }

.capture-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin-top: 8px;
}

    .capture-actions .capture-link {
        align-self: flex-end;
        width: auto;
        min-width: 0;
        height: auto;
        margin-top: 0;
        padding: 0;
        border: none;
        border-radius: 0;
        background: none;
        box-shadow: none;
        color: var(--red);
        font-size: 13px;
        font-weight: 600;
        gap: 6px;
        filter: none;
    }

        .capture-actions .capture-link svg {
            width: 15px;
            height: 15px;
            color: var(--red);
            opacity: 1;
        }

        .capture-actions .capture-link:hover,
        .capture-actions .capture-link:focus {
            background: none;
            color: var(--red-dark);
            filter: none;
            box-shadow: none;
            text-decoration: underline;
        }

        .capture-actions .capture-link:active {
            filter: none;
            box-shadow: none;
        }

    .capture-actions .btn-login {
        flex: none;
        width: 100%;
        margin-top: 0;
    }

.capture-link-row {
    display: flex;
    margin: 0 0 4px;
}

.capture-link {
    margin-top: 0;
}

@media (max-width: 420px) {
    .capture-actions .capture-link {
        align-self: flex-start;
    }
}

.form-links {
    text-align: center;
    margin-top: 14px;
}

.quit-link {
    font-size: 12.5px;
    color: #8a8a8a;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease;
}

    .quit-link:hover {
        text-decoration: none;
        color: var(--red);
    }

.security-note {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 16px;
    margin-top: 22px;
    background: #fff9e8;
    border: 1px solid #f0d78c;
    border-radius: 10px;
    font-size: 12.5px;
    line-height: 1.45;
    color: #9a7b3c;
}

.security-note-image {
    border: none;
    border-left: 4px solid #f0c14b;
    background: #fff8e6;
    border-radius: 8px;
    align-items: flex-start;
}

.security-icon {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #e6b422;
    color: #ffffff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

    .security-icon svg {
        width: 14px;
        height: 14px;
    }

.security-icon-shield {
    background: transparent;
    color: #c9a227;
    width: 20px;
    height: 20px;
    margin-top: 1px;
}

    .security-icon-shield svg {
        width: 18px;
        height: 18px;
    }

.form-footer {
    margin: 18px 0 0;
    text-align: center;
    font-size: 11px;
    color: #b0b0b0;
    line-height: 1.4;
}

.capture-preview {
    display: none;
    margin-bottom: 16px;
    border: 1px dashed #d0d0d4;
    border-radius: 8px;
    overflow: hidden;
    background: #f7f7f8;
    aspect-ratio: 4 / 3;
    align-items: center;
    justify-content: center;
}

    .capture-preview.is-visible {
        display: flex;
    }

    .capture-preview video,
    .capture-preview img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

.capture-preview-placeholder {
    color: #9a9a9a;
    font-size: 13px;
    text-align: center;
    padding: 20px;
}

.login-message {
    margin: 0 0 12px;
    text-align: center;
    font-size: 13px;
}

    .login-message.success {
        color: #555555;
    }

    .login-message.error {
        color: var(--red);
    }

.was-validated .boxed-input:invalid,
.boxed-input.is-invalid {
    border-color: var(--red);
}

.invalid-feedback {
    color: var(--red);
    font-size: 12px;
    margin-top: 6px;
}

@media (max-width: 991.98px) {
    .portal-page {
        padding: 16px 12px;
        padding: max(16px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
        max-height: none;
        align-items: flex-start;
        background-attachment: scroll;
    }

    .portal-card,
    .portal-card > .row,
    .portal-info,
    .portal-form {
        max-height: none;
    }

        .portal-card > .row {
            border-radius: 16px;
        }

    .portal-info {
        min-height: auto;
        padding: 32px 28px;
        overflow: visible;
        border-right: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    }

    .portal-heading {
        font-size: clamp(22px, 4vw, 24px);
    }

    .portal-desc {
        margin-bottom: 28px;
        max-width: none;
    }

    .feature-list {
        gap: 18px;
    }

    .portal-form {
        min-height: auto;
        padding: 32px 28px 24px;
        overflow: visible;
        border-left: none;
    }

    .login-tabs {
        flex-direction: column;
    }
}

@media (max-width: 575.98px) {
    .portal-page {
        padding: 12px 10px 20px;
        padding: max(12px, env(safe-area-inset-top)) max(10px, env(safe-area-inset-right)) max(20px, env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-left));
    }

    .portal-card,
    .portal-card > .row {
        border-radius: 12px;
    }

    .portal-info,
    .portal-form {
        padding: 22px 16px;
    }

    .brand {
        margin-bottom: 24px;
        gap: 10px;
    }

    .brand-icon {
        height: 56px;
        width: auto;
    }

    .brand-name {
        font-size: 17px;
    }

    .brand-tag {
        font-size: 12px;
    }

    .portal-heading {
        font-size: 20px;
    }

    .portal-desc {
        font-size: 13.5px;
        margin-bottom: 22px;
    }

    .feature-item strong {
        font-size: 14px;
    }

    .feature-item span:last-child {
        font-size: 12px;
    }

    .login-tabs {
        margin-bottom: 22px;
    }

    .login-tab {
        font-size: 12.5px;
        padding: 12px 10px;
    }

    .boxed-input {
        font-size: 16px; /* avoid iOS zoom on focus */
    }

    .security-note {
        font-size: 12px;
        padding: 12px 14px;
    }

    .btn-login,
    .btn-primary-action {
        width: 100%;
    }
}

@media (max-width: 380px) {
    .portal-page {
        padding: 10px 8px 16px;
        padding: max(10px, env(safe-area-inset-top)) max(8px, env(safe-area-inset-right)) max(16px, env(safe-area-inset-bottom)) max(8px, env(safe-area-inset-left));
    }

    .portal-info,
    .portal-form {
        padding: 18px 14px;
    }

    .feature-icon {
        width: 32px;
        height: 32px;
    }
}

/* ===== Live Image Capture Modal ===== */
.capture-modal[hidden] {
    display: none !important;
}

.capture-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.capture-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(20, 20, 25, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.capture-modal-dialog {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 620px;
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #ececef;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
    padding: 34px 36px 30px;
}

.capture-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #888888;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

    .capture-modal-close:hover {
        background: #f3f3f5;
        color: #333333;
    }

    .capture-modal-close svg {
        width: 20px;
        height: 20px;
    }

.capture-modal-header {
    text-align: center;
    margin-bottom: 22px;
    padding: 0 24px;
}

    .capture-modal-header h2 {
        margin: 0 0 10px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 10px;
        font-size: 22px;
        font-weight: 700;
        color: #1f1f1f;
    }

        .capture-modal-header h2 svg {
            width: 24px;
            height: 24px;
        }

    .capture-modal-header p {
        margin: 0;
        font-size: 14px;
        line-height: 1.5;
        color: #888888;
    }

.capture-viewport {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    min-height: 320px;
    border-radius: 14px;
    overflow: hidden;
    background: #2f3a47;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .capture-viewport video,
    .capture-viewport img {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

.capture-viewport-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: #c5cdd6;
    text-align: center;
    padding: 24px;
}

    .capture-viewport-placeholder svg {
        width: 72px;
        height: 72px;
        opacity: 0.7;
    }

    .capture-viewport-placeholder span {
        font-size: 15px;
        color: #ffffff;
    }

.capture-error {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 16px;
    padding: 14px 16px;
    border-radius: 10px;
    background: #fde8e8;
    color: #c2272d;
    font-size: 14px;
    line-height: 1.45;
}

    .capture-error[hidden] {
        display: none !important;
    }

    .capture-error svg {
        width: 20px;
        height: 20px;
        flex-shrink: 0;
        margin-top: 1px;
    }

.capture-modal-btn {
    margin-top: 18px;
    height: 52px;
    font-size: 15px;
}

    .capture-modal-btn:disabled {
        background: #b8c0c8;
        border-color: transparent;
        box-shadow: none;
        filter: none;
        cursor: not-allowed;
        color: #ffffff;
    }

        .capture-modal-btn:disabled:hover,
        .capture-modal-btn:disabled:focus {
            background: #b8c0c8;
            filter: none;
            box-shadow: none;
        }

body.modal-open {
    overflow: hidden;
}

@media (max-width: 640px) {
    .capture-modal {
        padding: 12px;
        align-items: flex-end;
    }

    .capture-modal-dialog {
        max-width: none;
        max-height: min(92vh, 100%);
        overflow-y: auto;
        border-radius: 16px 16px 12px 12px;
        padding: 28px 18px 22px;
    }

    .capture-modal-header {
        margin-bottom: 16px;
        padding: 0 28px 0 8px;
    }

        .capture-modal-header h2 {
            font-size: 18px;
            flex-wrap: wrap;
        }

            .capture-modal-header h2 svg {
                width: 20px;
                height: 20px;
            }

        .capture-modal-header p {
            font-size: 13px;
        }

    .capture-viewport {
        min-height: 0;
        aspect-ratio: 4 / 3;
    }

    .capture-viewport-placeholder {
        padding: 16px;
        gap: 10px;
    }

        .capture-viewport-placeholder svg {
            width: 48px;
            height: 48px;
        }

        .capture-viewport-placeholder span {
            font-size: 13px;
        }

    .capture-error {
        font-size: 13px;
        padding: 12px 14px;
    }

    .capture-modal-btn {
        height: 48px;
        font-size: 14px;
    }
}

@media (max-width: 380px) {
    .capture-modal-dialog {
        padding: 24px 14px 18px;
    }

    .capture-modal-header h2 {
        font-size: 16px;
    }
}

/* ================================
   CAMERA MODAL
================================ */

.camera-modal-content {
    border: none;
    border-radius: 18px;
    overflow: hidden;
    background: var(--white);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

/* Header */

.camera-modal-header {
    border-bottom: 1px solid var(--grey-light);
    padding: 22px 28px;
    background: var(--white);
}

    .camera-modal-header .modal-title {
        font-size: 20px;
        font-weight: 700;
        margin-bottom: 4px;
        color: var(--black);
    }

        .camera-modal-header .modal-title i {
            color: var(--red);
        }

    .camera-modal-header p {
        color: var(--grey);
        font-size: 14px;
        margin-bottom: 0;
    }


/* Body */

.camera-modal-body {
    padding: 24px 28px 28px;
}


/* ================================
   CAMERA PREVIEW
================================ */

.camera-preview-wrapper {
    width: 100%;
}

.camera-preview {
    position: relative;
    width: 100%;
    height: 350px;
    border-radius: 14px;
    overflow: hidden;
    background: #111827;
    border: 1px solid var(--grey-light);
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.1);
}


/* Placeholder */

.camera-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--grey);
    text-align: center;
    padding: 30px;
    background: #fdfdfd;
}

.camera-placeholder-icon {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--red-tint);
    margin-bottom: 15px;
}

    .camera-placeholder-icon i {
        font-size: 30px;
        color: var(--red);
    }

.camera-placeholder h6 {
    font-size: 18px;
    font-weight: 600;
    color: var(--black);
}

.camera-placeholder p {
    max-width: 350px;
    margin-bottom: 0;
    font-size: 14px;
    color: var(--grey);
}


/* Video */

.camera-feed {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
}


/* Camera Status */

.camera-status {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    color: var(--grey);
}

.status-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #28a745;
    box-shadow: 0 0 8px rgba(40, 167, 69, 0.5);
}


/* ================================
   ALERTS
================================ */

.camera-permission,
.permission-granted {
    display: none;
    align-items: flex-start;
    gap: 12px;
    padding: 15px;
    margin-top: 20px;
    border-radius: 10px;
}

.camera-permission {
    background: var(--note-bg);
    border: 1px solid var(--note-border);
    color: var(--note-text);
}

.permission-granted {
    background: #eaf7ee;
    border: 1px solid #b7e4c7;
    color: #155724;
}

.permission-granted .alert-icon i {
    color: #28a745;
}

.alert-icon {
    font-size: 22px;
    line-height: 1;
}

.camera-permission strong,
.permission-granted strong {
    display: block;
    margin-bottom: 4px;
}

.camera-permission p,
.permission-granted p {
    font-size: 13px;
}


/* ================================
   CAPTURE BUTTON
================================ */

.capture-btn {
    border: none;
    min-width: 220px;
    padding: 13px 30px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 15px;
    color: var(--white);
    background: linear-gradient(135deg, var(--red) 0%, var(--red-dark) 100%);
    box-shadow: 0 6px 20px rgba(194, 39, 45, 0.28);
    transition: all 0.25s ease;
}

    .capture-btn:hover:not(:disabled) {
        background: linear-gradient(135deg, var(--red-dark) 0%, var(--red-deep) 100%);
        transform: translateY(-2px);
        box-shadow: 0 8px 25px rgba(194, 39, 45, 0.38);
        color: var(--white);
    }

    .capture-btn:disabled {
        cursor: not-allowed;
        background: var(--grey-mid);
        opacity: 0.6;
        box-shadow: none;
    }


/* ================================
   CAPTURED IMAGE
================================ */

.captured-image-container {
    display: none;
    margin-top: 25px;
    padding: 20px;
    border-radius: 14px;
    background: #fdfdfd;
    border: 1px solid var(--grey-light);
}

.captured-image-header h6 {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 5px;
    color: var(--black);
}

    .captured-image-header h6 i {
        color: var(--red);
    }

.captured-image-header p {
    margin: 0;
    color: var(--grey);
    font-size: 13px;
}

.captured-image-preview {
    margin-top: 18px;
    display: flex;
    justify-content: center;
}

.captured-image {
    max-width: 100%;
    width: 320px;
    max-height: 300px;
    object-fit: cover;
    border-radius: 12px;
    border: 3px solid var(--red);
    box-shadow: 0 6px 22px rgba(194, 39, 45, 0.2);
}

.captured-image-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 20px;
}


/* ================================
   RESPONSIVE
================================ */

@media (max-width: 576px) {

    .camera-modal-body {
        padding: 16px;
    }

    .camera-modal-header {
        padding: 16px;
    }

    .camera-preview {
        height: 280px;
    }

    .captured-image-actions {
        flex-direction: column;
    }

        .captured-image-actions button {
            width: 100%;
        }

    .capture-btn {
        width: 100%;
    }
}