/* =====================================
   1FPS Web Studio - Glassmorphism Theme
   Современный стеклянный дизайн
   ===================================== */

:root {
    /* Основные цвета glassmorphism */
    --glass-bg: rgba(17, 25, 40, 0.75);
    --glass-border: rgba(255, 255, 255, 0.125);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    --glass-highlight: rgba(255, 255, 255, 0.1);
    
    /* Градиенты */
    --primary-gradient: linear-gradient(135deg, #8b9fff 0%, #b19bff 100%);
    --secondary-gradient: linear-gradient(135deg, #ff9ff9 0%, #ff7f8f 100%);
    --accent-gradient: linear-gradient(135deg, #6fd5ff 0%, #4fffff 100%);
    --glass-gradient: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
    
    /* Основные цвета */
    --bg-color: #0f0f23;
    --darker-bg: #0a0a1a;
    --card-bg: rgba(17, 25, 40, 0.7);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.8);
    --text-muted: rgba(255, 255, 255, 0.6);
    
    /* Акцентные цвета */
    --accent-blue: #4facfe;
    --accent-purple: #667eea;
    --accent-pink: #f093fb;
    --accent-cyan: #00f2fe;
    
    /* Эффекты */
    --blur-strength: 20px;
    --border-radius: 16px;
    --shadow-elevation: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
}

/* ===== БАЗОВЫЕ СТИЛИ ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

/* Animated background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(ellipse at top, rgba(102, 126, 234, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at bottom, rgba(240, 147, 251, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at left, rgba(79, 172, 254, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at right, rgba(0, 242, 254, 0.1) 0%, transparent 50%);
    z-index: -2;
    animation: backgroundShift 20s ease-in-out infinite;
}

@keyframes backgroundShift {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.1) rotate(1deg); }
}

/* ===== GLASS COMPONENTS ===== */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(var(--blur-strength));
    -webkit-backdrop-filter: blur(var(--blur-strength));
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    box-shadow: var(--glass-shadow);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--glass-gradient);
    z-index: 1;
}

.glass-button {
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    padding: 12px 24px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.glass-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--accent-gradient);
    transition: left 0.5s ease;
    z-index: -1;
}

.glass-button:hover::before {
    left: 0;
}

.glass-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(79, 172, 254, 0.3);
    border-color: var(--accent-blue);
}

/* ===== NAVIGATION ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 20px 0;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    background: rgba(15, 15, 35, 0.8);
    border-bottom: 1px solid var(--glass-border);
}

.nav-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 24px;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 16px;
    border-radius: 25px;
}

.nav-menu a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-menu a:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.nav-menu a:hover::before {
    width: 100%;
}

/* ===== HERO SECTION ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    text-align: center;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 800;
    margin-bottom: 20px;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.1;
    animation: fadeInUp 1s ease-out;
}

.hero-subtitle {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    color: var(--text-secondary);
    margin-bottom: 30px;
    animation: fadeInUp 1s ease-out 0.2s both;
}

.hero .hero-price,
.hero-content .hero-price,
div.hero-price {
    font-size: 1.5rem !important;
    font-weight: 700 !important;
    margin-bottom: 40px !important;
    padding: 15px 30px !important;
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(15px) !important;
    border: 2px solid rgba(255, 255, 255, 0.3) !important;
    border-radius: 50px !important;
    display: inline-block !important;
    animation: fadeInUp 1s ease-out 0.4s both !important;
    color: #ffffff !important;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8) !important;
    box-shadow: 0 8px 32px rgba(255, 255, 255, 0.1), inset 0 0 20px rgba(255, 255, 255, 0.1) !important;
    -webkit-text-fill-color: #ffffff !important;
    -webkit-background-clip: border-box !important;
    background-clip: border-box !important;
    background-image: none !important;
}

.btn-primary {
    background: var(--accent-gradient);
    border: none;
    border-radius: 50px;
    padding: 16px 32px;
    color: white;
    font-size: 18px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 24px rgba(79, 172, 254, 0.4);
    animation: fadeInUp 1s ease-out 0.6s both;
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 32px rgba(79, 172, 254, 0.6);
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: all 0.6s ease;
}

.btn-primary:hover::after {
    width: 300px;
    height: 300px;
}

/* ===== FLOATING ELEMENTS ===== */
.floating-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.floating-element {
    position: absolute;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    animation: float 8s ease-in-out infinite;
}

.floating-element:nth-child(1) {
    width: 80px;
    height: 80px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.floating-element:nth-child(2) {
    width: 120px;
    height: 120px;
    top: 70%;
    right: 10%;
    animation-delay: 2s;
}

.floating-element:nth-child(3) {
    width: 60px;
    height: 60px;
    top: 40%;
    right: 20%;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(180deg); }
}

/* ===== SERVICES SECTION ===== */
.services {
    padding: 120px 0;
    position: relative;
}

.section-title {
    text-align: center;
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 20px;
    color: #ffffff; /* fallback color */
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 60px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.service-card {
    padding: 40px 30px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    cursor: pointer;
}

.service-card:hover {
    transform: translateY(-10px) scale(1.02);
}

.service-icon {
    font-size: 60px;
    margin-bottom: 30px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
    animation: iconBounce 2s ease-in-out infinite;
}

.service-card:nth-child(2) .service-icon {
    background: var(--secondary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation-delay: 0.5s;
}

.service-card:nth-child(3) .service-icon {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation-delay: 1s;
}

@keyframes iconBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.service-card h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--text-primary);
    font-weight: 600;
}

.service-card p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 20px;
}

.service-price {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff !important;
    background: var(--glass-bg);
    padding: 8px 16px;
    border-radius: 25px;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    box-shadow: var(--glass-shadow);
    display: inline-block;
}

/* ===== PORTFOLIO SECTION ===== */
.portfolio {
    padding: 120px 0;
    background: rgba(10, 10, 26, 0.5);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.portfolio-item {
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    cursor: pointer;
    group: hover;
}

.portfolio-item:hover {
    transform: translateY(-10px) rotateX(5deg);
    box-shadow: 0 20px 40px rgba(79, 172, 254, 0.3);
}

.portfolio-image {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: all 0.4s ease;
}

.portfolio-item:hover .portfolio-image {
    transform: scale(1.1);
    filter: brightness(1.1);
}

.portfolio-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    border-top: 1px solid var(--glass-border);
    transform: translateY(100%);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-item:hover .portfolio-content {
    transform: translateY(0);
}

.portfolio-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.portfolio-description {
    color: var(--text-secondary);
    margin-bottom: 15px;
    line-height: 1.5;
}

.portfolio-link {
    margin-top: 15px;
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: var(--accent-gradient);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(79, 172, 254, 0.4);
}

.project-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(79, 172, 254, 0.6);
}

/* ===== CONTACT SECTION ===== */
.contact {
    padding: 120px 0;
    position: relative;
}

.contact-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.contact-form {
    padding: 40px;
    border-radius: var(--border-radius);
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 16px;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-blue);
    box-shadow: 0 0 20px rgba(79, 172, 254, 0.3);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

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

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .services-grid,
    .portfolio-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .service-card,
    .contact-form {
        padding: 30px 20px;
    }
    
    .floating-element {
        display: none;
    }
}

/* ===== THEME SWITCHER ===== */
.theme-switcher {
    position: fixed;
    top: 50%;
    right: 30px;
    transform: translateY(-50%);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.theme-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 2px solid var(--glass-border);
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--text-primary);
    box-shadow: var(--glass-shadow);
}

.theme-button:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 24px rgba(79, 172, 254, 0.4);
}

.theme-button.active {
    background: var(--accent-gradient);
    border-color: var(--accent-blue);
}

/* ===== UTILITIES ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== ADDITIONAL GLASS EFFECTS ===== */
.glass-orb {
    position: fixed;
    pointer-events: none;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, rgba(79, 172, 254, 0.3), rgba(240, 147, 251, 0.1));
    backdrop-filter: blur(20px);
    animation: orbFloat 8s ease-in-out infinite;
}

.glass-orb:nth-child(1) {
    width: 300px;
    height: 300px;
    top: 10%;
    left: -150px;
    animation-delay: 0s;
}

.glass-orb:nth-child(2) {
    width: 200px;
    height: 200px;
    top: 60%;
    right: -100px;
    animation-delay: 3s;
}

.glass-orb:nth-child(3) {
    width: 150px;
    height: 150px;
    bottom: 20%;
    left: 20%;
    animation-delay: 6s;
}

@keyframes orbFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        opacity: 0.6;
    }
    50% {
        transform: translateY(-30px) rotate(180deg);
        opacity: 0.8;
    }
}

/* Добавляем орбы через JavaScript */
.glass-background-orbs {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

/* ===== ENHANCED HOVER EFFECTS ===== */
.glass-card:hover {
    transform: translateY(-8px);
    box-shadow: 
        var(--glass-shadow),
        0 20px 40px rgba(79, 172, 254, 0.2);
    border-color: rgba(79, 172, 254, 0.4);
}

.glass-card:hover::before {
    background: linear-gradient(135deg, rgba(79, 172, 254, 0.2) 0%, rgba(240, 147, 251, 0.1) 100%);
}

/* ===== INTERACTIVE PARTICLES ===== */
.glass-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: radial-gradient(circle, var(--accent-blue), transparent);
    border-radius: 50%;
    pointer-events: none;
    animation: particleFloat 3s linear infinite;
}

@keyframes particleFloat {
    0% {
        opacity: 0;
        transform: translateY(100vh) scale(0);
    }
    10% {
        opacity: 1;
        transform: translateY(90vh) scale(1);
    }
    90% {
        opacity: 1;
        transform: translateY(10vh) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(0) scale(0);
    }
}

/* ===== SMOOTH TRANSITIONS ===== */
* {
    transition: 
        background-color 0.3s ease, 
        border-color 0.3s ease, 
        color 0.3s ease,
        transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
        box-shadow 0.3s ease;
}

/* ===== LOADING ANIMATIONS ===== */
.glass-loader {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid rgba(79, 172, 254, 0.2);
    border-radius: 50%;
    border-top-color: var(--accent-blue);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== GLASS MENU EFFECTS ===== */
.nav-menu a {
    position: relative;
    overflow: hidden;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--glass-gradient);
    transition: left 0.3s ease;
    z-index: -1;
}

.nav-menu a:hover::after {
    left: 0;
}

.text-center {
    text-align: center;
}

.mb-4 {
    margin-bottom: 2rem;
}

.opacity-0 {
    opacity: 0;
}

.transform {
    transform: translateY(20px);
}

/* Плавные переходы для смены темы */
* {
    transition: background-color 0.3s ease, border-color 0.3s ease, color 0.3s ease;
}

/* ЭКСТРЕННЫЙ ФИКС ДЛЯ HERO-PRICE */
.hero-price,
.hero .hero-price,
.hero-content .hero-price,
div.hero-price {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
    background-image: none !important;
    -webkit-background-clip: border-box !important;
    background-clip: border-box !important;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.8) !important;
}