/* =========================================================
   Citizen App Simulator - Realistic Smartphone Mockup & Dual Phone Layout
   iPhone 16 Pro Style Frame & P2P Ownership Transfer Simulator
   ========================================================= */

.mobile-sim-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

/* Mode Switcher: Single Phone vs Dual Phone */
.sim-controls-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 960px;
    background: rgba(14, 22, 38, 0.7);
    border: 1px solid var(--border-subtle);
    padding: 0.75rem 1.5rem;
    border-radius: 14px;
    backdrop-filter: blur(10px);
}

.sim-mode-toggle {
    display: flex;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-subtle);
    border-radius: 10px;
    padding: 0.25rem;
    gap: 0.25rem;
}

.sim-mode-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    padding: 0.45rem 1rem;
    border-radius: 8px;
    font-family: var(--font-ar);
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition-smooth);
}

.sim-mode-btn.active {
    background: var(--primary);
    color: #070B14;
    box-shadow: 0 2px 10px rgba(0, 240, 255, 0.3);
}

/* Dual Phones Stage */
.phones-stage {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    width: 100%;
    position: relative;
    padding: 1rem 0;
    flex-wrap: wrap;
}

/* Connecting Bridge Arrow between Phones */
.transfer-bridge-connector {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 1rem;
    background: rgba(14, 22, 38, 0.85);
    border: 1px solid rgba(0, 240, 255, 0.25);
    border-radius: 16px;
    box-shadow: 0 0 25px rgba(0, 240, 255, 0.15);
    z-index: 10;
}

.bridge-pulse-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 15px var(--primary);
    animation: bridgePulse 1.5s infinite alternate;
}

@keyframes bridgePulse {
    0% { transform: scale(0.8); opacity: 0.5; }
    100% { transform: scale(1.3); opacity: 1; }
}

.bridge-label {
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--primary);
    text-align: center;
    max-width: 110px;
    line-height: 1.3;
}

/* Realistic Smartphone Frame (iPhone 16 Pro Style) */
.phone-device-frame {
    width: 380px;
    height: 760px;
    background: #000000;
    border-radius: 52px;
    box-shadow: 
        0 0 0 4px #1E293B,
        0 0 0 7px #0F172A,
        0 25px 60px -10px rgba(0, 0, 0, 0.85),
        0 0 35px rgba(0, 240, 255, 0.12);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border: 3px solid #334155;
    flex-shrink: 0;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.phone-device-frame.vibrate {
    animation: phoneShake 0.6s ease-in-out;
}

@keyframes phoneShake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px) rotate(-1deg); }
    40%, 80% { transform: translateX(6px) rotate(1deg); }
}

/* Phone Role Tag (Seller / Buyer) */
.phone-role-header {
    position: absolute;
    top: -38px;
    right: 50%;
    transform: translateX(50%);
    background: rgba(14, 22, 38, 0.9);
    border: 1px solid var(--border-subtle);
    padding: 0.3rem 1rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

/* Dynamic Island & Notch */
.phone-dynamic-island {
    position: absolute;
    top: 11px;
    right: 50%;
    transform: translateX(50%);
    width: 105px;
    height: 28px;
    background: #000000;
    border-radius: 20px;
    z-index: 50;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10px;
}

.phone-dynamic-island.expanded {
    width: 90%;
    height: 65px;
    background: #0F172A;
    border: 1px solid var(--primary);
    box-shadow: 0 10px 30px rgba(0, 240, 255, 0.35);
}

/* Phone Status Bar */
.phone-status-bar {
    height: 48px;
    padding: 12px 24px 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    font-family: var(--font-en);
    font-weight: 700;
    color: #FFFFFF;
    z-index: 40;
    user-select: none;
}

.status-bar-icons {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

/* Phone Screen Content */
.phone-screen-viewport {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 1.25rem 1.5rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    scrollbar-width: none;
    position: relative;
    background: #070D18;
}
.phone-screen-viewport::-webkit-scrollbar { display: none; }

/* Phone Home Indicator */
.phone-home-indicator {
    width: 120px;
    height: 4px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 999px;
    margin: 8px auto 6px auto;
    flex-shrink: 0;
}

/* Push Notification Banner Inside Phone */
.phone-push-banner {
    background: rgba(30, 41, 59, 0.95);
    border: 1px solid var(--primary);
    border-radius: 16px;
    padding: 0.85rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
    animation: bannerDrop 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    cursor: pointer;
    margin-bottom: 0.5rem;
}

@keyframes bannerDrop {
    from { transform: translateY(-30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.push-banner-icon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: linear-gradient(135deg, #00F0FF, #3B82F6);
    color: #070B14;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.push-banner-content h5 {
    font-size: 0.82rem;
    font-weight: 800;
    color: #FFF;
}

.push-banner-content p {
    font-size: 0.72rem;
    color: var(--text-muted);
}

/* User Profile Header in Phone */
.phone-user-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.user-nav-profile {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.user-nav-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #1E293B;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    border: 1px solid var(--border-subtle);
}

.user-nav-info h4 {
    font-size: 0.88rem;
    font-weight: 800;
    color: #FFF;
}

.user-nav-info span {
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* Vehicle Digital Wallet Card */
.digital-vehicle-card {
    background: linear-gradient(135deg, #0F172A 0%, #1E293B 50%, #09101D 100%);
    border: 1px solid rgba(0, 240, 255, 0.3);
    border-radius: 20px;
    padding: 1.2rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    transition: transform 0.3s ease;
}

.digital-vehicle-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0, 240, 255, 0.1) 0%, transparent 60%);
    pointer-events: none;
}

.card-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-ministry-badge {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.72rem;
    font-weight: 800;
    color: #94A3B8;
}

.card-nfc-chip {
    width: 28px;
    height: 22px;
    background: linear-gradient(135deg, #F59E0B, #FBBF24);
    border-radius: 4px;
    border: 1px solid #78350F;
    box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.4);
}

.card-car-details h3 {
    font-size: 1.15rem;
    font-weight: 800;
    color: #FFF;
}

.card-car-details .vin-tag {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--primary);
    letter-spacing: 1px;
}

/* Card Plate Graphic */
.card-mini-plate {
    background: #FFFFFF;
    color: #000;
    border-radius: 6px;
    padding: 0.25rem 0.6rem;
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    font-family: var(--font-en);
    font-weight: 900;
    font-size: 1.1rem;
    border: 2px solid #0F172A;
    margin: 0.4rem 0;
}

.card-mini-plate span {
    font-family: var(--font-ar);
    font-size: 0.75rem;
    color: #475569;
}

/* Card Buttons Bar */
.card-action-btns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-top: 0.4rem;
}

.btn-card-action {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-subtle);
    color: #FFF;
    padding: 0.45rem 0.6rem;
    border-radius: 10px;
    font-family: var(--font-ar);
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    transition: var(--transition-fast);
}

.btn-card-action:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-card-action.transfer-cta {
    background: linear-gradient(135deg, #00F0FF, #0284C7);
    color: #070B14;
    border: none;
    font-weight: 800;
}

.btn-card-action.transfer-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 240, 255, 0.4);
}

/* Transfer Verification Modal Dialog inside Phone */
.phone-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(7, 11, 20, 0.88);
    backdrop-filter: blur(12px);
    z-index: 60;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    animation: fadeInModal 0.25s ease-out;
}

.phone-modal-sheet {
    background: #0E172A;
    border-top: 1px solid var(--border-subtle);
    border-radius: 24px 24px 0 0;
    padding: 1.5rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-height: 88%;
    overflow-y: auto;
}

@keyframes fadeInModal {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Mobile Responsiveness for Simulator Stage & Phone Mockups */
@media (max-width: 768px) {
    .phone-device-frame {
        width: 100%;
        max-width: 360px;
        height: 680px;
        border-radius: 40px;
    }
    .sim-controls-bar {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 1rem;
    }
    .phones-stage {
        gap: 1.5rem;
        padding: 0.5rem 0;
    }
    .transfer-bridge-connector {
        transform: rotate(90deg);
        margin: 0.5rem 0;
    }
}

@media (max-width: 480px) {
    .phone-device-frame {
        max-width: 100%;
        height: 620px;
        border-radius: 32px;
        box-shadow: 0 0 0 2px #1E293B, 0 10px 30px rgba(0, 0, 0, 0.8);
    }
    .sim-mode-toggle {
        width: 100%;
    }
    .sim-mode-btn {
        flex: 1;
        justify-content: center;
        font-size: 0.78rem;
        padding: 0.4rem 0.6rem;
    }
}

