/* ============================================
   AfiaSync Product Showcase
   Programmatic UI mockup — no screenshots needed
   ============================================ */

/* --- Layout & Container --- */
.showcase {
    margin-top: 6rem;
    display: flex;
    justify-content: center;
    perspective: 1200px;
}

.showcase-frame {
    width: 90%;
    max-width: 108rem;
    background: rgba(255,255,255,0.06);
    border-radius: 20px;
    overflow: hidden;
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.12);
    box-shadow:
        0 24px 80px rgba(0,0,0,0.25),
        0 0 0 1px rgba(255,255,255,0.05) inset;
}

.showcase-toolbar {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 1.2rem 1.6rem;
    background: rgba(255,255,255,0.06);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.showcase-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.showcase-url {
    margin-left: 1.2rem;
    font-size: 1.3rem;
    color: rgba(255,255,255,0.45);
    background: rgba(255,255,255,0.06);
    padding: 0.4rem 1.6rem;
    border-radius: 6px;
    flex: 1;
    max-width: 26rem;
    font-family: 'Satoshi', sans-serif;
    letter-spacing: 0.02em;
}

.showcase-url svg {
    vertical-align: middle;
    margin-right: 0.4rem;
    opacity: 0.5;
}

.showcase-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 52rem;
}

/* ============================================
   LEFT PANEL — Recording Screen (Dark)
   ============================================ */
.showcase-recording {
    background: #1A1A2E;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3.2rem 2.4rem;
    gap: 2rem;
}

/* Radial glow */
.showcase-recording::before {
    content: '';
    position: absolute;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    width: 400px;
    height: 320px;
    background: radial-gradient(ellipse at center, rgba(127,86,217,0.14) 0%, transparent 70%);
    pointer-events: none;
}

/* Patient info header */
.sc-patient {
    text-align: center;
    z-index: 1;
}

.sc-patient-name {
    font-size: 1.5rem;
    font-weight: 600;
    color: rgba(255,255,255,0.9);
    letter-spacing: 0.01em;
}

.sc-patient-type {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.4);
    margin-top: 0.2rem;
}

/* Recording status badge */
.sc-status {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: rgba(239,68,68,0.18);
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: 20px;
    padding: 0.5rem 1.4rem;
    z-index: 1;
}

.sc-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #EF4444;
    box-shadow: 0 0 8px rgba(239,68,68,0.6);
    animation: sc-pulse 1.5s ease-in-out infinite;
}

.sc-status-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: #EF4444;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

@keyframes sc-pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 6px rgba(239,68,68,0.6); }
    50% { opacity: 0.4; box-shadow: 0 0 2px rgba(239,68,68,0.3); }
}

/* Timer */
.sc-timer {
    font-size: 5.6rem;
    font-weight: 200;
    color: #fff;
    font-family: 'Courier New', 'SF Mono', monospace;
    letter-spacing: 4px;
    z-index: 1;
    line-height: 1;
}

/* Waveform */
.sc-waveform-wrap {
    width: 100%;
    max-width: 340px;
    height: 72px;
    background: rgba(255,255,255,0.035);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 0 16px;
    z-index: 1;
    box-shadow: 0 0 24px rgba(127,86,217,0.06);
}

.sc-bar {
    width: 4px;
    border-radius: 4px;
    background: #7F56D9;
    transition: height 0.15s ease;
    animation: sc-wave 1.8s ease-in-out infinite;
}

/* Generate varied wave animation for each bar */
.sc-bar:nth-child(1)  { height: 12px; animation-delay: 0.00s; opacity: 0.6; }
.sc-bar:nth-child(2)  { height: 18px; animation-delay: 0.05s; opacity: 0.7; }
.sc-bar:nth-child(3)  { height: 28px; animation-delay: 0.10s; opacity: 0.8; }
.sc-bar:nth-child(4)  { height: 40px; animation-delay: 0.15s; opacity: 0.9; }
.sc-bar:nth-child(5)  { height: 52px; animation-delay: 0.20s; opacity: 1.0; }
.sc-bar:nth-child(6)  { height: 44px; animation-delay: 0.25s; opacity: 0.9; }
.sc-bar:nth-child(7)  { height: 32px; animation-delay: 0.30s; opacity: 0.8; }
.sc-bar:nth-child(8)  { height: 20px; animation-delay: 0.35s; opacity: 0.7; }
.sc-bar:nth-child(9)  { height: 36px; animation-delay: 0.40s; opacity: 0.85; }
.sc-bar:nth-child(10) { height: 50px; animation-delay: 0.45s; opacity: 0.95; }
.sc-bar:nth-child(11) { height: 42px; animation-delay: 0.50s; opacity: 0.9; }
.sc-bar:nth-child(12) { height: 28px; animation-delay: 0.55s; opacity: 0.8; }
.sc-bar:nth-child(13) { height: 16px; animation-delay: 0.60s; opacity: 0.65; }
.sc-bar:nth-child(14) { height: 24px; animation-delay: 0.65s; opacity: 0.75; }
.sc-bar:nth-child(15) { height: 38px; animation-delay: 0.70s; opacity: 0.85; }
.sc-bar:nth-child(16) { height: 48px; animation-delay: 0.75s; opacity: 0.95; }
.sc-bar:nth-child(17) { height: 36px; animation-delay: 0.80s; opacity: 0.85; }
.sc-bar:nth-child(18) { height: 22px; animation-delay: 0.85s; opacity: 0.7; }
.sc-bar:nth-child(19) { height: 14px; animation-delay: 0.90s; opacity: 0.6; }
.sc-bar:nth-child(20) { height: 30px; animation-delay: 0.95s; opacity: 0.8; }
.sc-bar:nth-child(21) { height: 46px; animation-delay: 1.00s; opacity: 0.9; }
.sc-bar:nth-child(22) { height: 38px; animation-delay: 1.05s; opacity: 0.85; }
.sc-bar:nth-child(23) { height: 26px; animation-delay: 1.10s; opacity: 0.75; }
.sc-bar:nth-child(24) { height: 18px; animation-delay: 1.15s; opacity: 0.65; }
.sc-bar:nth-child(25) { height: 34px; animation-delay: 1.20s; opacity: 0.85; }
.sc-bar:nth-child(26) { height: 44px; animation-delay: 1.25s; opacity: 0.9; }
.sc-bar:nth-child(27) { height: 30px; animation-delay: 1.30s; opacity: 0.8; }
.sc-bar:nth-child(28) { height: 20px; animation-delay: 1.35s; opacity: 0.7; }
.sc-bar:nth-child(29) { height: 10px; animation-delay: 1.40s; opacity: 0.55; }
.sc-bar:nth-child(30) { height: 16px; animation-delay: 1.45s; opacity: 0.65; }

@keyframes sc-wave {
    0%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.35); }
}

/* Mic quality badge */
.sc-mic-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(34,197,94,0.1);
    border: 1px solid rgba(34,197,94,0.25);
    border-radius: 999px;
    padding: 0.4rem 1.2rem;
    z-index: 1;
}

.sc-mic-badge svg {
    color: #22C55E;
    flex-shrink: 0;
}

.sc-mic-badge span {
    font-size: 1.1rem;
    font-weight: 600;
    color: #22C55E;
}

/* Control buttons */
.sc-controls {
    display: flex;
    align-items: center;
    gap: 2rem;
    z-index: 1;
    margin-top: 0.4rem;
}

.sc-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: none;
    cursor: default;
}

.sc-btn-cancel {
    width: 50px;
    height: 50px;
    background: transparent;
    border: 1.5px solid rgba(251,146,60,0.5);
}

.sc-btn-cancel svg {
    color: #FB923C;
}

.sc-btn-pause {
    width: 54px;
    height: 54px;
    background: rgba(255,255,255,0.06);
    border: 1.5px solid rgba(255,255,255,0.2);
}

.sc-btn-pause svg {
    color: rgba(255,255,255,0.6);
}

.sc-btn-end {
    width: 64px;
    height: 64px;
    background: #EF4444;
    box-shadow: 0 0 20px rgba(239,68,68,0.35), 0 4px 12px rgba(0,0,0,0.3);
}

.sc-btn-end svg {
    color: #fff;
}

.sc-btn-label {
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    margin-top: 0.4rem;
}

.sc-ctrl-group {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.sc-ctrl-group:nth-child(1) .sc-btn-label { color: #FB923C; }
.sc-ctrl-group:nth-child(2) .sc-btn-label { color: rgba(255,255,255,0.45); }
.sc-ctrl-group:nth-child(3) .sc-btn-label { color: rgba(255,255,255,0.8); }

/* Trust line */
.sc-trust {
    font-size: 1rem;
    color: rgba(255,255,255,0.2);
    letter-spacing: 0.3px;
    z-index: 1;
    margin-top: 0.4rem;
}

.sc-trust svg {
    vertical-align: middle;
    margin-right: 0.3rem;
    opacity: 0.6;
}

/* ============================================
   RIGHT PANEL — SOAP Note (Light)
   ============================================ */
.showcase-note {
    background: #FAFAFA;
    padding: 2.4rem;
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: hidden;
    position: relative;
}

/* Note header */
.sc-note-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.6rem;
    padding-bottom: 1.2rem;
    border-bottom: 1px solid #E5E7EB;
}

.sc-note-header-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sc-note-format-icon {
    width: 36px;
    height: 36px;
    background: rgba(127,86,217,0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sc-note-format-icon svg {
    color: #7F56D9;
}

.sc-note-title {
    font-size: 1.6rem;
    font-weight: 600;
    color: #7F56D9;
}

.sc-note-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #22C55E;
    background: rgba(34,197,94,0.08);
    padding: 0.3rem 0.8rem;
    border-radius: 6px;
}

.sc-note-badge svg {
    flex-shrink: 0;
}

.sc-note-confidence {
    font-size: 1.1rem;
    color: #9CA3AF;
}

/* Note card */
.sc-note-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #E5E7EB;
    overflow: hidden;
    flex: 1;
}

/* Section */
.sc-section {
    border-top: 1px solid #E5E7EB;
}

.sc-section:first-child {
    border-top: none;
}

.sc-section-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.8rem 1.2rem;
    background: #FAFAFA;
}

.sc-section-header svg {
    color: #6B7280;
    flex-shrink: 0;
}

.sc-section-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: #000;
    flex: 1;
}

.sc-section-copy {
    color: #9CA3AF;
    cursor: default;
    display: flex;
}

.sc-section-body {
    padding: 1rem 1.2rem;
    font-size: 1.3rem;
    line-height: 1.65;
    color: #374151;
}

.sc-section-body p {
    margin: 0 0 0.6rem;
    font-size: 1.3rem;
    line-height: 1.65;
}

.sc-section-body p:last-child {
    margin-bottom: 0;
}

.sc-section-body strong {
    color: #000;
    font-weight: 600;
    display: block;
    margin-top: 0.6rem;
    margin-bottom: 0.2rem;
    font-size: 1.25rem;
}

.sc-section-body strong:first-child {
    margin-top: 0;
}

.sc-section-body .sc-bullet {
    padding-left: 1.4rem;
    position: relative;
}

.sc-section-body .sc-bullet::before {
    content: '•';
    position: absolute;
    left: 0.2rem;
    color: #9CA3AF;
}

/* Action buttons at bottom */
.sc-note-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-top: 1.4rem;
    justify-content: flex-end;
}

.sc-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.2rem;
    font-weight: 500;
    padding: 0.6rem 1.4rem;
    border-radius: 8px;
    border: none;
    cursor: default;
    font-family: 'Satoshi', sans-serif;
}

.sc-action-copy {
    background: #7F56D9;
    color: #fff;
}

.sc-action-export {
    background: transparent;
    border: 1px solid #E5E7EB;
    color: #374151;
}

.sc-action-export svg {
    color: #6B7280;
}

/* ============================================
   Fade overlay to suggest more content below
   ============================================ */
.showcase-note::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to bottom, transparent, #FAFAFA);
    pointer-events: none;
}

/* ============================================
   Labels above panels
   ============================================ */
.showcase-label {
    position: absolute;
    top: 1.2rem;
    right: 1.2rem;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 0.3rem 0.8rem;
    border-radius: 6px;
    z-index: 2;
}

.showcase-recording .showcase-label {
    background: rgba(239,68,68,0.15);
    color: #EF4444;
}

.showcase-note .showcase-label {
    background: rgba(34,197,94,0.1);
    color: #22C55E;
}

/* ============================================
   Responsive
   ============================================ */
@media screen and (max-width: 900px) {
    .showcase-body {
        grid-template-columns: 1fr;
    }
    
    .showcase-recording {
        padding: 2.4rem 1.6rem;
        min-height: 44rem;
    }
    
    .sc-timer {
        font-size: 4rem;
    }
    
    .sc-waveform-wrap {
        max-width: 280px;
        height: 56px;
    }
    
    .showcase-frame {
        width: 96%;
    }
}

@media screen and (max-width: 767px) {
    .showcase {
        margin-top: 3rem;
    }
    
    .showcase-frame {
        width: 100%;
        border-radius: 14px;
    }
    
    .showcase-toolbar {
        padding: 0.8rem 1.2rem;
    }
    
    .showcase-dot {
        width: 8px;
        height: 8px;
    }
    
    .showcase-url {
        font-size: 1.1rem;
    }
    
    .sc-timer {
        font-size: 3.4rem;
        letter-spacing: 2px;
    }
    
    .sc-waveform-wrap {
        max-width: 240px;
        height: 48px;
        gap: 2px;
        padding: 0 10px;
    }
    
    .sc-bar {
        width: 3px;
    }
    
    .sc-controls {
        gap: 1.4rem;
    }
    
    .sc-btn-cancel { width: 42px; height: 42px; }
    .sc-btn-pause  { width: 46px; height: 46px; }
    .sc-btn-end    { width: 54px; height: 54px; }
    
    .showcase-note {
        padding: 1.6rem;
    }
    
    .sc-note-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8rem;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .sc-bar { animation: none; }
    .sc-status-dot { animation: none; }
    .sw-spinner { animation: none; }
    .sw-ai-bar-fill { animation: none; }
    .sw-mini-wave span { animation: none; }
    .sw-rec-dot { animation: none; }
}


/* ============================================
   STEP WIDGETS — Mini CSS illustrations
   for How It Works section
   ============================================ */

.step-widget {
    margin-top: 2rem;
    display: flex;
    justify-content: center;
}

/* --- Step 1: Recording Widget --- */
.sw-record {
    background: #1A1A2E;
    border-radius: 16px;
    padding: 2rem 2.4rem;
    width: 100%;
    max-width: 36rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.4rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
    position: relative;
    overflow: hidden;
}

.sw-record::before {
    content: '';
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 160px;
    background: radial-gradient(ellipse at center, rgba(127,86,217,0.12) 0%, transparent 70%);
    pointer-events: none;
}

.sw-record-top {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    z-index: 1;
}

.sw-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(127,86,217,0.25);
    color: #A78BFA;
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sw-record-info {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.sw-record-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: rgba(255,255,255,0.85);
}

.sw-record-visit {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.35);
}

.sw-rec-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(239,68,68,0.15);
    border: 1px solid rgba(239,68,68,0.3);
    border-radius: 16px;
    padding: 0.3rem 1rem;
    font-size: 1rem;
    font-weight: 700;
    color: #EF4444;
    letter-spacing: 1px;
}

.sw-rec-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #EF4444;
    box-shadow: 0 0 6px rgba(239,68,68,0.6);
    animation: sc-pulse 1.5s ease-in-out infinite;
}

.sw-timer-row {
    z-index: 1;
}

.sw-timer {
    font-size: 3.6rem;
    font-weight: 200;
    color: #fff;
    font-family: 'Courier New', 'SF Mono', monospace;
    letter-spacing: 3px;
    line-height: 1;
}

.sw-mini-wave {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2.5px;
    height: 40px;
    width: 100%;
    max-width: 22rem;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 12px;
    padding: 0 12px;
    z-index: 1;
}

.sw-mini-wave span {
    width: 3px;
    border-radius: 3px;
    background: #7F56D9;
    animation: sc-wave 1.8s ease-in-out infinite;
}

.sw-mini-wave span:nth-child(1)  { height: 8px;  animation-delay: 0.00s; opacity: 0.5; }
.sw-mini-wave span:nth-child(2)  { height: 14px; animation-delay: 0.08s; opacity: 0.6; }
.sw-mini-wave span:nth-child(3)  { height: 22px; animation-delay: 0.16s; opacity: 0.8; }
.sw-mini-wave span:nth-child(4)  { height: 32px; animation-delay: 0.24s; opacity: 0.9; }
.sw-mini-wave span:nth-child(5)  { height: 26px; animation-delay: 0.32s; opacity: 0.85; }
.sw-mini-wave span:nth-child(6)  { height: 18px; animation-delay: 0.40s; opacity: 0.7; }
.sw-mini-wave span:nth-child(7)  { height: 12px; animation-delay: 0.48s; opacity: 0.55; }
.sw-mini-wave span:nth-child(8)  { height: 20px; animation-delay: 0.56s; opacity: 0.75; }
.sw-mini-wave span:nth-child(9)  { height: 30px; animation-delay: 0.64s; opacity: 0.9; }
.sw-mini-wave span:nth-child(10) { height: 24px; animation-delay: 0.72s; opacity: 0.8; }
.sw-mini-wave span:nth-child(11) { height: 16px; animation-delay: 0.80s; opacity: 0.65; }
.sw-mini-wave span:nth-child(12) { height: 10px; animation-delay: 0.88s; opacity: 0.5; }
.sw-mini-wave span:nth-child(13) { height: 18px; animation-delay: 0.96s; opacity: 0.7; }
.sw-mini-wave span:nth-child(14) { height: 28px; animation-delay: 1.04s; opacity: 0.85; }
.sw-mini-wave span:nth-child(15) { height: 20px; animation-delay: 1.12s; opacity: 0.75; }
.sw-mini-wave span:nth-child(16) { height: 14px; animation-delay: 1.20s; opacity: 0.6; }
.sw-mini-wave span:nth-child(17) { height: 8px;  animation-delay: 1.28s; opacity: 0.5; }
.sw-mini-wave span:nth-child(18) { height: 16px; animation-delay: 1.36s; opacity: 0.65; }
.sw-mini-wave span:nth-child(19) { height: 24px; animation-delay: 1.44s; opacity: 0.8; }
.sw-mini-wave span:nth-child(20) { height: 12px; animation-delay: 1.52s; opacity: 0.55; }

.sw-record-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #EF4444;
    border-radius: 999px;
    padding: 0.6rem 2rem;
    box-shadow: 0 0 16px rgba(239,68,68,0.3);
    z-index: 1;
}

.sw-record-btn span {
    font-size: 1.2rem;
    font-weight: 600;
    color: #fff;
}

/* --- Step 2: AI Processing Widget --- */
.sw-ai {
    background: #1A1A2E;
    border-radius: 16px;
    padding: 2rem 2.4rem;
    width: 100%;
    max-width: 36rem;
    display: flex;
    flex-direction: column;
    gap: 1.6rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.sw-ai-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.4rem;
    font-weight: 600;
    color: #A78BFA;
}

.sw-ai-steps {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.sw-ai-step {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 1.2rem;
    color: rgba(255,255,255,0.4);
}

.sw-ai-step.done {
    color: rgba(255,255,255,0.7);
}

.sw-ai-step.active {
    color: rgba(255,255,255,0.9);
}

.sw-spinner {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(127,86,217,0.25);
    border-top-color: #7F56D9;
    border-radius: 50%;
    animation: sw-spin 0.8s linear infinite;
    flex-shrink: 0;
}

@keyframes sw-spin {
    to { transform: rotate(360deg); }
}

.sw-ai-bar-wrap {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.sw-ai-bar {
    flex: 1;
    height: 6px;
    background: rgba(255,255,255,0.06);
    border-radius: 3px;
    overflow: hidden;
}

.sw-ai-bar-fill {
    width: 87%;
    height: 100%;
    background: linear-gradient(90deg, #7F56D9, #A78BFA);
    border-radius: 3px;
    animation: sw-bar-pulse 2s ease-in-out infinite;
}

@keyframes sw-bar-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.sw-ai-pct {
    font-size: 1.2rem;
    font-weight: 700;
    color: #A78BFA;
    min-width: 3rem;
    text-align: right;
}

/* --- Step 3: Review & Sign Widget --- */
.sw-review {
    background: #fff;
    border-radius: 16px;
    padding: 2rem 2.4rem;
    width: 100%;
    max-width: 36rem;
    display: flex;
    flex-direction: column;
    gap: 1.4rem;
    box-shadow: 0 8px 32px rgba(0,0,0,0.08);
    border: 1px solid #E5E7EB;
}

.sw-review-header {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.sw-review-title {
    font-size: 1.4rem;
    font-weight: 600;
    color: #7F56D9;
    flex: 1;
}

.sw-review-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: #22C55E;
    background: rgba(34,197,94,0.08);
    padding: 0.25rem 0.8rem;
    border-radius: 6px;
}

.sw-review-sections {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.sw-review-sec {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
}

.sw-sec-label {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: rgba(127,86,217,0.1);
    color: #7F56D9;
    font-size: 1.1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.sw-sec-lines {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 4px;
}

.sw-sec-lines span {
    display: block;
    height: 6px;
    background: #E5E7EB;
    border-radius: 3px;
    width: 100%;
}

.sw-review-actions {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    justify-content: flex-end;
    margin-top: 0.4rem;
}

.sw-btn-edit {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 1.2rem;
    font-weight: 500;
    color: #6B7280;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    padding: 0.5rem 1.2rem;
}

.sw-btn-edit svg {
    color: #6B7280;
}

.sw-btn-sign {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 1.2rem;
    font-weight: 600;
    color: #fff;
    background: #22C55E;
    border-radius: 8px;
    padding: 0.5rem 1.2rem;
    box-shadow: 0 2px 8px rgba(34,197,94,0.25);
}

.sw-btn-sign svg {
    color: #fff;
}

/* --- Step widgets responsive --- */
@media screen and (max-width: 767px) {
    .sw-record, .sw-ai, .sw-review {
        max-width: 100%;
        padding: 1.6rem;
    }
    
    .sw-timer {
        font-size: 2.8rem;
    }
    
    .sw-mini-wave {
        max-width: 100%;
    }
}