/*
 Theme Name:   OsintOps
 Theme URI:    https://osintops.com
 Description:  Child theme of Twenty Twenty-Four for OsintOps.com — v4A Offset Cards design system.
 Author:       OsintTrapper
 Author URI:   https://osintops.com
 Template:     twentytwentyfour
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  osintops
*/

/* ==========================================================================
   1. Design Tokens (v4A)
   ========================================================================== */

:root {
    /* Palette */
    --oo-primary: #1A2332;
    --oo-accent: #00B4D8;
    --oo-accent-light: #48CAE4;
    --oo-success: #06D6A0;
    --oo-warning: #FFD166;
    --oo-danger: #EF476F;
    --oo-bg: #F0F4F8;
    --oo-bg-dark: #0D1B2A;
    --oo-text: #2D3436;
    --oo-muted: #636E72;
    --oo-border: #DFE6E9;

    /* Typography */
    --oo-font-heading: 'Space Grotesk', sans-serif;
    --oo-font-body: 'Inter', sans-serif;
    --oo-font-mono: 'JetBrains Mono', monospace;
}

/* ==========================================================================
   2. Base Typography
   ========================================================================== */

body {
    font-family: var(--oo-font-body);
    color: var(--oo-text);
    background-color: var(--oo-bg);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--oo-font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--oo-text);
}

code, pre, kbd, samp {
    font-family: var(--oo-font-mono);
}

a {
    color: var(--oo-accent);
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--oo-accent-light);
}

/* ==========================================================================
   3. Header
   ========================================================================== */

.site-header,
header.wp-block-template-part {
    background-color: var(--oo-primary);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 12px 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.site-header a,
header.wp-block-template-part a {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    font-size: 14px;
    transition: color 0.3s ease;
}

.site-header a:hover,
header.wp-block-template-part a:hover {
    color: var(--oo-accent);
}

/* Logo text styling */
.oo-logo-text {
    font-family: var(--oo-font-heading);
    font-size: 22px;
    font-weight: 700;
    color: white;
}

.oo-logo-text span {
    color: var(--oo-accent);
}

/* Navigation */
.wp-block-navigation a {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
    font-size: 14px;
}

.wp-block-navigation a:hover {
    color: var(--oo-accent) !important;
}

/* ==========================================================================
   4. Hero Section
   ========================================================================== */

.oo-hero {
    background: linear-gradient(135deg, var(--oo-bg-dark) 0%, var(--oo-primary) 100%);
    padding: 100px 40px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    overflow: hidden;
    color: white;
}

.oo-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 180, 216, 0.15), transparent 70%);
    pointer-events: none;
}

.oo-hero-subtitle {
    font-family: var(--oo-font-mono);
    font-size: 13px;
    color: var(--oo-accent);
    letter-spacing: 2px;
    margin-bottom: 16px;
    text-transform: uppercase;
}

.oo-hero-title {
    font-family: var(--oo-font-heading);
    font-size: 48px;
    font-weight: 700;
    line-height: 1.15;
    margin-bottom: 20px;
    color: white;
}

.oo-hero-title span {
    color: var(--oo-accent);
}

.oo-hero-description {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 32px;
    max-width: 400px;
}

/* Hero circle animation */
.oo-hero-circle {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--oo-accent) 0%, var(--oo-accent-light) 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    animation: oo-pulse-glow 3s ease-in-out infinite;
    box-shadow: 0 0 60px rgba(0, 180, 216, 0.3);
    margin: 0 auto;
}

@keyframes oo-pulse-glow {
    0%, 100% { transform: scale(1); box-shadow: 0 0 60px rgba(0, 180, 216, 0.3); }
    50% { transform: scale(1.05); box-shadow: 0 0 100px rgba(0, 180, 216, 0.5); }
}

.oo-hero-circle img {
    width: 180px;
    height: auto;
}

/* ==========================================================================
   5. Buttons
   ========================================================================== */

.oo-btn,
.wp-block-button__link {
    padding: 12px 28px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
    font-family: var(--oo-font-body);
    display: inline-block;
}

.oo-btn-primary,
.wp-block-button.is-style-fill .wp-block-button__link {
    background-color: var(--oo-accent);
    color: var(--oo-bg-dark);
}

.oo-btn-primary:hover,
.wp-block-button.is-style-fill .wp-block-button__link:hover {
    background-color: var(--oo-accent-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 180, 216, 0.3);
    color: var(--oo-bg-dark);
}

.oo-btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.oo-btn-secondary:hover {
    background-color: white;
    color: var(--oo-bg-dark);
    transform: translateY(-2px);
}

/* ==========================================================================
   6. Stats Bar
   ========================================================================== */

.oo-stats-bar {
    background-color: white;
    padding: 40px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.oo-stat-number {
    font-family: var(--oo-font-heading);
    font-size: 36px;
    font-weight: 700;
    color: var(--oo-accent);
    margin-bottom: 8px;
    text-align: center;
}

.oo-stat-label {
    font-size: 14px;
    color: var(--oo-muted);
    font-weight: 500;
    text-align: center;
}

/* ==========================================================================
   7. Article Cards — Offset Effect (v4A signature)
   ========================================================================== */

.oo-articles-section {
    padding: 80px 40px;
    background-color: var(--oo-bg);
}

.oo-section-title {
    font-family: var(--oo-font-heading);
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 48px;
    color: var(--oo-text);
}

/* Featured article */
.oo-featured-article {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 40px;
    margin-bottom: 48px;
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.oo-featured-article-image {
    background-color: var(--oo-primary);
    position: relative;
    overflow: hidden;
    min-height: 320px;
}

.oo-featured-article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.oo-featured-article-content {
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Article cards grid */
.oo-articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.oo-article-card {
    background-color: white;
    border-radius: 12px;
    overflow: visible;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.oo-article-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

/* Offset image container — the v4A signature effect */
.oo-card-image-container {
    position: relative;
    height: 240px;
    background-color: var(--oo-primary);
    overflow: hidden;
    margin-top: -35px;
    margin-left: 12px;
    margin-right: 12px;
    border-radius: 8px;
    transform: rotate(-2deg);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.oo-article-card:hover .oo-card-image-container {
    transform: rotate(0deg) translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
}

.oo-card-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Card badges */
.oo-card-badges {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    justify-content: space-between;
    z-index: 10;
}

/* Card content */
.oo-card-content {
    padding: 32px 20px 24px;
}

.oo-card-title {
    font-family: var(--oo-font-heading);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--oo-text);
    line-height: 1.3;
}

.oo-card-excerpt {
    color: var(--oo-muted);
    font-size: 14px;
    margin-bottom: 16px;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Card meta */
.oo-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--oo-muted);
}

.oo-card-author-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: var(--oo-accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 12px;
    flex-shrink: 0;
}

/* Category & language badges */
.oo-article-category {
    display: inline-block;
    background-color: var(--oo-accent);
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 16px;
    width: fit-content;
}

.oo-article-lang {
    display: inline-block;
    background-color: var(--oo-warning);
    color: var(--oo-bg-dark);
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
    margin-left: 8px;
}

/* Article meta */
.oo-article-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--oo-muted);
    font-size: 13px;
}

.oo-author-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: var(--oo-accent);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

/* ==========================================================================
   8. Categories Section
   ========================================================================== */

.oo-categories-section {
    padding: 80px 40px;
    background-color: white;
}

.oo-categories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.oo-category-card {
    background: linear-gradient(135deg, rgba(0, 180, 216, 0.1) 0%, rgba(72, 202, 228, 0.05) 100%);
    border: 1px solid var(--oo-border);
    border-radius: 12px;
    padding: 32px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.oo-category-card:hover {
    border-color: var(--oo-accent);
    box-shadow: 0 8px 20px rgba(0, 180, 216, 0.15);
    transform: translateY(-4px);
}

.oo-category-icon {
    font-size: 40px;
    margin-bottom: 16px;
}

.oo-category-title {
    font-family: var(--oo-font-heading);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--oo-text);
}

.oo-category-desc {
    font-size: 13px;
    color: var(--oo-muted);
    margin-bottom: 12px;
}

.oo-category-count {
    font-size: 12px;
    color: var(--oo-accent);
    font-weight: 600;
}

/* ==========================================================================
   9. Projects Section
   ========================================================================== */

.oo-projects-section {
    padding: 80px 40px;
    background: linear-gradient(135deg, var(--oo-bg-dark) 0%, var(--oo-primary) 100%);
    color: white;
}

.oo-projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.oo-project-card {
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 32px;
    transition: all 0.3s ease;
}

.oo-project-card:hover {
    background-color: rgba(255, 255, 255, 0.08);
    border-color: var(--oo-accent);
    box-shadow: 0 8px 24px rgba(0, 180, 216, 0.2);
    transform: translateY(-4px);
}

.oo-project-title {
    font-family: var(--oo-font-heading);
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 12px;
}

.oo-project-desc {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 20px;
    line-height: 1.6;
}

.oo-project-link {
    color: var(--oo-accent);
    text-decoration: none;
    font-weight: 600;
    font-size: 13px;
    display: inline-flex;
    gap: 8px;
    transition: gap 0.3s ease;
}

.oo-project-link:hover {
    gap: 12px;
}

/* ==========================================================================
   10. Team Section
   ========================================================================== */

.oo-team-section {
    padding: 80px 40px;
    background-color: var(--oo-bg);
}

.oo-team-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 24px;
}

.oo-team-card {
    background-color: white;
    border-radius: 12px;
    padding: 24px;
    text-align: center;
    border: 1px solid var(--oo-border);
    transition: all 0.3s ease;
}

.oo-team-card:hover {
    border-color: var(--oo-accent);
    box-shadow: 0 8px 20px rgba(0, 180, 216, 0.15);
    transform: translateY(-4px);
}

.oo-team-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--oo-accent) 0%, var(--oo-accent-light) 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 24px;
    margin: 0 auto 16px;
}

.oo-team-name {
    font-family: var(--oo-font-heading);
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--oo-text);
}

.oo-team-role {
    font-size: 12px;
    color: var(--oo-accent);
    font-weight: 600;
}

/* ==========================================================================
   11. Footer
   ========================================================================== */

.site-footer,
footer.wp-block-template-part {
    background-color: var(--oo-bg-dark);
    color: white;
    padding: 60px 40px 20px;
}

.oo-footer-content {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    margin-bottom: 40px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 40px;
}

.oo-footer-column h4 {
    font-family: var(--oo-font-heading);
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--oo-accent);
}

.oo-footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

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

.oo-footer-column a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.oo-footer-column a:hover {
    color: var(--oo-accent);
}

.oo-footer-bottom {
    text-align: center;
    padding-top: 20px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
}

/* ==========================================================================
   13. WordPress Block Overrides
   ========================================================================== */

/* Post loop cards — apply offset card effect to standard WP post grids */
.wp-block-post-template .wp-block-post {
    background-color: white;
    border-radius: 12px;
    overflow: visible;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.wp-block-post-template .wp-block-post:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
}

/* Post featured image in loops */
.wp-block-post-featured-image {
    border-radius: 8px;
    overflow: hidden;
}

/* Post title */
.wp-block-post-title {
    font-family: var(--oo-font-heading);
    font-weight: 700;
    color: var(--oo-text);
}

.wp-block-post-title a {
    color: var(--oo-text);
}

.wp-block-post-title a:hover {
    color: var(--oo-accent);
}

/* Post excerpt */
.wp-block-post-excerpt {
    color: var(--oo-muted);
    font-size: 14px;
    line-height: 1.5;
}

/* Post date */
.wp-block-post-date {
    color: var(--oo-muted);
    font-size: 13px;
}

/* Search box */
.wp-block-search__input {
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: white;
    padding: 8px 16px;
    font-family: var(--oo-font-body);
    font-size: 14px;
}

.wp-block-search__input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.wp-block-search__input:focus {
    outline: none;
    border-color: var(--oo-accent);
}

/* Headings inside content */
.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
    font-family: var(--oo-font-heading);
    color: var(--oo-text);
}

/* Code blocks */
.wp-block-code,
pre.wp-block-code {
    font-family: var(--oo-font-mono);
    background-color: var(--oo-primary);
    color: var(--oo-accent-light);
    border-radius: 8px;
    padding: 24px;
    border: none;
}

/* Blockquotes */
.wp-block-quote {
    border-left: 4px solid var(--oo-accent);
    padding-left: 24px;
    font-style: italic;
    color: var(--oo-muted);
}

/* Tables */
.wp-block-table table {
    border-collapse: collapse;
    width: 100%;
}

.wp-block-table th {
    background-color: var(--oo-primary);
    color: white;
    font-family: var(--oo-font-heading);
    padding: 12px 16px;
    text-align: left;
}

.wp-block-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--oo-border);
}

/* ==========================================================================
   14. Utility Classes (for Elementor custom CSS)
   ========================================================================== */

.oo-bg-dark { background-color: var(--oo-bg-dark); }
.oo-bg-primary { background-color: var(--oo-primary); }
.oo-bg-accent { background-color: var(--oo-accent); }
.oo-bg-light { background-color: var(--oo-bg); }
.oo-bg-white { background-color: white; }

.oo-text-accent { color: var(--oo-accent); }
.oo-text-muted { color: var(--oo-muted); }
.oo-text-white { color: white; }
.oo-text-dark { color: var(--oo-text); }

.oo-font-heading { font-family: var(--oo-font-heading); }
.oo-font-mono { font-family: var(--oo-font-mono); }

.oo-gradient-hero { background: linear-gradient(135deg, var(--oo-bg-dark) 0%, var(--oo-primary) 100%); }
.oo-gradient-accent { background: linear-gradient(135deg, var(--oo-accent) 0%, var(--oo-accent-light) 100%); }

/* ==========================================================================
   15. Responsive
   ========================================================================== */

@media (max-width: 768px) {
    .oo-hero {
        grid-template-columns: 1fr;
        padding: 60px 20px;
        gap: 40px;
    }

    .oo-hero-title {
        font-size: 36px;
    }

    .oo-stats-bar {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        padding: 24px 20px;
    }

    .oo-articles-section,
    .oo-categories-section,
    .oo-projects-section,
    .oo-team-section {
        padding: 60px 20px;
    }

    .oo-featured-article {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .oo-featured-article-image {
        height: 280px;
    }

    .oo-featured-article-content {
        padding: 24px;
    }

    .oo-articles-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .oo-categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .oo-projects-grid {
        grid-template-columns: 1fr;
    }

    .oo-team-grid {
        grid-template-columns: repeat(3, 1fr);
    }



    .oo-footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .oo-hero-title {
        font-size: 28px;
    }

    .oo-categories-grid {
        grid-template-columns: 1fr;
    }

    .oo-team-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .oo-footer-content {
        grid-template-columns: 1fr;
    }
}
