@charset "utf-8";

/* ✅ ИСПРАВЛЕНО: Добавлен универсальный селектор * */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #4f46e5;
    --primary-hover: #4338ca;
    --secondary-color: #64748b;
    --bg-color: #f8fafc;
    --card-bg: #ffffff;
    --text-main: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --danger-color: #ef4444;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --radius: 20px;
    --shadow: 0 10px 40px rgba(71, 85, 105, 0.15);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    overflow-x: hidden;
    background: var(--bg-color);
}

.dashboard-body {
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    min-height: 100vh;
}

/* ✅ ИСПРАВЛЕНО: Убрано !important чтобы не ломать модальные окна */
.hidden {
    display: none;
}

/* ========== NAVIGATION ========== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    padding: 1.5rem 5%;
    z-index: 1000;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(71, 85, 105, 0.1);
    backdrop-filter: blur(10px);
}

.dashboard-navbar {
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    border-bottom: none;
}

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

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, #475569, #64748b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.dashboard-navbar .logo {
    background: linear-gradient(135deg, #ffffff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.logo-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;  /* или cover, если нужно заполнить весь блок */
    display: block;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 3rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0;
}

.dashboard-navbar .nav-links a {
    color: rgba(255, 255, 255, 0.9);
}

.nav-links a:hover {
    color: var(--secondary-color);
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #475569, #64748b);
    transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-links a.active {
    color: var(--secondary-color);
    font-weight: 600;
}

.btn-nav {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    color: white !important;
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
}

.btn-nav::after {
    display: none;
}

.btn-nav:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.3);
}

.dashboard-nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

.mobile-menu {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.mobile-menu span {
    width: 28px;
    height: 3px;
    background: var(--secondary-color);
    margin: 4px 0;
    transition: 0.3s;
    border-radius: 2px;
}

.dashboard-navbar .mobile-menu span {
    background: rgba(255, 255, 255, 0.9);
}

/* ========== HERO SECTION ========== */
.hero {
    height: 100vh;
    min-height: 600px;
    background: linear-gradient(135deg, #2563EB 0%, #3B82F6 50%, #93C5FD 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(60px, 60px); }
}

.hero-content {
    max-width: 900px;
    padding: 0 2rem;
    margin-top: 8rem;
    transform: translateY(50px);
    opacity: 0;
    animation: fadeInUp 1.2s ease forwards;
    z-index: 2;
    position: relative;
}

@keyframes fadeInUp {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.hero h1 {
    font-size: clamp(2.8rem, 7vw, 5rem);
    font-weight: 800;
    margin-bottom: 2rem;
    line-height: 1.1;
    letter-spacing: -2px;
    transition: opacity 0.5s ease-in-out;
}

.hero p {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    margin-bottom: 3rem;
    opacity: 0.95;
    font-weight: 300;
    transition: opacity 0.5s ease-in-out;
}

.text-fade-out {
    opacity: 0;
}

.cta-button {
    display: inline-block;
    padding: 1.2rem 3rem;
    background: rgba(255, 255, 255, 0.95);
    color: var(--text-main);
    text-decoration: none;
    font-weight: 700;
    border-radius: 60px;
    transition: all 0.4s ease;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.cta-button:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 1);
}

.geometric-shapes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.geo-shape {
    position: absolute;
    opacity: 0.15;
}

.geo-shape:nth-child(1) {
    top: 20%;
    left: 15%;
    width: 120px;
    height: 120px;
    background: linear-gradient(45deg, #fff, transparent);
    clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%);
    animation: float 12s ease-in-out infinite;
}

.geo-shape:nth-child(2) {
    top: 15%;
    right: 20%;
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #fff, transparent);
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
    animation: float 10s ease-in-out infinite reverse;
}

.geo-shape:nth-child(3) {
    top: 60%;
    left: 10%;
    width: 80px;
    height: 80px;
    background: linear-gradient(90deg, #fff, transparent);
    clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%);
    animation: float 8s ease-in-out infinite;
}

.geo-shape:nth-child(4) {
    top: 70%;
    right: 15%;
    width: 90px;
    height: 90px;
    background: linear-gradient(180deg, #fff, transparent);
    clip-path: polygon(50% 0%, 90% 20%, 100% 60%, 75% 100%, 25% 100%, 0% 60%, 10% 20%);
    animation: float 14s ease-in-out infinite;
}

.geo-shape:nth-child(5) {
    top: 35%;
    left: 50%;
    transform: translateX(-50%);
    width: 110px;
    height: 110px;
    background: linear-gradient(270deg, #fff, transparent);
    clip-path: polygon(50% 0%, 83% 12%, 100% 43%, 94% 78%, 68% 100%, 32% 100%, 6% 78%, 0% 43%, 17% 12%);
    animation: float 9s ease-in-out infinite;
}

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

/* ========== SECTION STYLES ========== */
.section {
    padding: 8rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 800;
    margin-bottom: 4rem;
    color: var(--text-main);
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
    letter-spacing: -1px;
}

.section-title.animate {
    opacity: 1;
    transform: translateY(0);
}

/* ========== SERVICES SECTION ========== */
.services {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 50%, #f8fafc 100%);
    position: relative;
}

.services-container {
    position: relative;
    z-index: 2;
}

.services-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 4rem;
    margin-top: 4rem;
    align-items: start;
}

.services-content {
    background: rgba(255, 255, 255, 0.8);
    border-radius: 25px;
    padding: 2.5rem;
    backdrop-filter: blur(15px);
    border: 2px solid rgba(71, 85, 105, 0.1);
    min-height: 400px;
    transition: all 0.5s ease;
}

.service-details {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
    display: none;
}

.service-details.active {
    opacity: 1;
    transform: translateY(0);
    display: block;
}

.service-details h3 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.service-details .service-subtitle {
    font-size: 1rem;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.service-details p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1rem;
    margin-bottom: 1.5rem;
}

.service-features {
    list-style: none;
    padding: 0;
    margin-top: 1.5rem;
}

.service-features li {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid rgba(71, 85, 105, 0.08);
}

.service-features li:last-child {
    border-bottom: none;
}

.feature-check {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #475569, #64748b);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.7rem;
    flex-shrink: 0;
}

.services-tabs {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.service-tab {
    background: rgba(255, 255, 255, 0.7);
    border: 2px solid rgba(71, 85, 105, 0.1);
    border-radius: 18px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.service-tab:hover,
.service-tab.active {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(71, 85, 105, 0.3);
    transform: translateX(10px);
    box-shadow: 0 10px 30px rgba(71, 85, 105, 0.15);
}

.service-tab.active {
    background: rgba(71, 85, 105, 0.1);
    border-color: rgba(71, 85, 105, 0.4);
}

.service-tab::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0;
    background: linear-gradient(135deg, #475569, #64748b);
    transition: width 0.3s ease;
}

.service-tab.active::before {
    width: 4px;
}

.tab-icon {
    font-size: 2rem;
    flex-shrink: 0;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, rgba(71, 85, 105, 0.1), rgba(100, 116, 139, 0.1));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.tab-content {
    flex: 1;
    min-width: 0;
}

.service-tab h4 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.3rem;
    position: relative;
    z-index: 2;
}

.service-tab p {
    color: var(--text-secondary);
    font-size: 0.8rem;
    line-height: 1.3;
    position: relative;
    z-index: 2;
}

.service-tab:hover .tab-icon,
.service-tab.active .tab-icon {
    background: linear-gradient(135deg, #475569, #64748b);
    color: white;
    transform: scale(1.05);
}

/* ========== ABOUT SECTION ========== */
.about-section {
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.about-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    background-image:
        repeating-linear-gradient(45deg,
            rgba(255, 255, 255, 0.06),
            rgba(255, 255, 255, 0.06) 1px,
            transparent 1px,
            transparent 100px),
        repeating-linear-gradient(-45deg,
            rgba(255, 255, 255, 0.06),
            rgba(255, 255, 255, 0.06) 1px,
            transparent 1px,
            transparent 100px);
}

.about {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.about-content {
    position: relative;
}

.about-content::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(to bottom, #64748b, transparent);
    border-radius: 2px;
}

.about-content h2 {
    font-size: clamp(2.2rem, 4vw, 3.2rem);
    font-weight: 800;
    margin-bottom: 2.5rem;
    color: white;
    letter-spacing: -1px;
    line-height: 1.2;
}

.about-content .highlight {
    color: #94a3b8;
    font-weight: 600;
    font-size: 1.3rem;
    margin-bottom: 2rem;
    letter-spacing: 0.5px;
}

.about-content p {
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 2rem;
    font-size: 1.15rem;
    line-height: 1.8;
}

.about-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin: 3rem 0;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(5px);
}

.feature-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #64748b, #94a3b8);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.feature-text {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    font-size: 0.95rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.stat:first-child {
    grid-column: 1 / -1;
}

.stat {
    text-align: center;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.stat:hover {
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.15);
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: #94a3b8;
    display: block;
}

.stat-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.5rem;
}

/* ========== CONTACT SECTION ========== */
.contact {
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
    background-size: 80px 80px;
    animation: contactGridMove 30s linear infinite;
}

@keyframes contactGridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(80px, 80px); }
}

.contact .section-title {
    color: white;
}

.contact-content {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.contact p {
    font-size: 1.3rem;
    margin-bottom: 3rem;
    opacity: 0.95;
    text-align: center;
}

.contact-form {
    display: grid;
    gap: 2rem;
    margin-top: 4rem;
}

.form-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.contact-form input,
.contact-form textarea {
    padding: 1.5rem;
    border: none;
    border-radius: 20px;
    font-size: 1rem;
    font-family: inherit;
    font-weight: 400;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.2);
    border-color: #64748b;
    box-shadow: 0 0 0 4px rgba(100, 116, 139, 0.2);
    transform: scale(1.02);
}

.contact-form textarea {
    grid-column: 1 / -1;
    resize: vertical;
    min-height: 150px;
    font-family: inherit;
}

.submit-btn {
    background: linear-gradient(135deg, #64748b, #475569);
    color: white;
    padding: 1.5rem 3rem;
    border: none;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s ease;
    justify-self: center;
    position: relative;
    overflow: hidden;
}

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

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

.submit-btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 30px rgba(100, 116, 139, 0.4);
}

/* ========== FOOTER ========== */
.footer {
    background: #0f172a;
    color: white;
    padding: 3rem 5% 2rem;
    text-align: center;
    border-top: 1px solid rgba(71, 85, 105, 0.2);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.footer-logo span {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #64748b, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-weight: 400;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #64748b;
}

.footer-copyright {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* ========== ALERTS ========== */
.alert {
    padding: 1rem 5%;
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    z-index: 999;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.alert-error {
    background: linear-gradient(135deg, #fee2e2, #fecaca);
    color: #991b1b;
    border-bottom: 2px solid #ef4444;
}

.alert-content {
    display: flex;
    align-items: center;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
}

.alert-icon {
    font-size: 1.5rem;
}

/* ========== BUTTONS ========== */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.95rem;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-hover));
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(79, 70, 229, 0.3);
}

.btn-secondary {
    background: #e5e7eb;
    color: var(--text-main);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--border-color);
    color: var(--text-main);
}

.dashboard-navbar .btn-outline {
    border-color: rgba(255, 255, 255, 0.3);
    color: white;
}

.btn-outline:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-text {
    background: transparent;
    color: var(--text-secondary);
    padding: 0.5rem 1rem;
}

.btn-text:hover {
    color: var(--primary-color);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-icon {
    background: none;
    border: none;
    color: var(--danger-color);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.5rem;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.btn-icon:hover {
    background: rgba(239, 68, 68, 0.1);
    transform: scale(1.1);
}

.btn-download {
    color: var(--success-color);
}

.btn-download:hover {
    background: rgba(16, 185, 129, 0.1);
}

.btn-preview {
    color: var(--primary-color);
}

.btn-preview:hover {
    background: rgba(79, 70, 229, 0.1);
}

/* ========== DASHBOARD STYLES ========== */
.dashboard-main {
    padding-top: 100px;
    min-height: 100vh;
}

.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 5%;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.dashboard-header h2 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-main);
}

.dashboard-actions {
    display: flex;
    gap: 1rem;
}

/* Storage Stats */
.storage-stats {
    background: var(--card-bg);
    border-radius: var(--radius);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    display: grid;
    grid-template-columns: repeat(3, 1fr) auto;
    gap: 2rem;
    align-items: center;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-icon {
    font-size: 2.5rem;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(67, 56, 202, 0.1));
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.progress-container {
    flex: 1;
    min-width: 200px;
}

.progress-bar {
    background: #e5e7eb;
    border-radius: 99px;
    height: 12px;
    overflow: hidden;
}

.progress-fill {
    background: linear-gradient(135deg, var(--success-color), #059669);
    height: 100%;
    transition: width 0.5s ease;
}

/* Admin Panel */
.admin-panel {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
    border: 2px solid var(--border-color);
}

.admin-panel h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.admin-form {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: flex-end;
}

.input-field {
    flex: 1;
    min-width: 200px;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: inherit;
}

.input-field:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.form-actions {
    display: flex;
    gap: 1rem;
}

/* Upload Zone */
.upload-zone {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius);
    padding: 4rem 2rem;
    text-align: center;
    background: var(--card-bg);
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 2rem;
    box-shadow: var(--shadow);
}

.upload-zone:hover,
.upload-zone.dragover {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.05), rgba(67, 56, 202, 0.05));
    transform: translateY(-5px);
}

.upload-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.upload-zone h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}

.upload-zone p {
    color: var(--text-secondary);
}

#upload-progress-bar {
    margin-top: 1.5rem;
}

/* File List */
.file-list-container {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.file-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.file-list-header h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-main);
}

.file-table {
    width: 100%;
    border-collapse: collapse;
}

.file-table th,
.file-table td {
    padding: 1.25rem 2rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.file-table th {
    background: linear-gradient(135deg, #f9fafb, #f3f4f6);
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.file-table tr:last-child td {
    border-bottom: none;
}

.file-table tr:hover {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.03), rgba(67, 56, 202, 0.03));
}

.file-actions {
    display: flex;
    gap: 0.5rem;
}

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

.loading-spinner {
    display: inline-block;
    width: 30px;
    height: 30px;
    border: 3px solid rgba(79, 70, 229, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-color);
    animation: spin 1s ease-in-out infinite;
    margin-right: 1rem;
    vertical-align: middle;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.empty-state p {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}

.empty-state span {
    color: var(--text-secondary);
}

/* ========== MODAL (BASE STYLES - OUTSIDE MEDIA QUERIES) ========== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal.active {
    display: flex;
    opacity: 1;
    visibility: visible;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
}

.modal-content {
    position: relative;
    background: var(--card-bg);
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.3s ease;
    z-index: 10;
}

.modal-close:hover {
    color: var(--danger-color);
}

.preview-card {
    text-align: center;
    background: var(--card-bg);
    color: var(--text-main);
}

#preview-content img {
    max-width: 100%;
    max-height: 70vh;
    border-radius: 10px;
}

#preview-content pre {
    background: #f1f5f9;
    padding: 1rem;
    border-radius: 10px;
    overflow-x: auto;
    text-align: left;
    font-size: 0.9rem;
}

/* ========== LOGIN MODAL CARD (SPECIFIC STYLES) ========== */
.login-modal-card {
    background: linear-gradient(135deg, #1e293b 0%, #475569 100%);
    color: white;
    max-width: 450px;
    padding: 3rem;
    border-radius: 30px;
    transform: translateY(-50px) scale(0.9);
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    overflow: hidden;
}

.modal.active .login-modal-card {
    transform: translateY(0) scale(1);
}

.login-modal-card .modal-close {
    background: rgba(100, 116, 139, 0.1);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-modal-card .modal-close:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    transform: rotate(90deg);
}

.login-header {
    text-align: center;
    margin-bottom: 2.5rem;
    position: relative;
    z-index: 2;
}

.login-logo {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    border-radius: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.1);
    animation: pulse 2s ease-in-out infinite;
    overflow: hidden;  /* ✅ Важно для скругления */
}

.login-logo img {
    width: 50px;        /* ✅ Размер иконки внутри */
    height: 50px;
    object-fit: contain; /* ✅ Сохраняет пропорции */
    display: block;
}

.login-header h2 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #ffffff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-header p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
}

.form-group-floating {
    position: relative;
    margin-bottom: 1.5rem;
}

.form-group-floating input {
    width: 100%;
    padding: 1.2rem 1.2rem 1.2rem 3rem;
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-group-floating input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.05);
}

.form-group-floating label {
    position: absolute;
    left: 3rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.5);
    font-size: 1rem;
    pointer-events: none;
    transition: all 0.3s ease;
    background: transparent;
    padding: 0 0.3rem;
}

.form-group-floating input:focus + label,
.form-group-floating input:not(:placeholder-shown) + label {
    top: 0;
    left: 1rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.8);
    background: linear-gradient(135deg, #1e293b, #475569);
    border-radius: 5px;
}

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.form-group-floating input:focus + .input-icon {
    color: rgba(255, 255, 255, 0.8);
}

.login-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    font-size: 0.875rem;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.7);
}

.checkbox-container input {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.checkbox-container input:checked + .checkmark {
    background: linear-gradient(135deg, #10b981, #059669);
    border-color: transparent;
}

.checkbox-container input:checked + .checkmark::after {
    content: '✓';
    color: white;
    font-size: 0.75rem;
    font-weight: 700;
}

.btn-login {
    width: 100%;
    padding: 1.2rem;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    border: none;
    border-radius: 15px;
    color: white;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

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

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

.btn-login:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(16, 185, 129, 0.4);
}

.btn-login:active {
    transform: translateY(-1px);
}

.btn-text,
.btn-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-loader.hidden {
    display: none;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.login-footer {
    text-align: center;
    position: relative;
    z-index: 2;
}

.login-footer p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.signup-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    text-decoration: none;
    font-weight: 600;
    padding: 0.8rem 2rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.signup-link:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
}

.login-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.deco-circle {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1), transparent);
    animation: floatDecoration 20s ease-in-out infinite;
}

.deco-circle:nth-child(1) {
    width: 300px;
    height: 300px;
    top: -150px;
    right: -150px;
    animation-delay: 0s;
}

.deco-circle:nth-child(2) {
    width: 200px;
    height: 200px;
    bottom: -100px;
    left: -100px;
    animation-delay: -7s;
}

.deco-circle:nth-child(3) {
    width: 150px;
    height: 150px;
    top: 50%;
    left: 50%;
    animation-delay: -14s;
}

@keyframes floatDecoration {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.5;
    }
    50% {
        transform: translate(30px, -30px) scale(1.1);
        opacity: 0.8;
    }
}

.form-group-floating.error input {
    border-color: #ef4444;
    animation: shake 0.5s ease;
}

.form-group-floating.error label {
    color: #ef4444;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.login-success {
    animation: successPulse 0.5s ease;
}

@keyframes successPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

/* ========== SCROLL ANIMATIONS ========== */
.fade-in {
    opacity: 1;
    transform: translateY(40px);
    transition: all 0.8s ease;
}

.fade-in.animate {
    opacity: 1;
    transform: translateY(0);
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.loading {
    animation: pulse 2s ease-in-out infinite;
}

/* ✅ ЕДИНСТВЕННОЕ ОПРЕДЕЛЕНИЕ @keyframes spin */
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1000px) {
    .about {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }
    
    .about-content::before {
        display: none;
    }
    
    .storage-stats {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .progress-container {
        order: -1;
    }
}

@media (max-width: 940px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(248, 250, 252, 0.95);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: 2rem 5%;
        box-shadow: 0 10px 30px rgba(71, 85, 105, 0.1);
        border-radius: 0 0 20px 20px;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .mobile-menu {
        display: flex;
    }
    
    .services-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .services-tabs {
        order: -1;
    }
    
    .service-tab {
        width: 100%;
        flex-direction: column;
        text-align: center;
    }
    
    .form-group {
        grid-template-columns: 1fr;
    }
    
    .dashboard-header {
        flex-direction: column;
        text-align: center;
    }
    
    .dashboard-actions {
        width: 100%;
        justify-content: center;
    }
    
    .admin-form {
        flex-direction: column;
    }
    
    .input-field {
        width: 100%;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }
    
    .file-table th,
    .file-table td {
        padding: 1rem;
        font-size: 0.875rem;
    }
    
    .file-actions {
        flex-direction: column;
        gap: 0.25rem;
    }
}

@media (max-width: 480px) {
    .stats {
        grid-template-columns: 1fr;
    }
    
    .stat:first-child {
        grid-column: 1;
    }
    
    .about-features {
        grid-template-columns: 1fr;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .section {
        padding: 5rem 5%;
    }
    
    /* ✅ АДАПТИВ ДЛЯ МОДАЛЬНОГО ОКНА (ТОЛЬКО ИЗМЕНЕНИЯ) */
    .modal-content {
        padding: 2rem;
        margin: 1rem;
    }
    
    .login-modal-card {
        padding: 2rem;
    }
    
    .login-options {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    
    .login-header h2 {
        font-size: 1.5rem;
    }
}
