/**
 * Woroku Theme - Detik.com Inspired Design
 * Professional News Portal Style
 * Version: 3.0.0
 * 
 * Design Philosophy:
 * - Clean, modern, professional
 * - Red accent color (customizable)
 * - Grid-based layout
 * - Breaking news focus
 * - Fast loading
 * - Mobile-first
 */

/* ============================================
   CSS VARIABLES - CUSTOMIZABLE COLORS
   ============================================ */

:root {
    /* Primary Colors */
    --woroku-primary: #E01A22;
    --woroku-primary-dark: #B01218;
    --woroku-primary-light: #FF2A32;
    --woroku-primary-pale: #FFF5F5;
    
    /* Neutral Colors */
    --woroku-dark: #1A1A1A;
    --woroku-gray-900: #2D2D2D;
    --woroku-gray-800: #424242;
    --woroku-gray-700: #616161;
    --woroku-gray-600: #757575;
    --woroku-gray-500: #9E9E9E;
    --woroku-gray-400: #BDBDBD;
    --woroku-gray-300: #E0E0E0;
    --woroku-gray-200: #EEEEEE;
    --woroku-gray-100: #F5F5F5;
    --woroku-gray-50: #FAFAFA;
    --woroku-white: #FFFFFF;
    
    /* Accent Colors */
    --woroku-success: #4CAF50;
    --woroku-warning: #FF9800;
    --woroku-info: #2196F3;
    --woroku-danger: #F44336;
    
    /* Typography */
    --woroku-font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --woroku-font-secondary: 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif;
    --woroku-font-heading: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    
    /* Spacing */
    --woroku-container-width: 1200px;
    --woroku-gutter: 20px;
    --woroku-section-padding: 40px 0;
    
    /* Effects */
    --woroku-shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --woroku-shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --woroku-shadow-lg: 0 10px 20px rgba(0, 0, 0, 0.12);
    --woroku-radius-sm: 4px;
    --woroku-radius-md: 8px;
    --woroku-radius-lg: 12px;
    --woroku-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   RESET & BASE STYLES
   ============================================ */

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--woroku-font-primary);
    font-size: 15px;
    line-height: 1.7;
    color: var(--woroku-dark);
    background: var(--woroku-gray-50);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--woroku-transition);
}

a:hover {
    color: var(--woroku-primary);
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--woroku-font-heading);
    font-weight: 700;
    line-height: 1.3;
    color: var(--woroku-dark);
    margin-bottom: 16px;
}

h1 { font-size: 32px; }
h2 { font-size: 28px; }
h3 { font-size: 24px; }
h4 { font-size: 20px; }
h5 { font-size: 18px; }
h6 { font-size: 16px; }

p {
    margin-bottom: 16px;
}

.lead {
    font-size: 18px;
    font-weight: 400;
    color: var(--woroku-gray-700);
    line-height: 1.6;
}

/* ============================================
   CONTAINER & LAYOUT
   ============================================ */

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

.woroku-container-fluid {
    width: 100%;
    padding: 0 var(--woroku-gutter);
}

.woroku-row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -10px;
}

.woroku-col {
    flex: 1;
    padding: 0 10px;
}

/* Grid System */
.woroku-grid {
    display: grid;
    gap: 20px;
}

.woroku-grid-2 { grid-template-columns: repeat(2, 1fr); }
.woroku-grid-3 { grid-template-columns: repeat(3, 1fr); }
.woroku-grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
    .woroku-grid-4 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .woroku-grid-2,
    .woroku-grid-3,
    .woroku-grid-4 { grid-template-columns: 1fr; }
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */

.woroku-header {
    background: var(--woroku-white);
    box-shadow: var(--woroku-shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.woroku-header-top {
    background: var(--woroku-dark);
    color: var(--woroku-white);
    padding: 8px 0;
    font-size: 13px;
}

.woroku-header-top .woroku-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.woroku-header-date {
    display: flex;
    align-items: center;
    gap: 15px;
}

.woroku-header-date svg {
    width: 16px;
    height: 16px;
}

.woroku-header-social {
    display: flex;
    gap: 12px;
}

.woroku-header-social a {
    color: var(--woroku-white);
    font-size: 16px;
    transition: var(--woroku-transition);
}

.woroku-header-social a:hover {
    color: var(--woroku-primary);
}

.woroku-header-main {
    padding: 20px 0;
    border-bottom: 1px solid var(--woroku-gray-200);
}

.woroku-header-main .woroku-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.woroku-logo {
    font-size: 32px;
    font-weight: 900;
    color: var(--woroku-primary);
    letter-spacing: -1px;
}

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

.woroku-search-trigger,
.woroku-menu-trigger {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--woroku-dark);
    cursor: pointer;
    padding: 8px;
    transition: var(--woroku-transition);
}

.woroku-search-trigger:hover,
.woroku-menu-trigger:hover {
    color: var(--woroku-primary);
}

/* Navigation Menu */
.woroku-nav {
    background: var(--woroku-white);
    border-bottom: 3px solid var(--woroku-primary);
}

.woroku-nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.woroku-nav-menu::-webkit-scrollbar {
    height: 3px;
}

.woroku-nav-menu::-webkit-scrollbar-thumb {
    background: var(--woroku-primary);
}

.woroku-nav-menu li {
    flex-shrink: 0;
}

.woroku-nav-menu a {
    display: block;
    padding: 15px 20px;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--woroku-gray-800);
    transition: var(--woroku-transition);
    border-bottom: 3px solid transparent;
}

.woroku-nav-menu a:hover,
.woroku-nav-menu li.current-menu-item a {
    color: var(--woroku-primary);
    border-bottom-color: var(--woroku-primary);
}

/* ============================================
   BREAKING NEWS TICKER
   ============================================ */

.woroku-breaking-news {
    background: var(--woroku-primary);
    color: var(--woroku-white);
    padding: 12px 0;
    overflow: hidden;
}

.woroku-breaking-news .woroku-container {
    display: flex;
    align-items: center;
    gap: 20px;
}

.woroku-breaking-label {
    background: var(--woroku-dark);
    padding: 6px 16px;
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    flex-shrink: 0;
    border-radius: var(--woroku-radius-sm);
}

.woroku-breaking-content {
    flex: 1;
    overflow: hidden;
}

.woroku-breaking-slider {
    display: flex;
    animation: marquee 30s linear infinite;
}

.woroku-breaking-slider:hover {
    animation-play-state: paused;
}

.woroku-breaking-item {
    padding-right: 50px;
    white-space: nowrap;
    font-weight: 500;
}

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ============================================
   HERO / HEADLINE SECTION
   ============================================ */

.woroku-hero {
    padding: 30px 0;
    background: var(--woroku-white);
}

.woroku-hero-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
}

.woroku-hero-main {
    position: relative;
    border-radius: var(--woroku-radius-lg);
    overflow: hidden;
    aspect-ratio: 16/9;
}

.woroku-hero-main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--woroku-transition);
}

.woroku-hero-main:hover img {
    transform: scale(1.05);
}

.woroku-hero-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    padding: 30px;
    color: var(--woroku-white);
}

.woroku-hero-category {
    display: inline-block;
    background: var(--woroku-primary);
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: var(--woroku-radius-sm);
    margin-bottom: 10px;
}

.woroku-hero-title {
    font-size: 28px;
    font-weight: 800;
    line-height: 1.3;
    color: var(--woroku-white);
    margin-bottom: 10px;
}

.woroku-hero-meta {
    display: flex;
    gap: 15px;
    font-size: 13px;
    opacity: 0.9;
}

.woroku-hero-sidebar {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.woroku-hero-small {
    position: relative;
    border-radius: var(--woroku-radius-md);
    overflow: hidden;
    aspect-ratio: 16/10;
}

.woroku-hero-small img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--woroku-transition);
}

.woroku-hero-small:hover img {
    transform: scale(1.05);
}

.woroku-hero-small .woroku-hero-overlay {
    padding: 20px;
}

.woroku-hero-small .woroku-hero-title {
    font-size: 16px;
    margin-bottom: 5px;
}

@media (max-width: 1024px) {
    .woroku-hero-grid {
        grid-template-columns: 1fr;
    }
    
    .woroku-hero-sidebar {
        grid-template-columns: repeat(2, 1fr);
        display: grid;
    }
}

@media (max-width: 768px) {
    .woroku-hero-sidebar {
        grid-template-columns: 1fr;
    }
    
    .woroku-hero-title {
        font-size: 22px;
    }
}

/* ============================================
   POST CARD (News Item)
   ============================================ */

.woroku-post-card {
    background: var(--woroku-white);
    border-radius: var(--woroku-radius-md);
    overflow: hidden;
    box-shadow: var(--woroku-shadow-sm);
    transition: var(--woroku-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.woroku-post-card:hover {
    box-shadow: var(--woroku-shadow-lg);
    transform: translateY(-4px);
}

.woroku-post-thumbnail {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.woroku-post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--woroku-transition);
}

.woroku-post-card:hover .woroku-post-thumbnail img {
    transform: scale(1.08);
}

.woroku-post-category {
    position: absolute;
    top: 12px;
    left: 12px;
    background: var(--woroku-primary);
    color: var(--woroku-white);
    padding: 5px 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: var(--woroku-radius-sm);
    letter-spacing: 0.5px;
}

.woroku-post-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.woroku-post-title {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
    margin-bottom: 10px;
    color: var(--woroku-dark);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.woroku-post-excerpt {
    font-size: 14px;
    line-height: 1.6;
    color: var(--woroku-gray-700);
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1;
}

.woroku-post-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--woroku-gray-600);
    padding-top: 15px;
    border-top: 1px solid var(--woroku-gray-200);
}

.woroku-post-date,
.woroku-post-views {
    display: flex;
    align-items: center;
    gap: 5px;
}

.woroku-post-date svg,
.woroku-post-views svg {
    width: 14px;
    height: 14px;
}

/* ============================================
   SECTION STYLES
   ============================================ */

.woroku-section {
    padding: var(--woroku-section-padding);
}

.woroku-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 3px solid var(--woroku-primary);
}

.woroku-section-title {
    font-size: 24px;
    font-weight: 800;
    color: var(--woroku-dark);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    padding-left: 20px;
}

.woroku-section-title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 5px;
    height: 24px;
    background: var(--woroku-primary);
    border-radius: 2px;
}

.woroku-section-link {
    font-size: 14px;
    font-weight: 600;
    color: var(--woroku-primary);
    display: flex;
    align-items: center;
    gap: 5px;
}

.woroku-section-link:hover {
    text-decoration: underline;
}

/* ============================================
   SIDEBAR
   ============================================ */

.woroku-sidebar {
    background: var(--woroku-white);
}

.woroku-widget {
    background: var(--woroku-white);
    border-radius: var(--woroku-radius-md);
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: var(--woroku-shadow-sm);
}

.woroku-widget-title {
    font-size: 18px;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 3px solid var(--woroku-primary);
    color: var(--woroku-dark);
}

.woroku-widget-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.woroku-widget-list li {
    padding: 12px 0;
    border-bottom: 1px solid var(--woroku-gray-200);
}

.woroku-widget-list li:last-child {
    border-bottom: none;
}

.woroku-widget-list a {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.woroku-widget-list a:hover .woroku-widget-list-title {
    color: var(--woroku-primary);
}

.woroku-widget-list-number {
    background: var(--woroku-primary);
    color: var(--woroku-white);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

.woroku-widget-list-title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    color: var(--woroku-dark);
    transition: var(--woroku-transition);
}

/* ============================================
   FOOTER
   ============================================ */

.woroku-footer {
    background: var(--woroku-dark);
    color: var(--woroku-gray-300);
    padding: 50px 0 20px;
    margin-top: 50px;
}

.woroku-footer-widgets {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

@media (max-width: 1024px) {
    .woroku-footer-widgets {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .woroku-footer-widgets {
        grid-template-columns: 1fr;
    }
}

.woroku-footer-widget h3 {
    color: var(--woroku-white);
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--woroku-primary);
}

.woroku-footer-widget ul {
    list-style: none;
}

.woroku-footer-widget ul li {
    margin-bottom: 10px;
}

.woroku-footer-widget ul li a {
    color: var(--woroku-gray-300);
    transition: var(--woroku-transition);
}

.woroku-footer-widget ul li a:hover {
    color: var(--woroku-primary);
    padding-left: 5px;
}

.woroku-footer-bottom {
    border-top: 1px solid var(--woroku-gray-800);
    padding-top: 30px;
    text-align: center;
}

.woroku-footer-copyright {
    font-size: 14px;
    color: var(--woroku-gray-500);
}

.woroku-footer-copyright a {
    color: var(--woroku-primary);
    font-weight: 600;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }

.mb-20 { margin-bottom: 20px; }
.mb-30 { margin-bottom: 30px; }
.mb-40 { margin-bottom: 40px; }

.mt-20 { margin-top: 20px; }
.mt-30 { margin-top: 30px; }
.mt-40 { margin-top: 40px; }

.hidden { display: none; }
.visible { display: block; }

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    :root {
        --woroku-gutter: 15px;
    }
    
    h1 { font-size: 24px; }
    h2 { font-size: 22px; }
    h3 { font-size: 20px; }
    
    .woroku-header-main {
        padding: 15px 0;
    }
    
    .woroku-logo {
        font-size: 24px;
    }
    
    .woroku-nav-menu a {
        padding: 12px 15px;
        font-size: 13px;
    }
    
    .woroku-section {
        padding: 20px 0;
    }
    
    .woroku-section-title {
        font-size: 20px;
    }
}

/* ============================================
   LOADING & ANIMATIONS
   ============================================ */

.woroku-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid var(--woroku-gray-300);
    border-top-color: var(--woroku-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

.slide-up {
    animation: slideUp 0.5s ease-out;
}

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