/* ==========================================
   Updates Section Styles
   ========================================== */

/* Updates Section */
.updates-section {
    padding: var(--space-3xl) 0;
    background: linear-gradient(180deg, var(--color-bg) 0%, var(--color-bg-warm) 100%);
    position: relative;
    overflow: hidden;
}

.updates-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-secondary), transparent);
}

.updates-section .section-header {
    text-align: center;
    margin-bottom: var(--space-2xl);
}

.updates-section .section-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, rgba(201, 162, 39, 0.15), rgba(217, 119, 6, 0.1));
    color: var(--color-accent);
    padding: 0.5rem 1.25rem;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(201, 162, 39, 0.3);
}

.updates-section .section-tag i {
    font-size: 1rem;
}

.updates-section h2 {
    font-size: clamp(2rem, 4vw, 2.75rem);
    color: var(--color-primary-dark);
    margin-bottom: 0.75rem;
}

.updates-section .section-subtitle {
    color: var(--color-text-light);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Updates Grid */
.updates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-bottom: var(--space-xl);
}

/* Update Card */
.update-card {
    background: white;
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    display: flex;
    flex-direction: column;
}

.update-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.update-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--color-secondary), var(--color-accent));
    z-index: 1;
}

/* Update Image */
.update-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.update-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.update-card:hover .update-image img {
    transform: scale(1.08);
}

.update-image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 40%, rgba(0, 0, 0, 0.6) 100%);
    pointer-events: none;
}

/* Update Category Badge */
.update-category {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.95);
    color: var(--color-primary);
    padding: 0.4rem 1rem;
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

[dir="ltr"] .update-category {
    right: auto;
    left: 1rem;
}

/* Update Date Badge */
.update-date-badge {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, var(--color-secondary), var(--color-accent));
    color: white;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px rgba(201, 162, 39, 0.4);
}

[dir="ltr"] .update-date-badge {
    right: auto;
    left: 1rem;
}

/* No Image Placeholder */
.update-image.no-image {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.update-image.no-image i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.2);
}

/* Update Content */
.update-content {
    padding: 1.75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.update-title {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--color-primary-dark);
    margin-bottom: 0.75rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.update-excerpt {
    color: var(--color-text-light);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 1.25rem;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Update Meta */
.update-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    border-top: 1px solid var(--color-border);
    margin-top: auto;
}

.update-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.update-tag {
    background: var(--color-bg-warm);
    color: var(--color-text-light);
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 500;
}

.update-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-secondary);
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.update-link:hover {
    color: var(--color-accent);
    gap: 0.75rem;
}

.update-link i {
    transition: transform 0.3s ease;
}

.update-link:hover i {
    transform: translateX(-4px);
}

[dir="ltr"] .update-link:hover i {
    transform: translateX(4px);
}

/* View All Updates Link */
.updates-cta {
    text-align: center;
    margin-top: var(--space-lg);
}

.updates-cta .btn {
    padding: 1rem 2.5rem;
    font-size: 1.05rem;
}

/* Featured Update Card */
.update-card.featured {
    grid-column: span 2;
}

.update-card.featured .update-image {
    height: 280px;
}

.update-card.featured .update-title {
    font-size: 1.6rem;
}

@media (max-width: 768px) {
    .update-card.featured {
        grid-column: span 1;
    }
    
    .update-card.featured .update-image {
        height: 220px;
    }
}

/* ==========================================
   Updates Full Page Styles
   ========================================== */

.updates-page-hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    padding: 10rem 0 4rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.updates-page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23c9a227' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.updates-page-hero h1 {
    color: white;
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
    position: relative;
}

.updates-page-hero p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

/* Updates Page Content */
.updates-page-content {
    padding: var(--space-2xl) 0;
    background: var(--color-bg);
    min-height: 60vh;
}

/* Update Filters */
.updates-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-bottom: var(--space-xl);
}

.filter-btn {
    background: white;
    border: 2px solid var(--color-border);
    color: var(--color-text);
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-full);
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn:hover {
    border-color: var(--color-secondary);
    color: var(--color-secondary);
}

.filter-btn.active {
    background: linear-gradient(135deg, var(--color-secondary), var(--color-accent));
    color: white;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(201, 162, 39, 0.3);
}

/* Updates Full Grid */
.updates-full-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 2.5rem;
}

@media (max-width: 480px) {
    .updates-grid,
    .updates-full-grid {
        grid-template-columns: 1fr;
    }
}

/* Single Update Page */
.update-single-hero {
    position: relative;
    height: 50vh;
    min-height: 400px;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: flex-end;
}

.update-single-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 35, 65, 0.95) 0%, rgba(15, 35, 65, 0.3) 50%, transparent 100%);
}

.update-single-hero .container {
    position: relative;
    padding-bottom: 3rem;
}

.update-single-hero h1 {
    color: white;
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
    max-width: 800px;
}

.update-single-meta {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    flex-wrap: wrap;
}

.update-single-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Update Content */
.update-single-content {
    padding: var(--space-2xl) 0;
    background: white;
}

.update-single-content .container {
    max-width: 900px;
}

.update-body {
    font-size: 1.15rem;
    line-height: 1.9;
    color: var(--color-text);
}

.update-body h2 {
    font-size: 1.75rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    color: var(--color-primary-dark);
}

.update-body h3 {
    font-size: 1.4rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: var(--color-primary);
}

.update-body p {
    margin-bottom: 1.5rem;
}

.update-body img {
    border-radius: var(--radius-lg);
    margin: 2rem 0;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.update-body blockquote {
    background: linear-gradient(135deg, var(--color-bg-warm), var(--color-bg));
    border-right: 4px solid var(--color-secondary);
    padding: 1.5rem 2rem;
    margin: 2rem 0;
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-style: italic;
    color: var(--color-primary);
}

[dir="ltr"] .update-body blockquote {
    border-right: none;
    border-left: 4px solid var(--color-secondary);
    border-radius: var(--radius-md) 0 0 var(--radius-md);
}

.update-body ul, 
.update-body ol {
    margin: 1.5rem 0;
    padding-right: 1.5rem;
}

[dir="ltr"] .update-body ul,
[dir="ltr"] .update-body ol {
    padding-right: 0;
    padding-left: 1.5rem;
}

.update-body li {
    margin-bottom: 0.75rem;
}

/* Update Gallery */
.update-gallery {
    margin-top: var(--space-xl);
    padding-top: var(--space-xl);
    border-top: 1px solid var(--color-border);
}

.update-gallery h3 {
    text-align: center;
    margin-bottom: var(--space-lg);
    color: var(--color-primary-dark);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1rem;
}

.gallery-item {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0);
    transition: background 0.3s ease;
}

.gallery-item:hover::after {
    background: rgba(0, 0, 0, 0.2);
}

/* Back Button */
.update-back {
    margin-bottom: var(--space-lg);
}

.update-back a {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--color-text-light);
    font-weight: 500;
    transition: color 0.3s ease;
}

.update-back a:hover {
    color: var(--color-secondary);
}

/* Share Buttons */
.update-share {
    margin-top: var(--space-xl);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--color-border);
    text-align: center;
}

.update-share h4 {
    margin-bottom: 1rem;
    color: var(--color-text-light);
    font-size: 1rem;
}

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

.share-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: white;
    transition: all 0.3s ease;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.share-btn.facebook { background: #1877f2; }
.share-btn.twitter { background: #1da1f2; }
.share-btn.whatsapp { background: #25d366; }
.share-btn.linkedin { background: #0a66c2; }
.share-btn.email { background: var(--color-primary); }

/* Empty State */
.updates-empty {
    text-align: center;
    padding: var(--space-3xl) var(--space-lg);
}

.updates-empty i {
    font-size: 4rem;
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
}

.updates-empty h3 {
    color: var(--color-text);
    margin-bottom: 0.75rem;
}

.updates-empty p {
    color: var(--color-text-light);
}

/* Pagination */
.updates-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: var(--space-xl);
}

.pagination-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border: 2px solid var(--color-border);
    color: var(--color-text);
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
}

.pagination-btn:hover {
    border-color: var(--color-secondary);
    color: var(--color-secondary);
}

.pagination-btn.active {
    background: linear-gradient(135deg, var(--color-secondary), var(--color-accent));
    color: white;
    border-color: transparent;
}

.pagination-btn.nav {
    width: auto;
    padding: 0 1.25rem;
    border-radius: var(--radius-full);
}

/* Loading Animation */
.updates-loading {
    display: flex;
    justify-content: center;
    padding: var(--space-2xl);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--color-border);
    border-top-color: var(--color-secondary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

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

.update-card {
    animation: fadeInUp 0.6s ease forwards;
}

.update-card:nth-child(2) { animation-delay: 0.1s; }
.update-card:nth-child(3) { animation-delay: 0.2s; }
.update-card:nth-child(4) { animation-delay: 0.3s; }
.update-card:nth-child(5) { animation-delay: 0.4s; }
.update-card:nth-child(6) { animation-delay: 0.5s; }
