﻿/* =====================================================
 * IELTS Mock Hub — Mobile-First CSS
 * Breakpoints (min-width): 480px | 640px | 768px | 1024px | 1366px
 * 14-inch primary target: 1366px
 * ===================================================== */

/* ==========================================
 * 1. FULLSCREEN SHELL
 * ========================================== */
.ielts-mock-fullscreen-shell{position:fixed;inset:0;z-index:var(--ielts-lms-z-top, 2147483000);width:100%;height:100vh;background:#f8fafc;overflow:auto;box-sizing:border-box;top:var(--wp-admin--admin-bar--height,0px);height:calc(100vh - var(--wp-admin--admin-bar--height,0px))}
.ielts-mock-fullscreen-shell__inner{min-height:100%;box-sizing:border-box;padding:16px}
.ielts-mock-fullscreen-shell--runtime{background:#fff;overflow:hidden}
.ielts-mock-fullscreen-shell--runtime .ielts-mock-fullscreen-shell__inner{height:100%;padding:0;background:#fff}
.ielts-mock-fullscreen-shell--runtime .ielts-final-wrapper{height:100% !important;width:100% !important;max-width:100% !important;margin:0 !important;padding:0 !important;border:none !important;border-radius:0 !important}
.ielts-mock-fullscreen-shell--runtime .ielts-main-interface-container{height:100% !important;max-height:none !important;flex-grow:1 !important;min-height:0 !important;box-sizing:border-box !important}
.ielts-mock-fullscreen-shell--runtime .ielts-content-wrapper{height:100%;min-height:0}
.ielts-mock-fullscreen-shell--runtime .ielts-final-container{height:100%;min-height:0}
.ielts-mock-fullscreen-shell--runtime .ielts-writing-container{min-height:0}
.ielts-mock-fullscreen-shell--runtime .ielts-top-bar,
.ielts-mock-fullscreen-shell--runtime .ielts-widget-header{margin-top:0 !important;border-top-left-radius:0 !important;border-top-right-radius:0 !important}

/* ── PRESTART SCROLL FIX ─────────────────────────────────────────────
 * Before the test starts (.test-started / .test-loading not present),
 * the instruction card can be taller than the viewport.  The --runtime
 * shell must scroll so users can reach the START TEST button.
 * :has() is supported in all modern browsers since 2023 and is already
 * used elsewhere in this codebase (single-ielts-writing.php, etc).
 * ------------------------------------------------------------------ */
/* :has() fallback — class-based selectors toggled via JS for older browsers */
.ielts-mock-fullscreen-shell--runtime.ielts-mock-pretest{overflow-y:auto}
.ielts-mock-fullscreen-shell--runtime.ielts-mock-pretest .ielts-mock-fullscreen-shell__inner{height:auto;min-height:100%;padding:16px;display:flex;flex-direction:column;align-items:center}
.ielts-mock-fullscreen-shell--runtime.ielts-mock-pretest .ielts-final-wrapper{height:auto !important;width:100% !important;max-width:740px !important;margin:0 auto !important}
@media(min-width:640px){
    .ielts-mock-fullscreen-shell--runtime.ielts-mock-pretest .ielts-mock-fullscreen-shell__inner{padding:24px 20px}
}
/* Modern browsers: use :has() */
.ielts-mock-fullscreen-shell--runtime:not(:has(.ielts-final-wrapper.test-started,.ielts-final-wrapper.test-loading)){overflow-y:auto}
.ielts-mock-fullscreen-shell--runtime:not(:has(.ielts-final-wrapper.test-started,.ielts-final-wrapper.test-loading)) .ielts-mock-fullscreen-shell__inner{height:auto;min-height:100%;padding:16px;display:flex;flex-direction:column;align-items:center}
.ielts-mock-fullscreen-shell--runtime:not(:has(.ielts-final-wrapper.test-started,.ielts-final-wrapper.test-loading)) .ielts-final-wrapper{height:auto !important;width:100% !important;max-width:740px !important;margin:0 auto !important}
@media(min-width:640px){
    .ielts-mock-fullscreen-shell--runtime:not(:has(.ielts-final-wrapper.test-started,.ielts-final-wrapper.test-loading)) .ielts-mock-fullscreen-shell__inner{padding:24px 20px}
}

/* ==========================================
 * 2. TRANSITION GUARD
 * ========================================== */
.ielts-mock-fullscreen-active,
.ielts-mock-fullscreen-active body{overflow:hidden !important}
.ielts-mock-transitioning,
.ielts-mock-transitioning body{overflow:hidden !important}
.ielts-mock-transition-guard{position:fixed;inset:0;z-index:var(--ielts-lms-z-guard, 2147483646);background:#f8fafc;opacity:0;pointer-events:none}
.ielts-mock-transition-guard[data-mode="runtime"]{background:#fff}
html.ielts-mock-transitioning .ielts-mock-transition-guard,
body.ielts-mock-transitioning .ielts-mock-transition-guard{opacity:1;pointer-events:auto}

/* ==========================================
 * 3. ENTRY SCREEN — mobile-first defaults
 * ========================================== */
.imh-entry-wrap{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;color:#111827}
.imh-entry-topbar{display:flex;flex-direction:column;align-items:center;gap:10px;margin:8px 0 24px}
.imh-entry-logo{text-align:center;font-size:1.9rem;font-weight:800;letter-spacing:-.03em;color:#111827;margin:0}
.imh-entry-stepper-block{display:flex;flex-direction:column;align-items:center;gap:8px}
.imh-entry-step-track{display:flex;align-items:center;justify-content:center;gap:8px;margin:0}
.imh-entry-step-dot{width:34px;height:8px;border-radius:999px;background:#dbe4ef}
.imh-entry-step-dot.active{background:linear-gradient(90deg,#2563eb 0%,#1d4ed8 100%);box-shadow:0 4px 16px rgba(37,99,235,.18)}
.imh-entry-step-label{text-align:center;color:#64748b;font-size:.8rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase;margin:0}
.imh-entry-card{background:#fff;border:1px solid #e5e7eb;border-radius:14px;padding:18px;box-shadow:0 4px 24px rgba(0,0,0,.07)}
.imh-entry-head{display:flex;flex-direction:column;align-items:center;gap:14px;margin-bottom:20px;padding-right:0}
.imh-entry-head-copy{max-width:560px;margin:0 auto;text-align:center}
.imh-entry-head-actions{position:static;display:flex;flex-direction:column;align-items:center;gap:12px;width:100%}
.imh-entry-eyebrow{margin:0 0 6px;color:#64748b;font-size:.78rem;font-weight:800;letter-spacing:.12em;text-transform:uppercase}
.imh-entry-head h3{margin:0 0 6px;font-size:1.18rem;line-height:1.25;color:#111827;font-weight:700;letter-spacing:-.02em}
.imh-entry-head p{margin:0 auto;color:#6b7280;font-size:.9rem;line-height:1.7;max-width:520px}
.imh-entry-exit{display:inline-flex;align-items:center;justify-content:center;gap:10px;width:100%;padding:10px 18px;min-height:44px;border:1px solid #cbd5e1;border-radius:10px;background:#fff;color:#374151;text-decoration:none;font-weight:700;transition:background-color .16s ease,border-color .16s ease}
.imh-entry-exit:hover{background:#f8fafc;border-color:#94a3b8}
.imh-entry-exit:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(37,99,235,0.25)}
.imh-entry-exit:active{background:#f1f5f9}
.imh-entry-exit-icon{display:inline-flex;width:18px;height:18px}
.imh-entry-exit-icon svg{width:18px;height:18px}
.imh-entry-body{padding:0}
.imh-entry-layout{display:grid;grid-template-columns:1fr;gap:14px;align-items:start}
.imh-entry-main,.imh-entry-side{display:grid;gap:14px}
.imh-entry-panel,.imh-entry-form-card{background:#fff;border:1px solid #e5e7eb;border-radius:12px;padding:14px;box-shadow:none}
.imh-entry-side-eyebrow{margin:0 0 8px;font-size:.76rem;font-weight:800;letter-spacing:.12em;text-transform:uppercase;color:#64748b}
.imh-entry-form-title{margin:0 0 6px;font-size:1.05rem;line-height:1.3;font-weight:700;color:#111827}
.imh-entry-form-copy{margin:0 0 14px;color:#6b7280;line-height:1.65;font-size:.87rem}
.imh-entry-notice{display:flex;align-items:flex-start;gap:13px;padding:13px 14px;background:#f8fafc;border:1px solid #e2e8f0;border-radius:10px}
.imh-entry-notice-icon{display:flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:50%;background:#fff;color:#2563eb;border:1px solid #e2e8f0;flex:0 0 auto}
.imh-entry-notice-icon svg{width:20px;height:20px}
.imh-entry-copy{margin:0;color:#374151;line-height:1.72;font-size:.89rem}
.imh-entry-section-head{display:flex;align-items:center;gap:10px;margin:0 0 13px}
.imh-entry-section-icon{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:10px;background:#f8fafc;color:#64748b;border:1px solid #e2e8f0}
.imh-entry-section-icon svg{width:16px;height:16px}
.imh-entry-subtitle{margin:0;font-size:.74rem;color:#111827;font-weight:800;letter-spacing:.08em;text-transform:uppercase}
.imh-entry-duration-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:8px;margin:0 0 15px}
.imh-entry-duration-item{border:1.5px solid #e5e7eb;border-radius:10px;padding:13px 6px 11px;text-align:center;display:flex;flex-direction:column;align-items:center;gap:6px;background:#fff}
.imh-entry-duration-item:hover{border-color:#cbd5e1}
.imh-entry-duration-badge{display:flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:50%;background:#f8fafc}
.imh-entry-duration-badge svg{width:18px;height:18px}
.imh-entry-duration-item-listening .imh-entry-duration-badge{color:#0284c7}
.imh-entry-duration-item-reading .imh-entry-duration-badge{color:#2563eb}
.imh-entry-duration-item-writing .imh-entry-duration-badge{color:#7c3aed}
.imh-entry-duration-item-speaking .imh-entry-duration-badge{color:#db2777}
.imh-entry-duration-label{color:#6b7280;font-size:.76rem;font-weight:600}
.imh-entry-duration-value{color:#111827;font-size:.9rem;font-weight:700}
.imh-entry-total{display:flex;align-items:center;gap:8px;margin:0;color:#111827;font-size:.9rem;line-height:1.5;flex-wrap:wrap;justify-content:center}
.imh-entry-total span{color:#111827}
.imh-entry-total strong{font-weight:800}
.imh-entry-rules{list-style:none;margin:0;padding:0;display:grid;gap:10px}
.imh-entry-rules li{position:relative;padding-left:18px;color:#374151;line-height:1.7;font-size:.87rem}
.imh-entry-rules li:before{content:'';position:absolute;left:0;top:.66em;width:6px;height:6px;border-radius:50%;background:#3b82f6}
.imh-entry-form{display:flex;flex-direction:column;gap:15px}
.imh-entry-field-grid{display:grid;grid-template-columns:1fr;gap:13px}
.imh-entry-field{display:flex;flex-direction:column;gap:7px}
.imh-entry-field-label{font-size:.74rem;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:#dc2626;padding-left:2px}
.imh-entry-field-shell{position:relative;display:block}
.imh-entry-field-icon{position:absolute;left:14px;top:50%;transform:translateY(-50%);display:flex;align-items:center;justify-content:center;color:#94a3b8;pointer-events:none}
.imh-entry-field-icon svg{width:17px;height:17px}
.imh-entry-input{width:100%;padding:11px 12px 11px 38px;border:1px solid #cbd5e1;border-radius:8px;font-size:.9rem;color:#111827;background:#fff;min-height:44px;transition:border-color .16s ease,box-shadow .16s ease}
.imh-entry-input:focus{outline:none;border-color:#2563eb;box-shadow:0 0 0 3px rgba(37,99,235,0.25)}
.imh-entry-error{margin:0 0 13px;padding:10px 13px;border-radius:12px;border:1px solid #fecaca;background:#fff1f2;color:#b42318;font-size:.9rem;font-weight:700}
.imh-entry-footer{padding-top:4px}
.imh-entry-cta{display:flex;align-items:center;justify-content:center;gap:12px;width:100%;padding:14px;min-height:44px;background:linear-gradient(180deg,#27c184 0%,#1eb06f 100%);color:#fff !important;text-decoration:none !important;border:0;border-radius:10px;font-size:.95rem;font-weight:700;cursor:pointer;box-shadow:0 10px 24px rgba(30,176,111,.22);transition:transform .15s ease,box-shadow .15s ease}
.imh-entry-cta:hover{box-shadow:0 12px 26px rgba(30,176,111,.26);transform:translateY(-1px)}
.imh-entry-cta:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(30,176,111,0.40);transform:translateY(-1px)}
.imh-entry-cta:active{transform:scale(0.97);box-shadow:0 4px 12px rgba(30,176,111,.18)}
.imh-entry-cta-icon{display:inline-flex;width:20px;height:20px}
.imh-entry-cta-icon svg{width:20px;height:20px}
.imh-entry-cta:disabled{background:#c7d3e2 !important;cursor:not-allowed;opacity:1;box-shadow:none;transform:none !important}
.imh-entry-cta:disabled:hover{background:#c7d3e2 !important}

/* ==========================================
 * 4. HUB PICKER / CARD — mobile-first defaults
 * ========================================== */
.imh-wrap{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif}
.imh-card{background:#fff;border:1px solid #e5e7eb;border-radius:14px;padding:18px;box-shadow:0 4px 24px rgba(0,0,0,.07)}
.imh-card-top{display:flex;justify-content:space-between;align-items:flex-start;gap:14px;margin-bottom:20px}
.imh-card-title{margin:0 0 5px;font-size:1.2rem;font-weight:700;color:#111827;line-height:1.3}
.imh-card-sub{margin:0;font-size:.86rem;color:#6b7280}
.imh-resume-box{background:#f8fafc;border:1px solid #dbe3ee;border-radius:12px;padding:14px 16px;margin-bottom:15px}
.imh-resume-box-title{margin:0 0 4px;font-size:.95rem;font-weight:700;color:#111827}
.imh-resume-box-sub{margin:0 0 11px;font-size:.82rem;color:#6b7280}
.imh-resume-actions{display:flex;flex-direction:column;gap:8px}
.imh-secondary-btn{display:inline-flex;align-items:center;justify-content:center;padding:10px 16px;min-height:44px;width:100%;border:1px solid #cbd5e1;border-radius:8px;background:#fff;color:#334155 !important;text-decoration:none !important;font-size:.82rem;font-weight:700;transition:background-color 120ms ease,border-color 120ms ease}
.imh-secondary-btn:hover{background:#f8fafc;color:#0f172a !important}
.imh-secondary-btn:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(37,99,235,0.25)}
.imh-secondary-btn:active{background:#f1f5f9}
.imh-footnote{text-align:center;font-size:.78rem;color:#9ca3af;margin:0}
.imh-footnote--spaced{margin-top:16px}
.imh-picker-list{display:flex;flex-direction:column;gap:0}
.imh-picker-row{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:14px 0;border-bottom:1px solid #f3f4f6}
.imh-picker-row:last-child{border-bottom:none}
.imh-picker-row-title{margin:0 0 3px;font-size:.95rem;font-weight:700;color:#111827}
.imh-picker-row-sub{margin:0;font-size:.8rem;color:#6b7280}
.imh-picker-btn{flex-shrink:0;display:inline-flex;align-items:center;justify-content:center;width:100%;padding:9px 18px;min-height:44px;background:linear-gradient(180deg,#27c184 0%,#1eb06f 100%);box-shadow:0 10px 24px rgba(30,176,111,.2);color:#fff !important;border:0;border-radius:8px;font-size:.82rem;font-weight:700;text-decoration:none !important;white-space:nowrap;cursor:pointer;transition:transform .15s ease,box-shadow .15s ease}
.imh-picker-btn:hover{box-shadow:0 12px 26px rgba(30,176,111,.24);transform:translateY(-1px)}
.imh-picker-btn:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(30,176,111,0.40);transform:translateY(-1px)}
.imh-picker-btn:active{transform:scale(0.97);box-shadow:0 4px 12px rgba(30,176,111,.18)}

/* ==========================================
 * 5. PREFLIGHT STEP SHELL — mobile-first defaults
 * ========================================== */
.ielts-mock-step-shell{font-family:-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,sans-serif;color:#111827}
.ielts-mock-step-topbar{display:flex;flex-direction:column;align-items:center;gap:10px;margin:8px 0 24px}
.ielts-mock-step-title{text-align:center;font-size:1.8rem;font-weight:800;letter-spacing:-.03em;color:#111827;margin:0}
.ielts-mock-stepper-block{display:flex;flex-direction:column;align-items:center;gap:8px}
.ielts-mock-step-track{display:flex;align-items:center;justify-content:center;gap:8px;margin:0}
.ielts-mock-dot{width:34px;height:8px;border-radius:999px;background:#dbe4ef}
.ielts-mock-dot.active{background:linear-gradient(90deg,#2563eb 0%,#1d4ed8 100%);box-shadow:0 4px 16px rgba(37,99,235,.18)}
.ielts-mock-step-label{text-align:center;color:#64748b;font-size:.8rem;font-weight:700;letter-spacing:.12em;text-transform:uppercase;margin:0}
.ielts-mock-step-card{background:#fff;border:1px solid #e5e7eb;border-radius:14px;padding:18px;box-shadow:0 4px 24px rgba(0,0,0,.07)}
.ielts-mock-step-card-header{display:flex;flex-direction:column;align-items:center;gap:13px;margin-bottom:20px;padding-right:0}
.ielts-mock-step-header-copy{max-width:540px;margin:0 auto;text-align:center}
.ielts-mock-step-header-actions{position:static;display:flex;flex-direction:column;align-items:center;width:100%}
.ielts-mock-step-eyebrow{margin:0 0 6px;color:#64748b;font-size:.78rem;font-weight:800;letter-spacing:.12em;text-transform:uppercase}
.ielts-mock-step-heading{margin:0;font-size:1.18rem;line-height:1.25;font-weight:700;letter-spacing:-.02em;color:#111827}
.ielts-mock-step-badge,.ielts-mock-step-module-tag{display:inline-flex;align-items:center;justify-content:center;padding:8px 12px;border-radius:8px;font-size:.74rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase;white-space:nowrap}
.ielts-mock-step-badge{background:#f8fafc;color:#334155;border:1px solid #e2e8f0}
.ielts-mock-step-module-tag{background:#fff;color:#334155;border:1px solid #cbd5e1}
.ielts-mock-step-card-body{padding:0;color:#111827}
.ielts-mock-step-layout{display:grid;grid-template-columns:1fr;gap:14px;align-items:start}
.ielts-mock-step-main,.ielts-mock-step-side{display:grid;gap:14px}
.ielts-mock-step-panel{padding:14px;border-radius:12px;border:1px solid #e5e7eb;background:#fff;box-shadow:none}
.ielts-mock-step-panel-eyebrow{margin:0 0 10px;color:#9ca3af;font-size:.74rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}
.ielts-mock-step-panel--upnext{position:static;gap:0}
.ielts-mock-step-side-kicker{margin:0 0 5px;color:#9ca3af;font-size:.74rem;font-weight:700;letter-spacing:.08em;text-transform:uppercase}
.ielts-mock-step-side-title{margin:0 0 7px;color:#111827;font-size:1rem;line-height:1.35;font-weight:700}
.ielts-mock-step-side-copy{margin:0;color:#6b7280;font-size:.86rem;line-height:1.65}
.ielts-mock-step-upnext-box{margin:13px 0 10px;background:#f8fafc;border:1px solid #e2e8f0;border-radius:8px;padding:11px 14px;font-size:.86rem;color:#374151}
.ielts-mock-step-upnext-box strong{color:#111827}
.ielts-mock-step-side-footnote{margin:11px 0 0;color:#6b7280;font-size:.8rem;line-height:1.6}
.ielts-mock-progress-list{display:grid;gap:8px}
.ielts-mock-progress-item{display:flex;align-items:flex-start;gap:10px;padding:11px 13px;border-radius:10px;background:#fff;border:1px solid #e5e7eb}
.ielts-mock-progress-item.is-active{border-color:#cbd5e1;background:#f8fafc}
.ielts-mock-progress-item.is-complete{border-color:#d1fae5;background:#f0fdf4}
.ielts-mock-progress-marker{display:inline-flex;align-items:center;justify-content:center;width:26px;height:26px;border-radius:50%;background:#f1f5f9;color:#334155;font-size:.78rem;font-weight:700;flex:0 0 auto}
.ielts-mock-progress-item.is-active .ielts-mock-progress-marker{background:#e2e8f0;color:#0f172a}
.ielts-mock-progress-item.is-complete .ielts-mock-progress-marker{background:#dcfce7;color:#166534}
.ielts-mock-progress-title{display:block;color:#111827;font-size:.88rem;font-weight:700;line-height:1.35}
.ielts-mock-progress-meta{display:block;margin-top:3px;color:#6b7280;font-size:.78rem;line-height:1.5}
.ielts-mock-spotlight{display:flex;align-items:flex-start;gap:13px;padding:13px 14px;background:#f8fafc;border:1px solid #e2e8f0;border-radius:10px}
.ielts-mock-spotlight p{margin:0;color:#374151;line-height:1.68;font-size:.88rem}
.ielts-mock-spotlight-icon{display:flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:50%;background:#fff;color:#2563eb;border:1px solid #e2e8f0;flex:0 0 auto}
.ielts-mock-spotlight-icon svg{width:20px;height:20px}
.ielts-mock-candidate-grid{display:grid;grid-template-columns:1fr;gap:8px}
.ielts-mock-candidate-card{padding:12px 14px;border-radius:10px;background:#fff;border:1px solid #e5e7eb}
.ielts-mock-candidate-label{font-size:.72rem;color:#9ca3af;text-transform:uppercase;letter-spacing:.08em;font-weight:700;margin:0 0 5px}
.ielts-mock-candidate-value{font-size:.93rem;color:#111827;font-weight:700;line-height:1.45;margin:0}
.ielts-mock-candidate-span{grid-column:1 / -1}
.ielts-mock-step-note{color:#334155;font-size:.86rem;line-height:1.68;margin:0;padding:11px 13px;background:#f8fafc;border:1px solid #e2e8f0;border-radius:8px}
.ielts-mock-step-warning{color:#92400e;font-size:.86rem;line-height:1.65;margin:0;padding:11px 13px;border-radius:8px;background:#fffbeb;border:1px solid #fde68a}
.ielts-mock-guideline-list{list-style:none;margin:0;padding:0;display:grid;gap:10px}
.ielts-mock-guideline-list li{position:relative;padding-left:18px;color:#374151;line-height:1.7;font-size:.87rem}
.ielts-mock-guideline-list li:before{content:'';position:absolute;left:0;top:.66em;width:6px;height:6px;border-radius:50%;background:#3b82f6}
.ielts-mock-step-actions{display:flex;justify-content:stretch;padding-top:2px}
.ielts-mock-step-btn{display:inline-flex;align-items:center;justify-content:center;padding:14px 20px;width:100%;min-height:44px;border-radius:10px;border:1px solid #cbd5e1;background:#fff;color:#111827;text-decoration:none;font-size:.95rem;font-weight:700;cursor:pointer;transition:background-color .15s ease,border-color .15s ease,box-shadow .15s ease,transform .15s ease}
.ielts-mock-step-btn.primary{background:linear-gradient(180deg,#27c184 0%,#1eb06f 100%);border-color:#1eb06f;color:#fff;box-shadow:0 10px 24px rgba(30,176,111,.22)}
.ielts-mock-step-btn.primary:hover{box-shadow:0 12px 26px rgba(30,176,111,.26);transform:translateY(-1px)}
.ielts-mock-step-btn:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(37,99,235,0.25)}
.ielts-mock-step-btn.primary:focus-visible{box-shadow:0 0 0 3px rgba(30,176,111,0.40)}
.ielts-mock-step-btn:active{transform:scale(0.97)}
.ielts-mock-audio-tools{display:flex;flex-direction:column;gap:12px;align-items:stretch;padding:13px 14px;background:#f8fafc;border:1px solid #e2e8f0;border-radius:10px}
.ielts-mock-audio-volume{width:100%;accent-color:#111827}
#ielts-mock-play-sound.ielts-mock-step-btn.primary{background:linear-gradient(135deg,#ef4444 0%,#dc2626 100%);border-color:#dc2626;box-shadow:0 12px 28px rgba(220,38,38,.22)}
#ielts-mock-play-sound.ielts-mock-step-btn.primary:hover{background:linear-gradient(135deg,#e33b3b 0%,#c81e1e 100%);border-color:#c81e1e;box-shadow:0 14px 30px rgba(220,38,38,.26);transform:translateY(-1px)}
.ielts-mock-inline-alert{display:none;text-align:left;font-size:.9rem;color:#b42318;margin:0;font-weight:700}

/* ==========================================
 * 6. BREAKPOINTS — mobile-first
 * ========================================== */

/* --- 480px: candidate 2-col, picker inline, auto-width buttons --- */
@media(min-width:480px){
    .ielts-mock-candidate-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
    .imh-picker-row{flex-direction:row;align-items:center;justify-content:space-between;gap:16px}
    .imh-picker-btn{width:auto;justify-content:initial}
    .imh-resume-actions{flex-direction:row;flex-wrap:wrap}
    .imh-secondary-btn{width:auto}
    .imh-entry-exit{width:auto}
    .ielts-mock-step-btn{width:auto}
    .ielts-mock-step-actions{justify-content:flex-start}
    .ielts-mock-step-shell[data-step="details"] .ielts-mock-step-actions,
    .ielts-mock-step-shell[data-step="sound"] .ielts-mock-step-actions{justify-content:center}
    .ielts-mock-audio-tools{flex-direction:row;align-items:center;flex-wrap:wrap}
    .ielts-mock-audio-volume{width:200px;flex-shrink:1}
}

/* --- 640px: larger card padding, row header actions --- */
@media(min-width:640px){
    .ielts-mock-fullscreen-shell__inner{padding:20px}
    .imh-entry-card,.ielts-mock-step-card{padding:24px}
    .imh-card{padding:24px}
    .imh-entry-panel,.imh-entry-form-card,.ielts-mock-step-panel{padding:16px}
    .imh-entry-step-dot,.ielts-mock-dot{width:42px}
    .imh-entry-head h3{font-size:1.26rem}
    .ielts-mock-step-heading{font-size:1.24rem}
    .imh-entry-head-actions{flex-direction:row;justify-content:center;gap:14px}
    .ielts-mock-step-header-actions{flex-direction:row;justify-content:center}
    .imh-entry-total{justify-content:flex-start}
    .ielts-mock-audio-volume{width:220px}
}

/* --- 768px: tablet landscape --- */
@media(min-width:768px){
    .imh-entry-duration-grid{gap:10px}
    .imh-entry-panel,.imh-entry-form-card,.ielts-mock-step-panel{padding:17px}
    .imh-entry-head h3{font-size:1.3rem}
    .ielts-mock-step-heading{font-size:1.28rem}
}

/* --- 1024px: 2-col layout, absolute header actions, desktop max-width --- */
@media(min-width:1024px){
    .ielts-mock-fullscreen-shell__inner{padding:24px}
    .imh-entry-wrap{max-width:980px;margin:0 auto}
    .ielts-mock-step-shell{max-width:980px;margin:0 auto}
    .imh-entry-card,.ielts-mock-step-card{padding:32px}
    .imh-card{padding:32px}
    .imh-entry-panel,.imh-entry-form-card,.ielts-mock-step-panel{padding:18px}
    .imh-entry-head{position:relative;flex-direction:row;justify-content:center;align-items:flex-start;padding-right:276px;gap:16px}
    .imh-entry-head-actions{position:absolute;top:0;right:0;flex-direction:row;align-items:flex-start;gap:14px;width:auto}
    .ielts-mock-step-card-header{position:relative;flex-direction:row;justify-content:center;align-items:flex-start;padding-right:176px;gap:16px}
    .ielts-mock-step-header-actions{position:absolute;top:0;right:0;flex-direction:row;width:auto}
    .imh-entry-layout{grid-template-columns:minmax(0,1.45fr) minmax(300px,.9fr);gap:18px}
    .ielts-mock-step-layout{grid-template-columns:minmax(0,1.35fr) minmax(260px,.75fr);gap:18px}
    .ielts-mock-step-main,.ielts-mock-step-side{gap:18px}
    .ielts-mock-step-panel--upnext{position:sticky;top:16px}
    .imh-entry-duration-grid{grid-template-columns:repeat(4,1fr);gap:10px}
    .imh-entry-step-dot,.ielts-mock-dot{width:48px}
    .imh-entry-head h3{font-size:1.36rem}
    .ielts-mock-step-heading{font-size:1.32rem}
}

/* --- 1366px: 14-inch primary — wider wrap, comfortable density --- */
@media(min-width:1366px){
    .imh-entry-wrap{max-width:1100px}
    .ielts-mock-step-shell{max-width:1100px}
    .imh-entry-card,.ielts-mock-step-card{padding:40px}
    .imh-entry-layout,.ielts-mock-step-layout{gap:24px}
    .imh-entry-panel,.imh-entry-form-card,.ielts-mock-step-panel{padding:24px}
    .imh-entry-duration-grid{grid-template-columns:repeat(4,1fr);gap:14px}
    .imh-entry-duration-item{padding:16px 8px 14px}
    .imh-entry-duration-badge{width:46px;height:46px}
    .imh-entry-duration-badge svg{width:20px;height:20px}
    .imh-entry-duration-value{font-size:.95rem}
    .imh-entry-field-grid{grid-template-columns:repeat(2,1fr)}
}
