/**
 * Noutăți / Blog Page — OPTEAM Construct
 */

/* Astra dark override */
.ot-noutati-page,
.ot-noutati-page .ast-container,
.ot-noutati-page #primary,
.ot-noutati-page .content-area,
.ot-noutati-page .site-main {
    background-color: var(--bg-primary) !important;
}

/* Page wrapper */
.ot-noutati-page {
    padding-top: clamp(120px, 14vw, 160px) !important;
    padding-bottom: 80px;
}

/* Tame lusion skew */
.ot-noutati-page .reveal { transform: translateY(24px) !important; transition: opacity 0.6s ease, transform 0.6s ease !important; }
.ot-noutati-page .reveal.visible { opacity: 1 !important; transform: translateY(0) !important; }
.ot-noutati-page .reveal-right { transform: translateX(24px) !important; transition: opacity 0.6s ease, transform 0.6s ease !important; }
.ot-noutati-page .reveal-right.visible { opacity: 1 !important; transform: translateX(0) !important; }

/* ============================================
   HERO
   ============================================ */
.ot-noutati-hero {
    text-align: center;
    margin-bottom: 48px;
}

.ot-noutati-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 900;
    margin: 16px 0 12px;
}

.ot-noutati-subtitle {
    color: var(--text-secondary);
    font-size: 1.05rem;
    max-width: 620px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ============================================
   LAYOUT
   ============================================ */
.ot-noutati-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    align-items: start;
}

@media (max-width: 900px) {
    .ot-noutati-layout {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   FEATURED POST
   ============================================ */
.ot-featured-post {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 40px;
    min-height: 380px;
    display: flex;
    align-items: flex-end;
    background: rgba(15, 25, 40, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.ot-featured-image {
    position: absolute;
    inset: 0;
}

.ot-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ot-featured-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(10, 14, 23, 0.95) 0%, rgba(10, 14, 23, 0.4) 50%, transparent 100%);
}

.ot-featured-content {
    position: relative;
    z-index: 1;
    padding: 32px;
    width: 100%;
}

.ot-post-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.ot-meta-cat {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent-gold);
    background: rgba(242, 183, 5, 0.12);
    border: 1px solid rgba(242, 183, 5, 0.2);
    padding: 4px 12px;
    border-radius: 999px;
}

.ot-meta-date {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    color: var(--text-muted);
}

.ot-featured-content h2 {
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    margin-bottom: 12px;
    line-height: 1.3;
}

.ot-featured-content h2 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s;
}

.ot-featured-content h2 a:hover {
    color: var(--accent-gold);
}

.ot-featured-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
    max-width: 600px;
}

/* ============================================
   POSTS GRID
   ============================================ */
.ot-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

@media (max-width: 600px) {
    .ot-posts-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   POST CARD
   ============================================ */
.ot-post-card {
    display: flex;
    flex-direction: column;
    background: rgba(15, 25, 40, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.ot-post-card:hover {
    transform: translateY(-6px);
    border-color: rgba(242, 183, 5, 0.3);
    box-shadow: 0 4px 24px rgba(242, 183, 5, 0.15), 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Thumbnail */
.ot-post-thumb-wrap {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.2);
}

.ot-post-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.ot-post-card:hover .ot-post-thumb {
    transform: scale(1.05);
}

.ot-post-tag-float {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 1;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent-gold);
    background: rgba(10, 14, 23, 0.85);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(242, 183, 5, 0.2);
    padding: 4px 10px;
    border-radius: 999px;
}

.ot-post-thumb-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: var(--accent-gold);
    background: linear-gradient(145deg, rgba(242, 183, 5, 0.06) 0%, var(--bg-secondary) 100%);
}

/* Body */
.ot-post-body {
    padding: 20px 24px 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.ot-post-date {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.ot-post-body h3 {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 10px;
    line-height: 1.35;
}

.ot-post-body h3 a {
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.2s;
}

.ot-post-body h3 a:hover {
    color: var(--accent-gold);
}

.ot-post-body p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin: 0 0 16px;
    flex: 1;
}

.ot-post-read-more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--accent-gold);
    text-decoration: none;
    transition: gap 0.2s ease;
    margin-top: auto;
}

.ot-post-read-more:hover {
    gap: 10px;
}

/* ============================================
   SIDEBAR
   ============================================ */
.ot-noutati-sidebar {
    position: sticky;
    top: calc(var(--header-height, 80px) + 20px);
    display: flex;
    flex-direction: column;
    gap: 24px;
}

@media (max-width: 900px) {
    .ot-noutati-sidebar {
        position: static;
    }
}

.ot-noutati-widget {
    background: rgba(15, 25, 40, 0.55);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    padding: 24px;
}

.ot-noutati-widget h4 {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent-gold);
    margin: 0 0 14px;
}

/* Search form */
.ot-noutati-search-form {
    position: relative;
}

.ot-noutati-search-form .ot-shop-input {
    width: 100%;
    padding: 12px 48px 12px 16px;
    background: rgba(10, 14, 23, 0.8);
    border: 1px solid rgba(242, 183, 5, 0.12);
    border-radius: 999px;
    color: var(--text-primary);
    font-size: 0.92rem;
    font-family: inherit;
    outline: none;
}

.ot-noutati-search-form .ot-shop-input:focus {
    border-color: rgba(242, 183, 5, 0.5);
    box-shadow: 0 0 0 3px rgba(242, 183, 5, 0.1);
}

.ot-noutati-search-btn {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-gold);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
    padding: 0;
}

.ot-noutati-search-btn:hover {
    background: rgba(242, 183, 5, 0.12);
    color: var(--accent-gold-hover);
}

/* Category list */
.ot-cat-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ot-cat-list li {
    margin-bottom: 4px;
}

.ot-cat-list a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    border-radius: 12px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: background 0.2s ease, color 0.2s ease;
}

.ot-cat-list a:hover,
.ot-cat-list a.active {
    background: rgba(242, 183, 5, 0.08);
    color: var(--accent-gold);
}

.ot-cat-count {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    background: rgba(10, 14, 23, 0.5);
    padding: 2px 8px;
    border-radius: 999px;
}

/* CTA widget */
.ot-noutati-cta {
    text-align: center;
    background: linear-gradient(145deg, rgba(242, 183, 5, 0.08) 0%, rgba(15, 25, 40, 0.55) 40%);
    border-color: rgba(242, 183, 5, 0.15);
}

.ot-noutati-cta h4 {
    margin-top: 12px;
    font-size: 1rem;
    color: var(--text-primary);
    text-transform: none;
    letter-spacing: 0;
}

.ot-noutati-cta p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 8px 0 20px;
}

/* ============================================
   EMPTY STATE
   ============================================ */
.ot-noutati-empty {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 24px;
    text-align: center;
    border: 2px dashed rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    color: var(--text-muted);
}

.ot-noutati-empty svg { margin-bottom: 16px; opacity: 0.5; }
.ot-noutati-empty h3 { color: var(--text-secondary); font-size: 1.1rem; margin: 0 0 8px; }
.ot-noutati-empty p { color: var(--text-muted); margin: 0 0 20px; }

/* ============================================
   OUTLINE BUTTON (used for filters/archive)
   ============================================ */
.ot-btn-outline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    border-radius: 999px;
    border: 1px solid rgba(242, 183, 5, 0.3);
    background: rgba(242, 183, 5, 0.06);
    color: var(--accent-gold);
    font-size: 0.88rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.ot-btn-outline:hover {
    background: rgba(242, 183, 5, 0.14);
    border-color: rgba(242, 183, 5, 0.5);
    transform: translateY(-2px);
    color: var(--accent-gold);
}

.ot-btn-outline svg {
    flex-shrink: 0;
}

/* ============================================
   REFINEMENTS — line-clamp, gaps, polish
   ============================================ */

/* Featured post excerpt — max 3 lines */
.ot-featured-content p {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Featured image as link — keep absolute positioning */
a.ot-featured-image {
    display: block;
    text-decoration: none;
}

/* Featured CTA button gap */
.ot-featured-content .ot-btn-gold {
    gap: 8px;
    text-decoration: none;
}

/* Post card title — max 2 lines */
.ot-post-body h3 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Post card excerpt — max 3 lines */
.ot-post-body p {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Read more hover — subtle underline */
.ot-post-read-more:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Category list active count badge */
.ot-cat-list a.active .ot-cat-count,
.ot-cat-list a:hover .ot-cat-count {
    background: rgba(242, 183, 5, 0.15);
    color: var(--accent-gold);
}

/* Search input placeholder */
.ot-noutati-search-form .ot-shop-input::placeholder {
    color: var(--text-muted);
    opacity: 0.7;
}

/* ============================================
   MOBILE REFINEMENTS
   ============================================ */
@media (max-width: 600px) {
    .ot-noutati-hero {
        margin-bottom: 32px;
    }

    .ot-noutati-title {
        font-size: 1.6rem;
    }

    .ot-noutati-subtitle {
        font-size: 0.95rem;
    }

    .ot-featured-post {
        min-height: 300px;
        border-radius: 16px;
    }

    .ot-featured-content {
        padding: 20px;
    }

    .ot-featured-content h2 {
        font-size: 1.2rem;
    }

    .ot-post-card {
        border-radius: 16px;
    }

    .ot-noutati-widget {
        border-radius: 16px;
    }

    .ot-noutati-cta .ot-btn-gold {
        font-size: 0.88rem;
        padding: 10px 20px;
    }
}
