/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
    color: #ffffff;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container */
.container {
    position: relative;
    z-index: 10;
    max-width: 400px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Profile Section */
.profile-section {
    text-align: center;
    margin-bottom: 2.5rem;
    animation: fadeInUp 0.8s ease-out;
}

/* Viewfinder Container */
.viewfinder-container {
    position: relative;
    width: 100%;
    max-width: 280px;
    margin: 0 auto 1.5rem;
    aspect-ratio: 4/3;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.viewfinder-image-container {
    position: relative;
    width: 100%;
    height: 100%;
    filter: saturate(0.8) contrast(1.1);
}

.viewfinder-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(0.5px);
    transition: filter 0.3s ease;
}

.viewfinder-container:hover .viewfinder-image {
    filter: saturate(1) contrast(1.15) blur(0);
}

/* Viewfinder Overlay */
.viewfinder-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: transparent;
    z-index: 10;
    pointer-events: none;
}

/* HUD Elements */
.hud-top {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.75rem;
}

.battery-icon i,
.settings-icon i {
    font-size: 0.875rem;
}

/* Focus Points */
.focus-points {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.focus-square {
    position: absolute;
    width: 20px;
    height: 20px;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.focus-square.top-left {
    top: 15px;
    left: 15px;
    border-right: none;
    border-bottom: none;
}

.focus-square.top-right {
    top: 15px;
    right: 15px;
    border-left: none;
    border-bottom: none;
}

.focus-square.bottom-left {
    bottom: 15px;
    left: 15px;
    border-right: none;
    border-top: none;
}

.focus-square.bottom-right {
    bottom: 15px;
    right: 15px;
    border-left: none;
    border-top: none;
}

/* Center Focus */
.center-focus {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.center-crosshair {
    width: 60px;
    height: 60px;
    position: relative;
}

.center-crosshair::before,
.center-crosshair::after {
    content: '';
    position: absolute;
    background: rgba(255, 255, 255, 0.4);
}

.center-crosshair::before {
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    transform: translateY(-50%);
}

.center-crosshair::after {
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    transform: translateX(-50%);
}

/* REC Indicator */
.rec-indicator {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    align-items: center;
    gap: 4px;
    color: #ff3333;
    font-size: 0.75rem;
    font-weight: bold;
}

.rec-dot {
    width: 8px;
    height: 8px;
    background: #ff3333;
    border-radius: 50%;
    animation: blink 1.5s ease-in-out infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

/* HUD Bottom */
.hud-bottom {
    position: absolute;
    bottom: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    justify-content: space-between;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.75rem;
    font-family: 'Courier New', monospace;
}

/* Grid Lines */
.grid-lines {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.grid-vertical,
.grid-horizontal {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
}

.grid-vertical {
    width: 1px;
    height: 100%;
    top: 0;
}

.grid-vertical:nth-child(1) { left: 33.33%; }
.grid-vertical:nth-child(2) { right: 33.33%; }

.grid-horizontal {
    height: 1px;
    width: 100%;
    left: 0;
}

.grid-horizontal:nth-child(3) { top: 33.33%; }
.grid-horizontal:nth-child(4) { bottom: 33.33%; }

/* Links Section */
.links-section {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 2rem;
}

.contact-btn {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #ffffff;
    text-decoration: none;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.contact-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.contact-btn:hover::before {
    left: 100%;
}

.contact-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.contact-btn svg {
    width: 1.25rem;
    height: 1.25rem;
    fill: currentColor;
}

.contact-btn .x-logo {
    width: 1.125rem;
    height: 1.125rem;
}

/* Brand-specific button colors */
.phone-btn:hover {
    border-color: #00b894;
    box-shadow: 0 8px 25px rgba(0, 184, 148, 0.2);
}

.whatsapp-btn:hover {
    border-color: #25d366;
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.2);
}

.email-btn:hover {
    border-color: #ea4335;
    box-shadow: 0 8px 25px rgba(234, 67, 53, 0.2);
}

.instagram-btn:hover {
    border-color: #e4405f;
    box-shadow: 0 8px 25px rgba(228, 64, 95, 0.2);
}

.youtube-btn:hover {
    border-color: #ff0000;
    box-shadow: 0 8px 25px rgba(255, 0, 0, 0.2);
}

.snapchat-btn:hover {
    border-color: #fffc00;
    color: #000000;
    background: rgba(255, 252, 0, 0.1);
}

.twitter-btn:hover {
    border-color: #1da1f2;
    box-shadow: 0 8px 25px rgba(29, 161, 242, 0.2);
}

.portfolio-btn:hover {
    border-color: #6366f1;
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.2);
}

/* vCard Section */
.vcard-section {
    text-align: center;
}

.vcard-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 50px;
    color: #ffffff;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.vcard-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes kenBurns {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(1.05);
    }
}

@keyframes grain {
    0% { transform: translate(0, 0); }
    10% { transform: translate(-1px, 1px); }
    20% { transform: translate(-2px, 0); }
    30% { transform: translate(1px, -1px); }
    40% { transform: translate(-1px, -2px); }
    50% { transform: translate(2px, 1px); }
    60% { transform: translate(-1px, 1px); }
    70% { transform: translate(1px, 2px); }
    80% { transform: translate(-2px, -1px); }
    90% { transform: translate(1px, -1px); }
    100% { transform: translate(0, 0); }
}

/* Floating emoji background */
.floating-emoji-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.emoji-float {
    position: absolute;
    font-size: 1.2rem;
    opacity: 0;
    animation: floatUp var(--duration) linear infinite;
    animation-delay: var(--delay);
    /* The 0% keyframe will define the starting transform now */
    will-change: transform, opacity; /* Hint to browser for performance optimization */
}

@keyframes floatUp {
    0% {
        /* Start above the screen, invisible */
        opacity: 0;
        transform: translateY(-100px) scale(var(--scale)) rotate(var(--start-rotation));
    }
    5% {
        /* Quickly appear at the top edge of the screen, fully visible */
        opacity: var(--opacity);
        transform: translateY(0) scale(var(--scale)) rotate(var(--start-rotation));
    }
    95% {
        /* Drift down to the bottom edge of the screen, still visible */
        opacity: var(--opacity);
        transform: translateY(100vh) scale(var(--scale)) rotate(var(--end-rotation));
    }
    100% {
        /* Move off screen at the very bottom, invisible */
        opacity: 0;
        transform: translateY(calc(100vh + 50px)) scale(var(--scale)) rotate(var(--end-rotation));
    }
}

/* Mobile optimizations */
@media (max-width: 480px) {
    .container {
        padding: 1.5rem 1rem;
    }
    
    .name {
        font-size: 1.5rem;
    }
    
    .viewfinder-container {
        max-width: 240px;
    }
    
    .hud-top,
    .hud-bottom,
    .rec-indicator {
        font-size: 0.625rem;
    }
    
    .focus-square {
        width: 15px;
        height: 15px;
    }
}
