/* Shared toolbar styles */
.call-toolbar,
.maps-toolbar,
.banking-toolbar,
.safari-toolbar,
.memory-toolbar,
.health-toolbar,
.parole-toolbar,
.voice-toolbar,
.calendar-toolbar,
.instagram-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    border-bottom: 1px solid #e5e5e5;
}

.call-toolbar,
.safari-toolbar { background: #f7f7f7; }

.calendar-toolbar,
.instagram-toolbar { background: #fff; }

.maps-toolbar {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 10;
    border-bottom: none;
}

.health-toolbar {
    border-bottom: none;
}

.banking-toolbar { background: #fff; }

/* Shared title styles */
.call-title,
.maps-title,
.banking-title,
.safari-title,
.memory-title,
.health-title,
.parole-title,
.voice-title,
.calendar-title,
.instagram-title {
    font-weight: 700;
    font-size: 16px;
    color: #111;
    margin: 0 auto;
}

/* Shared content area styles */
.call-content,
.banking-content {
    position: absolute;
    top: 50px; /* below toolbar */
    left: 0;
    right: 0;
    bottom: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: #fff;
    padding-bottom: 24px; /* space for home indicator */
}

.call-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    background: #fff;
}
.history-main {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}
.call-month-header {
    padding: 12px 16px;
    font-weight: 700;
    font-size: 14px;
    color: #333;
    background: #f5f5f5;
    border-top: 1px solid #e0e0e0;
    border-bottom: 1px solid #e0e0e0;
    list-style: none;
    margin: 8px 0 0 0;
}

.call-date-header {
    padding: 10px 16px;
    font-weight: 600;
    font-size: 13px;
    color: #555;
    background: #fafafa;
    border-bottom: 1px solid #f0f0f0;
    list-style: none;
    text-align: center;
}

.call-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    background: #fff;
    list-style: none;
}
.call-item:last-child { border-bottom: none; }
.call-avatar { width: 36px; height: 36px; border-radius: 50%; background: #e3e3e3; display:flex; align-items:center; justify-content:center; font-weight:600; color:#555; }
.call-info { flex: 1; min-width: 0; }
.call-name { font-size: 14px; color: #111; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.call-meta { font-size: 12px; color: #666; }
.call-type { font-size: 12px; color: #007AFF; flex-shrink: 0; }

/* Maps App */
.maps-container {
    position: absolute;
    top: 44px; /* below status bar */
    left: 0;
    right: 0;
    bottom: 0;
    background: #e8ebe8;
    overflow: hidden;
}

.maps-view {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #c8dcc8 0%, #e8ebe8 50%, #d8e4d8 100%);
    position: relative;
}

.maps-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(to right, rgba(0,0,0,0.03) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0,0,0,0.03) 1px, transparent 1px);
    background-size: 50px 50px;
}

.location-pin {
    position: absolute;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -100%);
    width: 32px;
    height: 40px;
    z-index: 5;
}

.location-info {
    position: absolute;
    bottom: 80px;
    left: 16px;
    right: 16px;
    background: #fff;
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 6;
}

.location-label {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.location-address {
    font-size: 15px;
    color: #111;
    font-weight: 600;
    margin-bottom: 4px;
}

.location-time {
    font-size: 12px;
    color: #666;
}

/* Banking App */
.banking-content {
    position: absolute;
    top: 44px;
    left: 0;
    right: 0;
    bottom: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: #f5f5f7;
    padding-bottom: 24px;
}

.balance-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 16px;
    padding: 20px;
    border-radius: 16px;
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.balance-label {
    font-size: 13px;
    opacity: 0.9;
    margin-bottom: 8px;
}

.balance-amount {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 4px;
}

.balance-account {
    font-size: 12px;
    opacity: 0.8;
}

.transactions-section {
    padding: 0 16px;
}

.transactions-header {
    font-size: 13px;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
    margin-top: 8px;
}

.transaction-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.transaction-item {
    background: #fff;
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.transaction-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.transaction-icon.expense { background: #ffe5e5; color: #ff3b30; }
.transaction-icon.income { background: #e5f5e5; color: #34c759; }

.transaction-info {
    flex: 1;
    min-width: 0;
}

.transaction-title {
    font-size: 14px;
    font-weight: 600;
    color: #111;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.transaction-date {
    font-size: 12px;
    color: #999;
}

.transaction-amount {
    font-size: 16px;
    font-weight: 600;
    flex-shrink: 0;
}

.transaction-amount.negative { color: #ff3b30; }
.transaction-amount.positive { color: #34c759; }

/* Tap to Jump Game */
.game-content {
    position: absolute;
    top: 44px;
    left: 0; right: 0; bottom: 0;
    background: #fff;
    overflow: hidden;
}

.game-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.game-score {
    position: absolute;
    top: 56px;
    right: 12px;
    background: rgba(0,0,0,0.6);
    color: #fff;
    padding: 6px 10px;
    border-radius: 8px;
    font-weight: 700;
    z-index: 5;
}

/* Memory Flip Game */
.memory-content {
    position: absolute;
    top: 44px;
    left: 0; right: 0; bottom: 0;
    background: #fff;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    justify-content: center;
    padding-bottom: 60px;
}

.memory-stats {
    display: flex;
    justify-content: space-between;
    padding: 10px 16px;
    font-weight: 600;
    color: #333;
    border-bottom: 1px solid #eee;
}

.memory-grid {
    flex: 0 1 auto;
    padding: 12px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 8px;
}

.card {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 2;
    border-radius: 8px;
    perspective: 800px;
}

.card-inner {
    position: absolute;
    inset: 0;
    border-radius: 8px;
    transition: transform 0.35s ease;
    transform-style: preserve-3d;
}

.card.flipped .card-inner { transform: rotateY(180deg); }

.card-face {
    position: absolute;
    inset: 0;
    backface-visibility: hidden;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 32px;
}

.card-front {
    background-image: var(--card-back);
    background-size: cover;
    background-position: center;
}

.card-back {
    background: #fff;
    color: #111;
    border: 1px solid #e5e5e5;
    transform: rotateY(180deg);
}

.matched .card-inner { opacity: 0.6; }

.memory-actions {
    padding: 10px 16px;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.btn {
    border: 1px solid #dadada;
    background: #fff;
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 14px;
}

/* Health App */
.health-content {
    position: absolute;
    top: 44px;
    left: 0; right: 0; bottom: 0;
    background: #f5f5f5;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 16px;
}

.health-card {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.health-card-icon {
    font-size: 32px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f7f7f7;
    border-radius: 10px;
}

.health-card-info {
    flex: 1;
}

.health-label {
    font-size: 13px;
    color: #666;
    margin-bottom: 4px;
}

.health-value {
    font-size: 28px;
    font-weight: 700;
    color: #111;
    margin-bottom: 2px;
}

.health-goal {
    font-size: 12px;
    color: #999;
}

.health-progress {
    flex-shrink: 0;
}

.health-chart-card {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.health-chart-header {
    margin-bottom: 16px;
}

.health-chart-title {
    font-size: 15px;
    font-weight: 600;
    color: #111;
}

.health-chart {
    width: 100%;
    height: 150px;
    margin-bottom: 8px;
}

.health-chart-labels {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: #999;
    padding: 0 4px;
    margin-bottom: 16px;
}

.health-chart-range {
    display: flex;
    justify-content: space-around;
    padding-top: 12px;
    border-top: 1px solid #f0f0f0;
}

.health-range-item {
    text-align: center;
}

.health-range-label {
    font-size: 11px;
    color: #999;
    margin-bottom: 4px;
}

.health-range-value {
    font-size: 14px;
    font-weight: 600;
    color: #111;
}

/* Password Manager (Parole) */
.add-btn {
    background: none;
    border: none;
    font-size: 28px;
    color: #007AFF;
    cursor: pointer;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* Voice Memos App */
.voice-content {
    position: absolute;
    top: 44px;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.voice-list {
    padding: 0;
}

.voice-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
}

.voice-play-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #007AFF;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
}

.voice-play-btn svg {
    margin-left: 2px;
}

.voice-play-btn:active {
    opacity: 0.7;
}

.voice-info {
    flex: 1;
    min-width: 0;
}

.voice-name {
    font-size: 15px;
    font-weight: 600;
    color: #111;
    margin-bottom: 2px;
}

.voice-meta {
    display: flex;
    gap: 8px;
    font-size: 13px;
    color: #666;
}

.voice-waveform {
    display: flex;
    align-items: center;
    gap: 2px;
    height: 30px;
}

.waveform-bar {
    width: 3px;
    background: #007AFF;
    border-radius: 2px;
    opacity: 0.6;
}

.parole-content {
    position: absolute;
    top: 44px;
    left: 0; right: 0; bottom: 0;
    background: #f5f5f5;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.parole-search {
    background: #fff;
    margin: 12px 16px;
    padding: 10px 12px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.parole-search input {
    border: none;
    outline: none;
    flex: 1;
    font-size: 15px;
    background: transparent;
}

.parole-categories {
    display: flex;
    gap: 8px;
    padding: 0 16px 12px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.parole-category {
    padding: 6px 14px;
    background: #fff;
    border-radius: 16px;
    font-size: 13px;
    color: #666;
    white-space: nowrap;
    cursor: pointer;
}

.parole-category.active {
    background: #007AFF;
    color: #fff;
    font-weight: 600;
}

.parole-list {
    padding: 0 16px 16px;
}

.parole-item {
    background: #fff;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.parole-icon {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.parole-info {
    flex: 1;
}

.parole-name {
    font-size: 15px;
    font-weight: 600;
    color: #111;
    margin-bottom: 3px;
}

.parole-username {
    font-size: 13px;
    color: #666;
}

.parole-action {
    font-size: 24px;
    color: #C7C7CC;
    font-weight: 300;
}

.parole-item {
    cursor: pointer;
}

.parole-item:active {
    opacity: 0.7;
}

.parole-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.parole-modal-content {
    background: #fff;
    border-radius: 16px;
    width: 300px;
    max-width: 90%;
    overflow: hidden;
}

.parole-modal-header {
    padding: 16px;
    border-bottom: 1px solid #e5e5e5;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.parole-modal-title {
    font-size: 17px;
    font-weight: 700;
    color: #111;
}

.parole-modal-close {
    background: none;
    border: none;
    font-size: 32px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 28px;
    height: 28px;
}

.parole-modal-body {
    padding: 16px;
}

.parole-modal-service {
    font-size: 14px;
    font-weight: 600;
    color: #007AFF;
    margin-bottom: 12px;
}

.parole-modal-question {
    font-size: 15px;
    color: #111;
    margin-bottom: 16px;
    line-height: 1.4;
}

.parole-modal-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    font-size: 15px;
    outline: none;
    box-sizing: border-box;
}

.parole-modal-input:focus {
    border-color: #007AFF;
}

.parole-modal-error {
    color: #FF3B30;
    font-size: 13px;
    margin-top: 8px;
}

.parole-modal-footer {
    padding: 12px 16px;
    border-top: 1px solid #e5e5e5;
}

.parole-modal-btn {
    width: 100%;
    padding: 12px;
    background: #007AFF;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
}

.parole-modal-btn:active {
    background: #0051D5;
}

.parole-password-reveal {
    padding: 16px;
    background: #f7f7f7;
    border-top: 1px solid #e5e5e5;
    text-align: center;
}

html {
    background: #000;
    height: 100%;
    overflow: hidden;
}

body {
    margin: 0;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, sans-serif;
    overflow: hidden;
}

#iphone {
    width: 375px;
    height: 812px;
    background-color: #000;
    background-image: url('assets/other/wallpaper.jpg');
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    border-radius: 40px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 0 30px rgba(0,0,0,0.6);
    flex-shrink: 0;
}

/* Mobile responsive - prevent scrolling and fit to device */
@media (max-width: 768px) {
    body {
        width: 100%;
        height: 100dvh;
        overflow: hidden;
        padding: 0;
        margin: 0;
        justify-content: stretch;
        align-items: stretch;
    }
    
    html {
        width: 100%;
        height: 100dvh;
        overflow: hidden;
    }
    
    #iphone {
        width: 100%;
        height: 100dvh;
        max-width: 100%;
        max-height: 100dvh;
        border-radius: 0;
        box-shadow: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }
}

@media (max-height: 900px) and (max-width: 768px) {
    #iphone {
        width: 100%;
        height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
        box-shadow: none;
    }
}

.status-bar {
    height: 40px;
    padding: 5px 10px;
    color: white;
    font-size: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-shadow: 0 0 4px rgba(0,0,0,0.6);
}

@media (max-width: 768px) {
    .status-bar {
        height: 25px;
        padding: 3px 10px;
        font-size: 12px;
    }
}

/* Dark status bar variant for light backgrounds */
.status-bar.status-bar--dark {
    color: #000;
    text-shadow: none;
}

/* Solid background variant to avoid wallpaper bleed */
.status-bar.status-bar--solid {
    background: #fff;
}

/* Full-screen app container */
.app-screen {
    position: absolute;
    top: 44px; /* leave room for status bar */
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
}

.back-btn {
    background: transparent;
    border: 0;
    color: #007AFF;
    font-size: 17px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 400;
    padding: 0;
}

.safari-content {
    position: absolute;
    top: 40px; /* below status bar */
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 24px; /* avoid overlap with home indicator */
}

/* Shared footer elements */
.home-indicator {
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: #000;
    border-radius: 4px;
    opacity: 0.8;
}

.history-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.history-item {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.history-item:last-child {
    border-bottom: none;
}

.history-title { font-size: 14px; color: #111; }
.history-url { font-size: 12px; color: #666; }
.history-date { font-size: 11px; color: #999; }

.apps-grid {
    margin: 20px;
    padding-top: 20px;
    padding-bottom: 120px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-gap: 18px;
    flex: 1;
    overflow: hidden;
    align-content: start;
}

.app {
    text-align: center;
    color: white;
    font-size: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.app img {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.4);
}

.app-disabled {
    opacity: 0.4;
    pointer-events: none;
}

.dock {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 100px;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    padding-bottom: 10px;
    pointer-events: auto;
    flex-shrink: 0;
    z-index: 100;
}

.dock-bg {
    position: absolute;
    width: 90%;
    max-width: 320px;
    height: 80px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 25px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.dock-icons {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    width: 90%;
    max-width: 320px;
    height: 80px;
    pointer-events: auto;
    padding: 0 15px;
    box-sizing: border-box;
}

.dock-app img {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

/* Lock Screen Styles */
#lock-screen {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    display: flex;
    flex-direction: column;
    z-index: 1000;
}

.lock-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 30px;
}

.lock-date {
    font-size: 18px;
    font-weight: 500;
    color: #fff;
    margin-bottom: 8px;
    letter-spacing: 0.3px;
}

.lock-time-large {
    font-size: 76px;
    font-weight: 300;
    color: #fff;
    line-height: 1;
    letter-spacing: -2px;
}

.pin-container {
    padding: 0 20px 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: auto;
}

.pin-header {
    font-size: 15px;
    color: #fff;
    margin-bottom: 16px;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.pin-dots {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    min-height: 16px;
}

.pin-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    transition: all 0.2s ease;
}

.pin-dot.filled {
    background: #fff;
    border-color: #fff;
}

.pin-error {
    display: none;
    color: #ff3b30;
    font-size: 14px;
    margin-bottom: 20px;
    font-weight: 500;
    min-height: 20px;
}

.pin-keypad {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 20px;
}

.pin-row {
    display: flex;
    gap: 24px;
    justify-content: center;
}

.pin-btn {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 32px;
    font-weight: 300;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}

.pin-btn:active {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(0.95);
}

.pin-btn.pin-empty {
    background: transparent;
    border: none;
    cursor: default;
}

.pin-btn.pin-empty:active {
    transform: none;
    background: transparent;
}

.pin-btn.pin-delete {
    font-size: 20px;
}

.pin-btn.pin-delete svg {
    stroke: #fff;
    opacity: 0.6;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-8px); }
    20%, 40%, 60%, 80% { transform: translateX(8px); }
}

/* Calendar App Styles */
.calendar-content {
    position: absolute;
    top: 84px;
    left: 0;
    right: 0;
    bottom: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: #f2f2f7;
    padding-bottom: 24px;
}

.calendar-month {
    background: #fff;
    padding: 16px;
    margin-bottom: 8px;
}

.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    margin-bottom: 8px;
}

.calendar-weekday {
    text-align: center;
    font-size: 11px;
    font-weight: 600;
    color: #8e8e93;
    padding: 4px 0;
}

.calendar-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    color: #000;
    border-radius: 50%;
    position: relative;
}

.calendar-day.empty {
    visibility: hidden;
}

.calendar-day.selected {
    background: #007aff;
    color: #fff;
    font-weight: 600;
}

.calendar-day.has-events::after {
    content: '';
    position: absolute;
    bottom: 2px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #007aff;
}

.calendar-day.selected.has-events::after {
    background: #fff;
}

.calendar-events {
    padding: 0 16px;
}

.event-date-header {
    font-size: 14px;
    font-weight: 700;
    color: #000;
    text-transform: uppercase;
    margin: 16px 0 12px 0;
    letter-spacing: 0.5px;
}

.event-item {
    background: #fff;
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 8px;
    display: flex;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.event-time-bar {
    width: 4px;
    border-radius: 2px;
    flex-shrink: 0;
}

.event-details {
    flex: 1;
}

.event-time {
    font-size: 12px;
    color: #8e8e93;
    margin-bottom: 2px;
}

.event-title {
    font-size: 15px;
    font-weight: 600;
    color: #000;
    margin-bottom: 4px;
}

.event-location {
    font-size: 13px;
    color: #8e8e93;
}

/* Instagram App Styles */
.instagram-content {
    position: absolute;
    top: 84px;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.instagram-error {
    text-align: center;
    max-width: 300px;
}

.instagram-error svg {
    margin-bottom: 24px;
}

.instagram-error h3 {
    font-size: 18px;
    font-weight: 600;
    color: #262626;
    margin: 0 0 12px 0;
}

.instagram-error p {
    font-size: 14px;
    color: #8e8e93;
    margin: 0 0 8px 0;
    line-height: 1.5;
}

.instagram-error .instagram-retry {
    margin-bottom: 24px;
}

.instagram-retry-btn {
    background: #0095f6;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.instagram-retry-btn:active {
    background: #007cc2;
}

/* App Lock Modal Styles */
.app-lock-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.app-lock-content {
    background: #fff;
    border-radius: 20px;
    padding: 32px 24px;
    max-width: 300px;
    width: 90%;
    text-align: center;
    position: relative;
}

.app-lock-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f2f2f7;
    border: none;
    font-size: 24px;
    line-height: 1;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.app-lock-close:hover {
    background: #e5e5ea;
}

.app-lock-close:active {
    background: #d1d1d6;
}

.app-lock-icon {
    margin-bottom: 20px;
}

.app-lock-title {
    font-size: 20px;
    font-weight: 700;
    color: #000;
    margin-bottom: 8px;
}

.app-lock-subtitle {
    font-size: 14px;
    color: #8e8e93;
    margin-bottom: 24px;
}

.app-lock-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 16px;
    border: 1.5px solid #e5e5e5;
    border-radius: 10px;
    margin-bottom: 8px;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.app-lock-input:focus {
    outline: none;
    border-color: #007aff;
}

.app-lock-error {
    color: #ff3b30;
    font-size: 13px;
    margin-bottom: 16px;
    min-height: 18px;
}

.app-lock-btn {
    width: 100%;
    padding: 14px;
    background: #007aff;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.app-lock-btn:active {
    background: #0051d5;
}

/* Home Screen Static Layout */
#home-screen {
    position: absolute;
    top: 40px;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: transparent;
    width: 100%;
    height: calc(100% - 40px);
}

@media (max-width: 768px) {
    #home-screen {
        top: 0;
        height: 100%;
    }
}

/* Ensure all content screens prevent scrolling */
.app-screen {
    position: absolute;
    top: 44px;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}

.call-content,
.banking-content,
.safari-content,
.notes-content,
.messages-content,
.photos-content {
    overflow: hidden !important;
}

/* Mobile-specific adjustments */
@media (max-width: 768px) {
    #home-screen {
        top: 0;
        height: 100%;
    }
    
    .apps-grid {
        margin: 8px;
        padding-top: 50px;
        padding-bottom: 100px;
        grid-gap: 10px;
    }
    
    .app {
        font-size: 11px;
    }
    
    .app img {
        width: 45px;
        height: 45px;
    }
    
    .dock {
        height: 90px;
        padding-bottom: 8px;
        z-index: 100;
    }
    
    .dock-app img {
        width: 48px;
        height: 48px;
    }
    
    .dock-bg {
        height: 70px;
        bottom: 8px;
        width: 85%;
        max-width: 280px;
    }
    
    .dock-icons {
        height: 70px;
        width: 85%;
        max-width: 280px;
        gap: 15px;
        padding: 0 12px;
        pointer-events: auto;
    }
}