/**
 * Base Styles - Reset, CSS Variables, Typography
 * Witit - AI Image Generator
 */

/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    height: 100%;
    height: 100dvh; /* Dynamic viewport for mobile Safari URL bar */
    overflow: hidden;
}

/* iOS Safari safe area support */
@supports (padding-top: env(safe-area-inset-top)) {
    body {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
    }
}

body {
    background: #06060a;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: white;
}

/* Background Effects */
.bg-effects {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    animation: float 20s ease-in-out infinite;
}

/* Performance: Disable heavy animations on mobile */
@media (max-width: 768px) {
    .orb {
        animation: none;
        filter: blur(60px);  /* Reduce blur intensity - less GPU intensive */
    }
}

/* Respect user's motion preference */
@media (prefers-reduced-motion: reduce) {
    .orb {
        animation: none !important;
    }
}

.orb-1 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
    top: -150px;
    left: -150px;
}

.orb-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 0, 170, 0.12) 0%, transparent 70%);
    bottom: 10%;
    right: -100px;
    animation-delay: -7s;
}

.orb-3 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 170, 0, 0.1) 0%, transparent 70%);
    top: 50%;
    left: 30%;
    animation-delay: -14s;
}

.grid-overlay {
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.012) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.012) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 1;
}

/* Main Layout */
.app {
    position: relative;
    z-index: 2;
    height: 100%;
    height: 100dvh; /* Dynamic viewport for mobile Safari */
    display: flex;
}

.main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    height: 100%;
}

/* Utility Classes */
.hidden { display: none !important; }
.hidden-input { display: none; }
