/* ================================================================
   Gripar Feedback Widget — feedback-widget.css
   ================================================================ */

/* ── Floating trigger button ───────────────────────────────────── */
#gp-fb-trigger {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 99990;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: #1a56db;
    color: #fff;
    border: none;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: grab;
    box-shadow: 0 4px 18px rgba(26,86,219,.40);
    transition: background .2s, transform .15s, box-shadow .2s, opacity .15s;
    letter-spacing: .3px;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: none;
    -webkit-user-select: none;
    user-select: none;
}
#gp-fb-trigger:hover {
    background: #1648c0;
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(26,86,219,.50);
}
#gp-fb-trigger:active { cursor: grabbing; }
#gp-fb-trigger.gp-fb-dragging {
    opacity: .85;
    cursor: grabbing;
    transform: scale(1.06);
    box-shadow: 0 8px 28px rgba(26,86,219,.55);
    transition: opacity .1s, transform .1s, box-shadow .1s;
}
#gp-fb-trigger i { font-size: 15px; }

/* ── Backdrop ──────────────────────────────────────────────────── */
#gp-fb-backdrop {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 99991;
    background: rgba(0,0,0,.40);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
    -webkit-animation: gpFbFadeIn .18s ease;
    animation: gpFbFadeIn .18s ease;
}
#gp-fb-backdrop.active { display: block; }

/* ── Modal container ───────────────────────────────────────────── */
#gp-fb-modal {
    display: none;
    position: fixed;
    bottom: 90px;
    right: 28px;
    z-index: 99992;
    width: 420px;
    max-width: calc(100vw - 40px);
    /* Constrain height so the modal never extends past the viewport.
       The JS layer sets a precise pixel value via --gp-fb-vh when open,
       overriding this fallback for the most accurate fit. */
    max-height: calc(100vh - 120px);
    max-height: calc(100dvh - 120px);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 12px 48px rgba(0,0,0,.18), 0 2px 8px rgba(0,0,0,.08);
    overflow: hidden;
    -webkit-animation: gpFbSlideUp .22s cubic-bezier(.34,1.56,.64,1);
    animation: gpFbSlideUp .22s cubic-bezier(.34,1.56,.64,1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    box-sizing: border-box;
}
#gp-fb-modal.active {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
}

/* Header, tabs, and footer are fixed; only the body scrolls.
   This guarantees buttons + title are always visible regardless of content. */
#gp-fb-modal .gp-fb-header,
#gp-fb-modal .gp-fb-tabs,
#gp-fb-modal .gp-fb-footer {
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
}
#gp-fb-modal #gp-fb-form {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}
#gp-fb-modal #gp-fb-mine-panel {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-height: 0;
    overflow: hidden;
}

/* ── Modal header ──────────────────────────────────────────────── */
.gp-fb-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px 14px;
    background: #1a56db;
    color: #fff;
}
.gp-fb-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
}
.gp-fb-close {
    background: rgba(255,255,255,.2);
    border: none;
    color: #fff;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
}
.gp-fb-close:hover { background: rgba(255,255,255,.35); }

/* ── Modal body / form ─────────────────────────────────────────── */
.gp-fb-body {
    padding: 20px;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
    /* Keep scroll inside the modal — never chain to the page behind */
    overscroll-behavior: contain;
    /* Slim, themed scrollbar (Firefox + WebKit) */
    scrollbar-width: thin;
    scrollbar-color: #c7d2e0 transparent;
}
.gp-fb-body::-webkit-scrollbar { width: 8px; }
.gp-fb-body::-webkit-scrollbar-track { background: transparent; }
.gp-fb-body::-webkit-scrollbar-thumb {
    background: #c7d2e0;
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: padding-box;
}
.gp-fb-body::-webkit-scrollbar-thumb:hover { background: #94a3b8; background-clip: padding-box; }

.gp-fb-field { margin-bottom: 16px; }
.gp-fb-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}
.gp-fb-field label span.req { color: #e53e3e; margin-left: 2px; }

.gp-fb-field select,
.gp-fb-field input[type="text"],
.gp-fb-field input[type="email"],
.gp-fb-field textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 9px 12px;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    color: #111827;
    font-family: inherit;
    background: #fafafa;
    transition: border-color .15s, box-shadow .15s;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}
.gp-fb-field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%236b7280' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}
.gp-fb-field select:focus,
.gp-fb-field input[type="text"]:focus,
.gp-fb-field input[type="email"]:focus,
.gp-fb-field textarea:focus {
    border-color: #1a56db;
    box-shadow: 0 0 0 3px rgba(26,86,219,.12);
    background: #fff;
}
.gp-fb-field textarea { resize: vertical; min-height: 100px; }

/* Type badges row */
.gp-fb-type-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.gp-fb-type-btn {
    flex: 1;
    min-width: 80px;
    padding: 8px 6px;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    background: #f9fafb;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    text-align: center;
    transition: all .15s;
    font-family: inherit;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}
.gp-fb-type-btn i { font-size: 16px; }
.gp-fb-type-btn:hover { border-color: #1a56db; color: #1a56db; background: #eff6ff; }
.gp-fb-type-btn.selected {
    border-color: #1a56db;
    background: #eff6ff;
    color: #1a56db;
    box-shadow: 0 0 0 3px rgba(26,86,219,.10);
}
.gp-fb-type-btn.selected.type-bug     { border-color: #dc2626; color: #dc2626; background: #fef2f2; box-shadow: 0 0 0 3px rgba(220,38,38,.10); }
.gp-fb-type-btn.selected.type-suggest { border-color: #059669; color: #059669; background: #ecfdf5; box-shadow: 0 0 0 3px rgba(5,150,105,.10); }
.gp-fb-type-btn.selected.type-other   { border-color: #7c3aed; color: #7c3aed; background: #f5f3ff; box-shadow: 0 0 0 3px rgba(124,58,237,.10); }

/* File upload zone */
.gp-fb-dropzone {
    border: 2px dashed #d1d5db;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
    cursor: pointer;
    transition: border-color .15s, background .15s;
    background: #fafafa;
}
.gp-fb-dropzone:hover,
.gp-fb-dropzone.drag-over {
    border-color: #1a56db;
    background: #eff6ff;
}
.gp-fb-dropzone input[type="file"] { display: none; }
.gp-fb-dropzone .gp-fb-dz-icon { font-size: 24px; color: #9ca3af; margin-bottom: 6px; }
.gp-fb-dropzone p {
    margin: 0;
    font-size: 13px;
    color: #6b7280;
}
.gp-fb-dropzone p strong { color: #1a56db; cursor: pointer; }

.gp-fb-file-list {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.gp-fb-file-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f3f4f6;
    border-radius: 6px;
    padding: 7px 10px;
    font-size: 13px;
    color: #374151;
}
.gp-fb-file-item i { color: #6b7280; }
.gp-fb-file-item span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gp-fb-file-item .gp-fb-rm { cursor: pointer; color: #9ca3af; font-size: 15px; }
.gp-fb-file-item .gp-fb-rm:hover { color: #ef4444; }

/* Char counter */
.gp-fb-char { font-size: 11px; color: #9ca3af; text-align: right; margin-top: 3px; }
.gp-fb-char.warn { color: #f59e0b; }
.gp-fb-char.over { color: #ef4444; }

/* ── Footer / submit ───────────────────────────────────────────── */
.gp-fb-footer {
    padding: 14px 20px 18px;
    border-top: 1px solid #f3f4f6;
    display: flex;
    align-items: center;
    gap: 10px;
}
.gp-fb-submit {
    flex: 1;
    padding: 11px;
    background: #1a56db;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.gp-fb-submit:hover:not(:disabled) { background: #1648c0; }
.gp-fb-submit:disabled { opacity: .6; cursor: not-allowed; }

.gp-fb-cancel {
    padding: 11px 16px;
    background: #f3f4f6;
    color: #374151;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s;
}
.gp-fb-cancel:hover { background: #e5e7eb; }

/* ── Alert / toast messages ────────────────────────────────────── */
.gp-fb-alert {
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}
.gp-fb-alert.success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.gp-fb-alert.error   { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* ── Success state ─────────────────────────────────────────────── */
.gp-fb-success-state {
    text-align: center;
    padding: 30px 20px;
}
.gp-fb-success-state .gp-fb-tick {
    font-size: 48px;
    color: #10b981;
    margin-bottom: 12px;
}
.gp-fb-success-state h4 {
    margin: 0 0 8px;
    font-size: 17px;
    color: #111827;
}
.gp-fb-success-state p {
    margin: 0 0 16px;
    font-size: 14px;
    color: #6b7280;
}

/* ── Token box (shown after successful submission) ─────────────── */
.gp-fb-token-box {
    margin: 0 auto;
    max-width: 320px;
    background: #f0f9ff;
    border: 2px dashed #38bdf8;
    border-radius: 10px;
    padding: 14px 16px;
    text-align: center;
}
.gp-fb-token-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: #0369a1;
    margin-bottom: 8px;
}
.gp-fb-token-value {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 2px;
    color: #0c4a6e;
    font-family: 'Courier New', monospace;
    margin-bottom: 10px;
    word-break: break-all;
}
.gp-fb-token-copy {
    padding: 7px 16px;
    background: #0369a1;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: inherit;
    transition: background .15s;
    margin-bottom: 10px;
}
.gp-fb-token-copy:hover { background: #075985; }
.gp-fb-token-hint {
    font-size: 12px;
    color: #64748b;
    margin: 0;
}

/* ── Animations ────────────────────────────────────────────────── */
@-webkit-keyframes gpFbSlideUp {
    from { opacity: 0; -webkit-transform: translateY(20px) scale(.97); transform: translateY(20px) scale(.97); }
    to   { opacity: 1; -webkit-transform: translateY(0) scale(1);      transform: translateY(0) scale(1); }
}
@keyframes gpFbSlideUp {
    from { opacity: 0; transform: translateY(20px) scale(.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
@-webkit-keyframes gpFbFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes gpFbFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ── Tabs ──────────────────────────────────────────────────────── */
.gp-fb-tabs {
    display: flex;
    border-bottom: 1px solid #f3f4f6;
    flex-shrink: 0;
}
.gp-fb-tab {
    flex: 1;
    padding: 11px 8px;
    background: #fff;
    border: none;
    border-bottom: 2px solid transparent;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    cursor: pointer;
    font-family: inherit;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: color .15s, border-color .15s, background .15s;
}
.gp-fb-tab:hover  { color: #1a56db; background: #f9fafb; }
.gp-fb-tab.active { color: #1a56db; border-bottom-color: #1a56db; background: #fff; }
.gp-fb-tab i      { font-size: 12px; }

/* ── My Submissions panel ──────────────────────────────────────── */
#gp-fb-mine-panel {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}
.gp-fb-mine-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px 8px;
    flex-shrink: 0;
    border-bottom: 1px solid #f3f4f6;
}
.gp-fb-mine-count { font-size: 12px; color: #9ca3af; font-weight: 500; }
.gp-fb-mine-refresh {
    background: none;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 500;
    color: #6b7280;
    cursor: pointer;
    font-family: inherit;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all .15s;
}
.gp-fb-mine-refresh:hover { border-color: #1a56db; color: #1a56db; }
.gp-fb-mine-list {
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #c7d2e0 transparent;
}
.gp-fb-mine-list::-webkit-scrollbar { width: 8px; }
.gp-fb-mine-list::-webkit-scrollbar-track { background: transparent; }
.gp-fb-mine-list::-webkit-scrollbar-thumb {
    background: #c7d2e0;
    border-radius: 4px;
    border: 2px solid transparent;
    background-clip: padding-box;
}
.gp-fb-mine-loading {
    text-align: center;
    padding: 40px 20px;
    color: #9ca3af;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.gp-fb-mine-empty {
    text-align: center;
    padding: 36px 20px;
    color: #9ca3af;
    font-size: 13px;
}
.gp-fb-mine-empty i { font-size: 26px; margin-bottom: 10px; display: block; }
.gp-fb-mine-empty p { margin: 0; }

/* ── Submission rows ───────────────────────────────────────────── */
.gp-fb-sub-row { border-bottom: 1px solid #f3f4f6; }
.gp-fb-sub-row:last-child { border-bottom: none; }
.gp-fb-sub-row-main {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    cursor: pointer;
    transition: background .12s;
    flex-wrap: wrap;
}
.gp-fb-sub-row-main:hover { background: #f9fafb; }
.gp-fb-sub-row.open .gp-fb-sub-row-main { background: #eff6ff; }

.gp-fb-sub-token {
    font-family: 'Courier New', monospace;
    font-size: 10px;
    font-weight: 700;
    color: #1a56db;
    background: #eff6ff;
    border-radius: 4px;
    padding: 2px 6px;
    white-space: nowrap;
    flex-shrink: 0;
    letter-spacing: .5px;
}
.gp-fb-sub-subject {
    flex: 1;
    min-width: 80px;
    font-size: 12px;
    font-weight: 500;
    color: #111827;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.gp-fb-sub-badges { display: flex; gap: 4px; flex-shrink: 0; align-items: center; }
.gp-fb-sub-badge  { font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 10px; white-space: nowrap; }

/* Type badge colours */
.gp-fb-type-feedback { background: #eff6ff; color: #1d4ed8; }
.gp-fb-type-bug      { background: #fef2f2; color: #b91c1c; }
.gp-fb-type-suggest  { background: #ecfdf5; color: #065f46; }
.gp-fb-type-other    { background: #f5f3ff; color: #5b21b6; }
/* Status badge colours */
.gp-fb-status-new         { background: #dbeafe; color: #1e40af; }
.gp-fb-status-in_review   { background: #ede9fe; color: #5b21b6; }
.gp-fb-status-in_progress { background: #fef3c7; color: #92400e; }
.gp-fb-status-resolved    { background: #d1fae5; color: #065f46; }
.gp-fb-status-closed      { background: #f1f5f9; color: #64748b; }

.gp-fb-sub-chevron { font-size: 10px; color: #9ca3af; flex-shrink: 0; transition: transform .15s; }

/* ── Expand panel ──────────────────────────────────────────────── */
.gp-fb-sub-expand { background: #f8fafc; border-top: 1px solid #e5e7eb; }
.gp-fb-sub-expand-loading {
    text-align: center; padding: 18px; font-size: 12px; color: #9ca3af;
    display: flex; align-items: center; justify-content: center; gap: 7px;
}
.gp-fb-sub-detail { padding: 14px 16px; }
.gp-fb-sub-detail-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 12px;
    font-size: 12px;
    color: #374151;
}
.gp-fb-sub-detail-meta > span { display: flex; align-items: center; gap: 6px; }
.gp-fb-sub-detail-lbl {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .4px;
    color: #9ca3af;
}
.gp-fb-sub-details-text {
    font-size: 12px;
    color: #374151;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 9px 12px;
    white-space: pre-wrap;
    line-height: 1.55;
    max-height: 100px;
    overflow-y: auto;
    margin-bottom: 2px;
}

/* Status progress steps (compact) */
.gp-fb-sub-progress { margin: 12px 0 14px; }
.gp-fb-sub-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    overflow-x: auto;
    padding: 2px 0;
}
.gp-fb-sub-step { display: flex; flex-direction: column; align-items: center; gap: 4px; flex-shrink: 0; }
.gp-fb-sub-step-icon {
    width: 28px; height: 28px;
    border-radius: 50%;
    border: 2px solid #e2e8f0;
    background: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; color: #cbd5e1; transition: all .2s;
}
.gp-fb-sub-step.done   .gp-fb-sub-step-icon { background: #d1fae5; border-color: #10b981; color: #065f46; }
.gp-fb-sub-step.active .gp-fb-sub-step-icon { background: #1a56db; border-color: #1a56db; color: #fff; }
.gp-fb-sub-step-label { font-size: 9px; font-weight: 600; color: #94a3b8; white-space: nowrap; }
.gp-fb-sub-step.done   .gp-fb-sub-step-label { color: #059669; }
.gp-fb-sub-step.active .gp-fb-sub-step-label { color: #1a56db; }
.gp-fb-sub-step-line {
    flex: 1; height: 2px; background: #e2e8f0;
    min-width: 10px; max-width: 36px; margin-bottom: 18px; transition: background .2s;
}
.gp-fb-sub-step-line.done { background: #10b981; }

/* Remarks inside expand */
.gp-fb-sub-remarks-list { display: flex; flex-direction: column; gap: 7px; }
.gp-fb-sub-remark {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-left: 3px solid #6366f1;
    border-radius: 5px;
    padding: 8px 10px;
}
.gp-fb-sub-remark-meta {
    display: flex; align-items: center; justify-content: space-between;
    font-size: 10px; color: #9ca3af; margin-bottom: 4px; gap: 8px;
}
.gp-fb-sub-remark-meta span:first-child { font-weight: 700; color: #6366f1; }
.gp-fb-sub-remark-text { font-size: 12px; color: #374151; line-height: 1.5; }
.gp-fb-sub-no-remarks  { font-size: 12px; color: #9ca3af; margin: 0; }
.gp-fb-sub-err         { font-size: 12px; color: #ef4444; padding: 10px 16px; margin: 0; }

/* ── Spinner ───────────────────────────────────────────────────── */
.gp-fb-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.3);
    border-top-color: #fff;
    border-radius: 50%;
    -webkit-animation: gpFbSpin .7s linear infinite;
    animation: gpFbSpin .7s linear infinite;
}
@-webkit-keyframes gpFbSpin { to { -webkit-transform: rotate(360deg); transform: rotate(360deg); } }
@keyframes gpFbSpin { to { transform: rotate(360deg); } }

/* ── Guest step panels ─────────────────────────────────────────── */

/* Shared container: email step & OTP step */
.gp-fb-guest-step {
    padding: 28px 24px 0;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    scrollbar-width: thin;
    scrollbar-color: #c7d2e0 transparent;
}

/* Centred header block: icon + heading + sub-text */
.gp-fb-guest-header {
    text-align: center;
    margin-bottom: 22px;
}
.gp-fb-guest-header h4 {
    margin: 10px 0 6px;
    font-size: 16px;
    font-weight: 700;
    color: #111827;
}
.gp-fb-guest-header p {
    margin: 0;
    font-size: 13px;
    color: #6b7280;
    line-height: 1.5;
}

/* Large centred icon */
.gp-fb-guest-icon {
    display: block;
    font-size: 38px;
    color: #1a56db;
    margin: 0 auto 2px;
}

/* Dev-only OTP display box */
.gp-fb-guest-dev-otp {
    background: #fffbeb;
    border: 1.5px dashed #f59e0b;
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 13px;
    font-weight: 600;
    color: #92400e;
    text-align: center;
    letter-spacing: .5px;
}
.gp-fb-guest-dev-otp::before {
    content: '🔧 Dev OTP: ';
    font-weight: 700;
}

/* Footer row in OTP step: timer · resend · sep · back */
.gp-fb-guest-otp-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #9ca3af;
    margin-top: 6px;
    margin-bottom: 2px;
    flex-wrap: wrap;
}

/* Countdown text, e.g. "Resend in 54s" */
.gp-fb-guest-timer {
    color: #6b7280;
    font-weight: 500;
}

/* Resend Code link */
.gp-fb-guest-resend {
    color: #1a56db;
    font-weight: 600;
    text-decoration: none;
    transition: color .15s;
}
.gp-fb-guest-resend:hover { color: #1648c0; text-decoration: underline; }

/* Back link */
.gp-fb-guest-back {
    color: #6b7280;
    font-weight: 500;
    text-decoration: none;
    transition: color .15s;
}
.gp-fb-guest-back:hover { color: #374151; text-decoration: underline; }

/* Separator dot between footer links */
.gp-fb-guest-sep {
    color: #d1d5db;
    -webkit-user-select: none;
    user-select: none;
    line-height: 1;
}

/* "Submitting as …" badge shown inside the feedback form for verified guests */
.gp-fb-guest-badge {
    display: flex;
    align-items: center;
    gap: 7px;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    color: #1e40af;
    margin-bottom: 16px;
    flex-wrap: wrap;
    line-height: 1.4;
}
.gp-fb-guest-badge i {
    font-size: 14px;
    color: #2563eb;
    flex-shrink: 0;
}
.gp-fb-guest-badge strong {
    font-weight: 700;
    word-break: break-all;
}
.gp-fb-guest-badge a {
    margin-left: auto;
    font-size: 12px;
    font-weight: 600;
    color: #1a56db;
    text-decoration: none;
    white-space: nowrap;
    transition: color .15s;
}
.gp-fb-guest-badge a:hover { color: #1648c0; text-decoration: underline; }

/* "Please log in" state in My Submissions tab for guests */
.gp-fb-mine-guest {
    padding: 44px 24px;
}
.gp-fb-mine-guest a {
    color: #1a56db;
    font-weight: 600;
    text-decoration: none;
}
.gp-fb-mine-guest a:hover { text-decoration: underline; }

/* ── Responsive — bottom sheet for narrow viewports ───────────── */
/* Threshold raised to 640px so narrow desktop windows (e.g. Windows
   browser at ~600px wide) also get the safe full-width sheet layout. */
@media (max-width: 640px) {
    #gp-fb-modal {
        bottom: 0;
        right: 0;
        left: 0;
        top: auto;
        width: 100%;
        max-width: 100%;
        border-radius: 16px 16px 0 0;
        /* Use the smallest stable viewport unit so the modal never extends
           behind the dynamic browser UI. Fallback chain:
             vh   — works everywhere, but on mobile may include browser chrome
             svh  — small viewport height (with chrome visible) — modern browsers
             dvh  — dynamic viewport height — newest, adapts as chrome shows/hides
           JS additionally overrides this via inline style for the most precise fit. */
        max-height: 90vh;
        max-height: 90svh;
        max-height: 90dvh;
        /* iOS safe area — keep footer clear of home indicator */
        padding-bottom: env(safe-area-inset-bottom, 0px);
    }

    /* ── Compact mobile spacing — aim: no internal scroll on common phones ── */

    /* Header / tabs / footer: tight padding */
    #gp-fb-modal .gp-fb-header { padding: 12px 16px 10px; }
    #gp-fb-modal .gp-fb-header h3 { font-size: 15px; }
    #gp-fb-modal .gp-fb-tabs .gp-fb-tab { padding: 9px 8px; font-size: 12px; }
    #gp-fb-modal .gp-fb-footer { padding: 10px 14px 12px; }
    #gp-fb-modal .gp-fb-submit,
    #gp-fb-modal .gp-fb-cancel { padding: 10px 14px; font-size: 13px; }

    /* Body: tighter outer padding */
    #gp-fb-modal .gp-fb-body { padding: 12px 14px; }

    /* Field rhythm: less vertical gap between fields */
    #gp-fb-modal .gp-fb-field        { margin-bottom: 10px; }
    #gp-fb-modal .gp-fb-field label  { margin-bottom: 4px; font-size: 12px; }
    #gp-fb-modal .gp-fb-field select,
    #gp-fb-modal .gp-fb-field input[type="text"],
    #gp-fb-modal .gp-fb-field input[type="email"],
    #gp-fb-modal .gp-fb-field textarea { padding: 8px 10px; font-size: 13px; }

    /* Type buttons: smaller pills */
    #gp-fb-modal .gp-fb-type-btn { padding: 6px 4px; font-size: 11px; min-width: 0; }
    #gp-fb-modal .gp-fb-type-btn i { font-size: 13px; }
    #gp-fb-modal .gp-fb-type-group { gap: 6px; }

    /* Details textarea: significantly shorter on mobile */
    #gp-fb-modal .gp-fb-field textarea { min-height: 60px; }

    /* Char counter pulled tighter */
    #gp-fb-modal .gp-fb-char { font-size: 10px; margin-top: 2px; }

    /* Dropzone: shorter so it doesn't dominate the body */
    #gp-fb-modal .gp-fb-dropzone { padding: 10px; }
    #gp-fb-modal .gp-fb-dropzone .gp-fb-dz-icon { font-size: 18px; margin-bottom: 2px; }
    #gp-fb-modal .gp-fb-dropzone p { font-size: 12px; }

    /* On mobile the button position is managed by JS drag logic;
       these are the defaults if no saved position exists. */
    #gp-fb-trigger {
        bottom: 20px;
        right: 16px;
        left: auto;
        padding: 10px 16px;
        font-size: 13px;
    }
}

/* Extra-narrow viewports (small phones) — keep things tight */
@media (max-width: 380px) {
    #gp-fb-modal .gp-fb-type-btn { flex-basis: calc(50% - 3px); }
    #gp-fb-modal .gp-fb-footer   { gap: 6px; padding: 10px 12px 12px; }
    #gp-fb-modal .gp-fb-cancel   { padding: 10px 12px; }
    #gp-fb-modal .gp-fb-guest-badge { padding: 6px 10px; font-size: 12px; margin-bottom: 10px; }
}

/* Short viewports (landscape phones, mini windows) — shrink the textarea
   further so the footer never gets pushed off */
@media (max-height: 600px) {
    #gp-fb-modal .gp-fb-field textarea { min-height: 50px; }
    #gp-fb-modal .gp-fb-body { padding: 10px 14px; }
    #gp-fb-modal .gp-fb-field { margin-bottom: 8px; }
}

/* ── Drag-to-reposition hint (mobile only) ─────────────────────── */
@media (hover: none) and (pointer: coarse) {
    /* Touch devices: show a subtle drag-handle cue */
    #gp-fb-trigger::after {
        content: '';
        display: inline-block;
        width: 4px;
        height: 4px;
        border-radius: 50%;
        background: rgba(255,255,255,.5);
        margin-left: 2px;
        box-shadow: 0 -5px 0 rgba(255,255,255,.5), 0 5px 0 rgba(255,255,255,.5);
        -webkit-flex-shrink: 0;
        flex-shrink: 0;
    }
}