/*
Theme Name: TaxPilot Portal
Author: Senior Frontend Designer
Description: Концепция "Precision Dashboard": Индустриальная точность, навигация в мире налогов и данных.
Version: 1.0.0
Text Domain: taxpilot
*/

:root {
    /* Colors - Cockpit Precision */
    --bg: #0f172a; /* Deep Navy */
    --surface: #1e293b;
    --surface-light: #334155;
    --primary: #f97316; /* Pilot Orange */
    --primary-dim: rgba(249, 115, 22, 0.1);
    --accent: #38bdf8; /* Sky Blue */
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --border: #334155;
    
    /* Spacing */
    --gap: 2rem;
    --header-height: 80px;
    --container-width: 1400px;
    
    /* Fonts */
    --font-display: 'Syne', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { 
    background-color: var(--bg); 
    color: var(--text); 
    font-family: var(--font-body); 
    line-height: 1.6; 
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
a { color: inherit; text-decoration: none; transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
ul { list-style: none; }

.container { max-width: var(--container-width); margin: 0 auto; padding: 0 var(--gap); }

/* Typography */
h1, h2, h3 { font-family: var(--font-display); font-weight: 800; text-transform: uppercase; line-height: 1.1; letter-spacing: -0.02em; }
.text-mono { font-family: var(--font-mono); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.15em; font-weight: 600; }

/* Header - Floating Rig */
.site-header {
    height: var(--header-height);
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 4rem; /* По памятке */
}

.logo {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 900;
    letter-spacing: -1px;
    color: #fff;
    flex-shrink: 0; /* По памятке */
}

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

.main-nav ul { 
    display: flex; 
    gap: 3.5rem; /* По памятке */
}
.main-nav a { font-family: var(--font-mono); font-size: 0.8rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; }
.main-nav a:hover, .main-nav .current-menu-item a { color: var(--primary); }

.menu-toggle { display: none; background: var(--surface); color: #fff; border: 1px solid var(--border); padding: 0.6rem; cursor: pointer; border-radius: 4px; }
.hamburger { width: 20px; height: 2px; background: #fff; position: relative; display: block; }
.hamburger::before, .hamburger::after { content: ''; position: absolute; width: 20px; height: 2px; background: #fff; left: 0; transition: 0.3s; }
.hamburger::before { top: -6px; }
.hamburger::after { top: 6px; }

.menu-toggle.is-active .hamburger { background: transparent; }
.menu-toggle.is-active .hamburger::before { transform: rotate(45deg); top: 0; }
.menu-toggle.is-active .hamburger::after { transform: rotate(-45deg); top: 0; }

/* Hero - Option D: Split Screen (50/50) */
.hero {
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--border);
}

.hero-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 8rem 0;
    background: radial-gradient(circle at 10% 90%, var(--primary-dim) 0%, transparent 40%);
}

.hero-visual {
    flex: 1;
    background: var(--surface);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border-left: 1px solid var(--border);
}

.hero-visual::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent 48%, var(--border) 50%, transparent 52%);
    background-size: 40px 40px;
    opacity: 0.3;
}

.hero-visual-inner {
    position: relative;
    z-index: 2;
    width: 85%;
    max-width: 700px;
    display: flex;
    justify-content: center;
}

.hero-banner-img {
    display: block;
    width: 100%;
    height: auto;
    min-height: 300px; /* Гарантируем минимальную высоту */
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid var(--primary);
    box-shadow: 0 0 50px rgba(249, 115, 22, 0.3);
    transform: rotate(-2deg);
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.hero-visual:hover .hero-banner-img {
    transform: rotate(0deg) scale(1.05);
}

.hero h1 { font-size: clamp(3rem, 6vw, 4.5rem); margin-bottom: 2.5rem; }
.hero-desc { font-size: 1.4rem; color: var(--text-muted); max-width: 600px; line-height: 1.4; margin-bottom: 3rem; }

/* Dashboard Cards */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1px;
    background: var(--border);
    margin-top: -1px;
    border-bottom: 1px solid var(--border);
}

.dash-card {
    background: var(--bg);
    padding: 3rem 2rem;
    transition: background 0.3s;
}

.dash-card:hover { background: var(--surface); }
.dash-card h3 { font-size: 0.9rem; margin-bottom: 1rem; color: var(--primary); font-family: var(--font-mono); }
.dash-card p { font-size: 0.85rem; color: var(--text-muted); }

/* Post Grid */
.section-header {
    padding: 8rem 0 3rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 4rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.section-header h2 { font-size: 2.5rem; }

.post-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 4rem;
    padding-bottom: 8rem;
}

.post-card {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border);
    min-width: 0;
}

.card-img-wrap {
    aspect-ratio: 16/10;
    overflow: hidden;
    position: relative;
}

.card-img { width: 100%; height: 100%; object-fit: cover; transition: 0.8s; opacity: 0.7; }
.post-card:hover .card-img { transform: scale(1.1); opacity: 1; }

.card-body { padding: 3rem 2.5rem; flex-grow: 1; display: flex; flex-direction: column; }
.card-meta { font-family: var(--font-mono); font-size: 0.7rem; color: var(--primary); margin-bottom: 1.5rem; display: block; }
.card-title { font-size: 1.6rem; margin-bottom: 1.5rem; line-height: 1.2; text-transform: none; }
.card-excerpt { color: var(--text-muted); font-size: 1rem; margin-bottom: 2.5rem; flex-grow: 1; }

.btn-pilot {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text);
    padding: 1rem 0;
    border-top: 1px solid var(--border);
    width: 100%;
    margin-top: auto;
}

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

/* Pagination */
.pagination-container { padding-bottom: 8rem; }
.pagination-list { display: flex; justify-content: center; gap: 0.5rem; }
.pagination-item a, .pagination-item span {
    width: 50px; height: 50px;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--border);
    font-family: var(--font-mono);
    font-size: 0.8rem;
}
.pagination-item.is-active span { background: var(--primary); color: #fff; border-color: var(--primary); }

/* Footer */
.site-footer {
    padding: 8rem 0 4rem;
    background: var(--surface);
    border-top: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 4rem;
    margin-bottom: 6rem;
}

.footer-col h4 { font-family: var(--font-mono); font-size: 0.75rem; color: var(--primary); margin-bottom: 2rem; letter-spacing: 0.2em; }
.footer-contact-item { margin-bottom: 2rem; }
.footer-contact-item label { display: block; font-size: 0.65rem; color: var(--text-muted); text-transform: uppercase; margin-bottom: 0.5rem; }
.footer-contact-item span { font-size: 1.1rem; }

.footer-bottom {
    padding-top: 3rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Mobile Adjustments */
@media (max-width: 1024px) {
    .hero { flex-direction: column; }
    .hero-visual { border-left: none; border-top: 1px solid var(--border); min-height: 400px; }
    .dashboard-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 768px) {
    .header-inner { gap: 2rem; }
    .main-nav { display: none; }
    .main-nav.is-active { 
        display: block; 
        position: absolute; top: 100%; left: 0; width: 100%; 
        background: var(--bg); padding: 2rem; border-bottom: 1px solid var(--border);
    }
    .main-nav.is-active ul { flex-direction: column; gap: 1.5rem; }
    .menu-toggle { display: block; }
}

@media (max-width: 640px) {
    .dashboard-grid { grid-template-columns: 1fr; }
    .post-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .hero h1 { font-size: 2.5rem; }
}
