/* iOS Design System Styles */

:root {
    --ios-blue: #007aff;
    --ios-indigo: #5856d6;
    --ios-purple: #af52de;
    --ios-pink: #ff2d55;
    --ios-green: #34c759;
    --ios-orange: #ff9500;
}

/* Apple SF Pro Font Stack */
body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "SF Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    padding-bottom: env(safe-area-inset-bottom, 0px);
}

/* iOS Glassmorphism and Materials */
.ios-blur {
    backdrop-filter: blur(25px) saturate(190%);
    -webkit-backdrop-filter: blur(25px) saturate(190%);
}

.ios-glass-card {
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

/* iOS Squircle Rounded Corners */
.ios-card {
    border-radius: 26px;
}

.ios-card-sm {
    border-radius: 18px;
}

.ios-card-lg {
    border-radius: 34px;
}

/* iOS Grouped List Inset */
.ios-list-group {
    border-radius: 20px;
    overflow: hidden;
}

.ios-list-item {
    position: relative;
    transition: background-color 0.2s ease;
}

.ios-list-item:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    left: 56px;
    height: 1px;
    background-color: rgba(60, 60, 67, 0.12);
}

.dark .ios-list-item:not(:last-child)::after {
    background-color: rgba(84, 84, 88, 0.35);
}

/* iOS Smooth Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(142, 142, 147, 0.3);
    border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(142, 142, 147, 0.5);
}

/* iOS Segmented Control animation */
.segmented-btn {
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.segmented-btn.active {
    background-color: #ffffff;
    color: #000000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.dark .segmented-btn.active {
    background-color: rgba(255, 255, 255, 0.22);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
}

/* Portfolio Card Transitions */
.portfolio-card {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease, box-shadow 0.3s ease;
}

.portfolio-card.hidden-project {
    display: none;
    opacity: 0;
    transform: scale(0.96);
}

/* iOS Modal Sheet Transitions */
.ios-modal-backdrop {
    transition: opacity 0.25s ease;
}

.ios-modal-content {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.ios-modal-hidden .ios-modal-backdrop {
    opacity: 0;
    pointer-events: none;
}

.ios-modal-hidden .ios-modal-content {
    opacity: 0;
    transform: scale(0.95) translateY(20px);
    pointer-events: none;
}
