/* ============================================================================
   Ассистент Трейдера - Glass UI Design v4.0
   ============================================================================ */

:root {
    --gradient-start: #667eea;
    --gradient-end: #764ba2;
    --gradient-angle: 135deg;
    --glass-bg: rgba(255, 255, 255, 0.1);
    --glass-border: rgba(255, 255, 255, 0.2);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.8);
    --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.3);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(var(--gradient-angle), var(--gradient-start) 0%, var(--gradient-end) 100%);
    min-height: 100vh;
    color: var(--text-primary);
    position: relative;
    overflow-x: hidden;
}

/* ============================================================================
   Анимированный фон
   ============================================================================ */

.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    background: linear-gradient(var(--gradient-angle), var(--gradient-start) 0%, var(--gradient-end) 100%);
}

.animated-bg::before,
.animated-bg::after {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: float 20s infinite ease-in-out;
}

.animated-bg::before {
    top: -250px;
    left: -250px;
    animation-delay: 0s;
}

.animated-bg::after {
    bottom: -250px;
    right: -250px;
    animation-delay: 10s;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    25% {
        transform: translate(50px, 50px) scale(1.1);
    }
    50% {
        transform: translate(0, 100px) scale(1);
    }
    75% {
        transform: translate(-50px, 50px) scale(0.9);
    }
}

/* ============================================================================
   Glass эффект
   ============================================================================ */

.glass {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow);
    position: relative;
    z-index: 1;
}

/* ============================================================================
   Навигация
   ============================================================================ */

.navbar {
    padding: 1rem 2rem;
    margin-bottom: 2rem;
    border-radius: 15px;
    margin: 1rem;
}

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

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
}

.logo-icon {
    font-size: 2rem;
}

.logo-text {
    background: linear-gradient(135deg, #fff, rgba(255, 255, 255, 0.6));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
}

.nav-user {
    color: var(--text-primary);
    font-weight: 500;
}

/* ============================================================================
   Контейнер
   ============================================================================ */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

/* ============================================================================
   Hero секция
   ============================================================================ */

.hero {
    text-align: center;
    padding: 4rem 2rem;
    margin-bottom: 4rem;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.gradient-text {
    background: linear-gradient(135deg, #fff, rgba(255, 255, 255, 0.5));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================================================
   Кнопки
   ============================================================================ */

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 2rem;
    border-radius: 12px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background: rgba(255, 255, 255, 0.25);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-primary:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

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

.btn-icon {
    font-size: 1.2rem;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ============================================================================
   Секции
   ============================================================================ */

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
}

/* ============================================================================
   Возможности (Features)
   ============================================================================ */

.features {
    margin-bottom: 4rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.feature-card {
    padding: 2rem;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.feature-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.feature-description {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ============================================================================
   Тарифы (Pricing)
   ============================================================================ */

.pricing {
    margin-bottom: 4rem;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.pricing-card {
    padding: 2.5rem;
    border-radius: 20px;
    text-align: center;
    transition: all 0.3s ease;
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.pricing-card.featured {
    border: 2px solid rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

.plan-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.plan-name {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
}

.plan-price {
    margin-bottom: 2rem;
}

.price-amount {
    font-size: 3rem;
    font-weight: 800;
}

.price-currency {
    font-size: 1.25rem;
    color: var(--text-secondary);
}

.plan-features {
    list-style: none;
    margin-bottom: 2rem;
    text-align: left;
}

.feature-item {
    padding: 0.75rem 0;
    color: var(--text-secondary);
}

/* ============================================================================
   CTA
   ============================================================================ */

.cta {
    padding: 4rem 2rem;
    border-radius: 20px;
    text-align: center;
    margin-bottom: 4rem;
}

.cta-title {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-text {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* ============================================================================
   Аутентификация
   ============================================================================ */

.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 150px);
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.auth-card {
    width: 100%;
    max-width: 450px;
    padding: 3rem;
    border-radius: 20px;
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

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

.auth-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.auth-subtitle {
    color: var(--text-secondary);
}

.auth-form {
    margin-bottom: 1.5rem;
}

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

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
}

.form-input-sm {
    padding: 0.625rem 0.875rem;
    font-size: 0.9rem;
}

.auth-footer {
    text-align: center;
    color: var(--text-secondary);
}

.auth-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
}

.auth-link:hover {
    text-decoration: underline;
}

/* ============================================================================
   Сообщения
   ============================================================================ */

.error-message {
    padding: 1rem;
    background: rgba(255, 100, 100, 0.2);
    border: 1px solid rgba(255, 100, 100, 0.4);
    border-radius: 10px;
    margin-bottom: 1rem;
    color: #ffcccc;
}

.success-message {
    padding: 1rem;
    background: rgba(100, 255, 100, 0.2);
    border: 1px solid rgba(100, 255, 100, 0.4);
    border-radius: 10px;
    margin-bottom: 1rem;
    color: #ccffcc;
}

.warning-text {
    color: #ffcc00;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.success-text {
    color: #00ff88;
    font-weight: 600;
}

/* ============================================================================
   Модальные окна
   ============================================================================ */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modal-content {
    width: 90%;
    max-width: 500px;
    padding: 2rem;
    border-radius: 20px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    margin-bottom: 1.5rem;
}

.modal-header h2 {
    font-size: 1.75rem;
}

.modal-body {
    margin-bottom: 1.5rem;
}

.modal-footer {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* ============================================================================
   API Key Display
   ============================================================================ */

.api-key-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    margin: 1rem 0;
}

.api-key-display code {
    flex: 1;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    word-break: break-all;
    color: #00ff88;
}

.demo-credentials {
    margin-top: 2rem;
    padding: 1.5rem;
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.05);
}

.demo-credentials h4 {
    margin-bottom: 0.75rem;
}

.demo-credentials p {
    margin: 0.25rem 0;
    font-size: 0.9rem;
}

.demo-credentials code {
    padding: 0.25rem 0.5rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    color: #00ff88;
}

/* ============================================================================
   Dashboard
   ============================================================================ */

.dashboard {
    padding: 2rem;
}

.dashboard-header {
    margin-bottom: 2rem;
}

.page-title {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.dashboard-card {
    border-radius: 20px;
    padding: 1.5rem;
}

.dashboard-card.full-width {
    grid-column: 1 / -1;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
}

.card-body {
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    color: var(--text-secondary);
}

.info-value {
    font-weight: 600;
}

.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.2);
}

.badge-success {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
}

.badge-info {
    background: rgba(100, 200, 255, 0.2);
    color: #64c8ff;
}

/* ============================================================================
   Статистика
   ============================================================================ */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    border-radius: 15px;
}

.stat-icon {
    font-size: 3rem;
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
}

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

/* ============================================================================
   Таблицы
   ============================================================================ */

.table-responsive {
    overflow-x: auto;
}

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

.data-table th,
.data-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.data-table th {
    font-weight: 600;
    color: var(--text-secondary);
}

.loading {
    text-align: center;
    color: var(--text-secondary);
    padding: 2rem;
}

/* ============================================================================
   API Keys List
   ============================================================================ */

.keys-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.key-item {
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.key-info h4 {
    margin-bottom: 0.25rem;
}

.key-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* ============================================================================
   Webhooks List
   ============================================================================ */

.webhooks-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-height: 500px;
    overflow-y: auto;
}

.webhook-item {
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border-left: 3px solid rgba(0, 255, 136, 0.5);
}

.webhook-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.webhook-time {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.webhook-data {
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    background: rgba(0, 0, 0, 0.3);
    padding: 0.75rem;
    border-radius: 5px;
    overflow-x: auto;
    color: #00ff88;
}

/* ============================================================================
   Instructions
   ============================================================================ */

.instructions {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.instruction-step {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    font-weight: 700;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.step-content h4 {
    margin-bottom: 0.5rem;
}

.step-content p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ============================================================================
   Settings
   ============================================================================ */

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.setting-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.color-input-group {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.color-input {
    width: 60px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    cursor: pointer;
    background: transparent;
}

.range-input {
    width: 100%;
}

.gradient-preview {
    height: 150px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1.25rem;
}

/* ============================================================================
   API Endpoints
   ============================================================================ */

.api-endpoints {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.endpoint {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
}

.method {
    padding: 0.25rem 0.5rem;
    border-radius: 5px;
    font-weight: 700;
    font-size: 0.75rem;
}

.method-get {
    background: rgba(0, 200, 255, 0.2);
    color: #00c8ff;
}

.method-post {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
}

.path {
    color: var(--text-secondary);
}

/* ============================================================================
   Glass Info
   ============================================================================ */

.glass-info {
    padding: 1rem;
    background: rgba(100, 200, 255, 0.1);
    border: 1px solid rgba(100, 200, 255, 0.2);
    border-radius: 10px;
    margin-bottom: 1rem;
}

.glass-info code {
    display: block;
    padding: 0.5rem;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 5px;
    margin-top: 0.5rem;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    word-break: break-all;
    color: #64c8ff;
}

/* ============================================================================
   Loader
   ============================================================================ */

.loader {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* ============================================================================
   Footer
   ============================================================================ */

.footer {
    margin-top: 4rem;
    padding: 3rem 2rem 1rem;
    background: rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    position: relative;
    z-index: 1;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover {
    color: var(--text-primary);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

/* ============================================================================
   Адаптивность
   ============================================================================ */

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .nav-links {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .features-grid,
    .pricing-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}



