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

:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f5f5f7;
    --bg-tertiary: #fafafa;
    --text-primary: #1d1d1f;
    --text-secondary: #86868b;
    --text-tertiary: #a1a1a6;
    --blue: #0071e3;
    --blue-hover: #0077ed;
    --gold: #d4a574;
    --gold-light: #f5e6d3;
    --red: #ff3b30;
    --green: #34c759;
    --border: #d5d5d7;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.16);
}

@media (prefers-color-scheme: dark) {
    :root {
        --bg-primary: #000000;
        --bg-secondary: #1d1d1f;
        --bg-tertiary: #424245;
        --text-primary: #f5f5f7;
        --text-secondary: #a1a1a6;
        --text-tertiary: #86868b;
        --border: #424245;
        --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
        --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
        --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.6);
    }
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 64px;
}

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

/* Header */
header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    height: 64px;
}

@media (prefers-color-scheme: dark) {
    header {
        background: rgba(0, 0, 0, 0.7);
    }
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    height: 100%;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
    cursor: pointer;
    transition: opacity 0.3s;
}

.logo:hover {
    opacity: 0.7;
}

.logo span {
    color: var(--blue);
}

.nav-menu {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-link {
    font-size: 15px;
    color: var(--text-primary);
    text-decoration: none;
    cursor: pointer;
    transition: color 0.3s, opacity 0.3s;
    position: relative;
}

.nav-link:hover {
    color: var(--blue);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--blue);
    transition: width 0.3s;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link.active {
    color: var(--blue);
}

.nav-link.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    gap: 16px;
    align-items: center;
}

.search-box {
    position: relative;
}

.search-input {
    width: 200px;
    padding: 8px 12px 8px 36px;
    border: 1px solid var(--border);
    border-radius: 20px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 15px;
    transition: all 0.3s;
}

.search-input::placeholder {
    color: var(--text-secondary);
}

.search-input:focus {
    outline: none;
    border-color: var(--blue);
    box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.1);
}

.search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}

.theme-toggle {
    ackground: var(--bg-secondary);
    border: 1px solid var(--border);
   border-radius: 20px;
    padding: 8px 12px;
    cursor: pointer;
    transition: all 0.3s;
    color: var(--text-primary);
    font-size: 15px;
}

.theme-toggle:hover {
    background: var(--bg-tertiary);
}

/* Main Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 40px;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(0, 113, 227, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
    z-index: 0;
}

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

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    text-align: center;
    animation: fadeInUp 0.8s ease;
}

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

.hero h1 {
    font-size: clamp(44px, 8vw, 72px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -1px;
    margin-bottom: 24px;
}

.hero p {
    font-size: 21px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.5;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    padding: 12px 28px;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--blue);
    color: white;
}

.btn-primary:hover {
    background: var(--blue-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-tertiary);
    border-color: var(--text-primary);
}

.btn-gold {
    background: var(--gold-light);
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-gold:hover {
    background: var(--gold);
    color: white;
}

/* Stats Section */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
    margin: 60px 0;
    padding: 40px;
    background: var(--bg-secondary);
    border-radius: 20px;
    animation: slideUp 0.8s ease 0.2s both;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

.stat-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--blue);
    margin-bottom: 8px;
}

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

/* Featured Section */
.featured-section {
    margin: 80px 0;
}

.section-title {
    font-size: 44px;
    font-weight: 700;
    margin-bottom: 40px;
    animation: slideUp 0.8s ease both;
}

.featured-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
}

@media (max-width: 1024px) {
    .featured-grid {
        grid-template-columns: 1fr;
    }
}

.featured-card {
    background: var(--bg-secondary);
    border-radius: 20px;
    padding: 40px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.featured-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--blue) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.4s;
}

.featured-card:hover {
    border-color: var(--blue);
    box-shadow: var(--shadow-lg);
    transform: translateY(-8px);
}

.featured-card:hover::before {
    opacity: 0.05;
}

.featured-card-content {
    position: relative;
    z-index: 1;
}

.featured-card.big {
    grid-row: span 2;
}

.featured-card h3 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 16px;
    line-height: 1.2;
}

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

.featured-card .meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: var(--text-tertiary);
}

.tag {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    background: var(--bg-primary);
    color: var(--blue);
}

.tag.premium {
    background: var(--gold-light);
    color: var(--gold);
}

/* Articles Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    margin: 40px 0;
}

.article-card {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.3s;
    border: 1px solid transparent;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    border-color: var(--blue);
    box-shadow: var(--shadow-md);
    transform: translateY(-4px);
}

.article-card h4 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
    line-height: 1.3;
}

.article-card p {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 16px;
    flex-grow: 1;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--text-tertiary);
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.read-time {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 2000;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: var(--bg-primary);
    border-radius: 20px;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 40px;
    animation: slideUp 0.3s ease;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--bg-secondary);
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    transition: all 0.3s;
}

.modal-close:hover {
    background: var(--border);
}

.article-header {
    margin-bottom: 24px;
}

.article-header .tags {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.article-header h2 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.2;
}

.article-meta-full {
    display: flex;
    gap: 20px;
    font-size: 14px;
    color: var(--text-secondary);
}

.article-body {
    line-height: 1.8;
    margin: 30px 0;
}

.article-body p {
    margin-bottom: 16px;
    font-size: 16px;
}

.why-matters {
    background: var(--gold-light);
    border-left: 4px solid var(--gold);
    padding: 20px;
    border-radius: 12px;
    margin: 30px 0;
}

.why-matters strong {
    color: var(--gold);
}

.source-link {
    display: inline-block;
    margin-top: 20px;
    padding: 12px 20px;
    background: var(--blue);
    color: white;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s;
}

.source-link:hover {
    background: var(--blue-hover);
}

/* Filters */
.filters {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin: 30px 0;
}

.filter-btn {
    padding: 8px 16px;
    border: 1px solid var(--border);
    background: var(--bg-secondary);
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text-primary);
    transition: all 0.3s;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--blue);
    color: white;
    border-color: var(--blue);
}

/* Pricing Section */
.pricing-section {
    margin: 80px 0;
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin: 40px 0;
}

.pricing-card {
    background: var(--bg-secondary);
    border: 2px solid transparent;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    transition: all 0.3s;
}

.pricing-card:hover {
    border-color: var(--blue);
    box-shadow: var(--shadow-lg);
    transform: translateY(-8px);
}

.pricing-card.featured {
    background: var(--blue);
    color: white;
}

.pricing-card.featured:hover {
    border-color: var(--blue);
}

.pricing-tier {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}

.pricing-price {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 8px;
}

.pricing-price span {
    font-size: 16px;
    font-weight: 400;
}

.pricing-desc {
    color: var(--text-secondary);
    margin-bottom: 24px;
    font-size: 15px;
}

.pricing-card.featured .pricing-desc {
    color: rgba(255, 255, 255, 0.8);
}

.pricing-features {
    text-align: left;
    margin: 24px 0;
    font-size: 14px;
}

.pricing-features li {
    list-style: none;
    padding: 8px 0;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.pricing-card.featured .pricing-features li {
    color: rgba(255, 255, 255, 0.9);
}

.pricing-features li::before {
    content: '✓';
    color: var(--green);
    font-weight: 700;
}

.pricing-card.featured .pricing-features li::before {
    color: white;
}

/* Newsletter */
.newsletter-section {
    margin: 80px 0;
    background: var(--bg-secondary);
    padding: 60px 40px;
    border-radius: 20px;
    text-align: center;
}

.newsletter-title {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 16px;
}

.newsletter-desc {
    color: var(--text-secondary);
    margin-bottom: 32px;
    font-size: 16px;
}

.newsletter-form {
    display: flex;
    gap: 12px;
    max-width: 500px;
    margin: 0 auto;
}

.newsletter-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg-primary);
    color: var(--text-primary);
    font-size: 15px;
}

.newsletter-input::placeholder {
    color: var(--text-secondary);
}

.newsletter-input:focus {
    outline: none;
    border-color: var(--blue);
    box-shadow: 0 0 0 3px rgba(0, 113, 227, 0.1);
}

/* Footer */
footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    margin-top: 80px;
    padding: 60px 40px 40px;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
}

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

.footer-section h4 {
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 16px;
}

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

.footer-section li {
    margin-bottom: 12px;
}

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

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

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-tertiary);
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--border);
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Responsive */
@media (max-width: 768px) {
    .header-content {
        padding: 0 20px;
    }

    .nav-menu {
        gap: 16px;
        font-size: 14px;
    }

    .search-input {
        width: 150px;
    }

    .container {
        padding: 0 20px;
    }

    .hero {
        padding: 60px 20px;
    }

    .hero h1 {
        font-size: 32px;
    }

    .hero p {
        font-size: 16px;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .featured-card.big {
        grid-row: auto;
    }

    .section-title {
        font-size: 32px;
    }

    .modal-content {
        padding: 24px;
        max-width: 95vw;
    }

    .newsletter-form {
        flex-direction: column;
    }
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 64px;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--blue), var(--gold));
    width: 0%;
    z-index: 999;
    transition: width 0.1s linear;
}

/* Pagination */
.pagination {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin: 40px 0;
}

.pagination button {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border);
    background: var(--bg-secondary);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 600;
}

.pagination button:hover,
.pagination button.active {
    background: var(--blue);
    color: white;
    border-color: var(--blue);
}

/* No Results */
.no-results {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.no-results svg {
    width: 80px;
    height: 80px;
    margin-bottom: 20px;
    opacity: 0.5;
}
