/*
Theme Name: GötaBladet
Theme URI: https://gotabladet.se
Author: GötaBladet Team
Author URI: https://gotabladet.se
Description: Ett modernt nyhetstema inspirerat av svenska tidningar som GP och Sydsvenskan
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: gotabladet
*/

/* CSS Variables */
:root {
    --primary-color: #1a1a1a;
    --secondary-color: #FFD700;
    --accent-color: #0066cc;
    --text-color: #333;
    --light-gray: #f5f5f5;
    --border-color: #e0e0e0;
    --font-primary: 'Georgia', 'Times New Roman', serif;
    --font-serif: 'Playfair Display', 'Georgia', serif;
    --font-logo: 'Playfair Display', 'Georgia', serif;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    color: var(--text-color);
    line-height: 1.6;
    background-color: #fff;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-serif);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

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

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

/* Header */
.site-header {
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.site-branding {
    text-align: center;
    padding: 2rem 0 1rem 0;
    border-bottom: 4px solid var(--secondary-color);
}

.site-title {
    font-size: 4.5rem;
    font-family: var(--font-logo);
    font-weight: 900;
    color: var(--primary-color);
    margin: 0 0 0.5rem 0;
    letter-spacing: -2px;
    text-transform: uppercase;
}

.site-title a {
    color: var(--primary-color);
}

.site-description {
    font-size: 0.75rem;
    color: #666;
    font-style: normal;
    font-weight: 400;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-family: var(--font-primary);
}

/* Navigation */
.main-navigation {
    background: #fff;
    border-bottom: 1px solid var(--border-color);
    margin-top: 0;
}

.main-navigation ul {
    list-style: none;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.main-navigation li {
    margin: 0;
}

.main-navigation a {
    display: block;
    padding: 1rem 1.5rem;
    color: var(--primary-color);
    font-weight: 600;
    text-transform: none;
    font-size: 0.95rem;
    letter-spacing: 0;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}

.main-navigation a:hover {
    background: transparent;
    color: var(--secondary-color);
    border-bottom-color: var(--secondary-color);
}

/* Main Content */
.site-content {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

/* Article Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.article-card {
    background: #fff;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.article-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.article-content {
    padding: 1.5rem;
}

.article-category {
    display: inline-block;
    background: var(--secondary-color);
    color: #fff;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.article-title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.article-title a {
    color: var(--primary-color);
}

.article-excerpt {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #999;
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

/* Homepage Layout */
.homepage-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 3rem;
    max-width: 1400px;
    margin: 0 auto;
}

.main-feed {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Large Feed Article */
.feed-large {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 2rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.feed-large-image-link {
    display: block;
    overflow: hidden;
}

.feed-large-image {
    width: 100%;
    height: 400px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.feed-large-image-link:hover .feed-large-image {
    transform: scale(1.05);
}

.feed-large-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.feed-large-title {
    font-size: 2.25rem;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.feed-large-title a {
    color: var(--primary-color);
}

.feed-large-excerpt {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 1rem;
}

.feed-time {
    font-size: 0.9rem;
    color: #999;
}

/* Small Feed Articles Row */
.feed-small-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid var(--border-color);
}

.feed-small {
    background: #fff;
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feed-small:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.feed-small-link {
    display: block;
    color: var(--text-color);
}

.feed-small-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.feed-small-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.feed-small:hover .feed-small-image img {
    transform: scale(1.05);
}

.feed-small-content {
    padding: 1.25rem;
}

.feed-small-category {
    display: inline-block;
    background: var(--secondary-color);
    color: #fff;
    padding: 0.2rem 0.6rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}

.feed-small-title {
    font-size: 1.1rem;
    line-height: 1.3;
    margin-bottom: 0.75rem;
    font-weight: 700;
    color: var(--primary-color);
}

.feed-small-time {
    font-size: 0.85rem;
    color: #999;
}

/* Homepage Sidebar */
.homepage-sidebar {
    align-self: start;
}

.sidebar-box {
    background: var(--light-gray);
    padding: 1.5rem;
    margin-bottom: 2rem;
    border-left: 4px solid var(--secondary-color);
}

.sidebar-box-title {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Sidebar Article List */
.sidebar-article-list {
    list-style: none;
}

.sidebar-article-item {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-article-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-article-link {
    display: flex;
    gap: 1rem;
    color: var(--text-color);
    transition: opacity 0.3s ease;
}

.sidebar-article-link:hover {
    opacity: 0.7;
}

.sidebar-article-thumb {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    overflow: hidden;
}

.sidebar-article-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-article-text {
    flex: 1;
}

.sidebar-article-cat {
    display: inline-block;
    background: var(--secondary-color);
    color: #fff;
    padding: 0.15rem 0.5rem;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.sidebar-article-title {
    font-size: 0.95rem;
    line-height: 1.3;
    margin-bottom: 0.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.sidebar-article-time {
    font-size: 0.75rem;
    color: #999;
}

/* Sidebar Numbered List (Most Read) */
.sidebar-numbered-list {
    list-style: none;
    counter-reset: item-counter;
}

.sidebar-numbered-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.25rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-numbered-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    background: var(--secondary-color);
    color: #fff;
    font-size: 1.25rem;
    font-weight: 700;
    flex-shrink: 0;
}

.sidebar-numbered-link {
    flex: 1;
    color: var(--text-color);
    transition: opacity 0.3s ease;
}

.sidebar-numbered-link:hover {
    opacity: 0.7;
}

.sidebar-numbered-title {
    font-size: 0.95rem;
    line-height: 1.3;
    font-weight: 700;
    color: var(--primary-color);
}


/* Single Article */
.article-layout {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto;
}

.single-article {
    max-width: 100%;
}

.single-article .article-header {
    margin-bottom: 2rem;
}

.single-article .article-image {
    width: 100%;
    height: auto;
    margin-bottom: 2rem;
}

.single-article .article-content {
    font-size: 1.1rem;
    line-height: 1.8;
}

.single-article .article-content p {
    margin-bottom: 1.5rem;
}

/* Sidebar */
.article-sidebar {
    align-self: start;
}

.sidebar-section {
    background: var(--light-gray);
    padding: 1.5rem;
    margin-bottom: 2rem;
    border-left: 4px solid var(--secondary-color);
}

.sidebar-title {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sidebar-list {
    list-style: none;
}

.sidebar-item {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.sidebar-link {
    display: flex;
    gap: 1rem;
    color: var(--text-color);
    transition: opacity 0.3s ease;
}

.sidebar-link:hover {
    opacity: 0.7;
}

.sidebar-thumbnail {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    overflow: hidden;
}

.sidebar-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-item-content {
    flex: 1;
}

.sidebar-category {
    display: inline-block;
    background: var(--secondary-color);
    color: #fff;
    padding: 0.15rem 0.5rem;
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.sidebar-item-title {
    font-size: 0.95rem;
    line-height: 1.3;
    margin-bottom: 0.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.sidebar-date {
    font-size: 0.75rem;
    color: #999;
}


/* Footer */
.site-footer {
    background: var(--primary-color);
    color: #fff;
    padding: 2rem 0;
    margin-top: 4rem;
    text-align: center;
}

.site-footer a {
    color: #fff;
}

/* Responsive */
@media (max-width: 768px) {
    .site-title {
        font-size: 2rem;
    }

    .hero-article {
        grid-template-columns: 1fr;
    }

    .hero-image {
        height: 250px;
    }

    .hero-content .article-title {
        font-size: 1.75rem;
    }

    .articles-grid {
        grid-template-columns: 1fr;
    }

    .main-navigation ul {
        flex-direction: column;
    }

    .main-navigation a {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    /* Article layout responsive */
    .article-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .article-sidebar {
        position: static;
    }

    .sidebar-section {
        padding: 1rem;
    }

    /* Homepage responsive */
    .homepage-layout {
        grid-template-columns: 1fr;
    }

    .homepage-sidebar {
        position: static;
    }

    .feed-large {
        grid-template-columns: 1fr;
    }

    .feed-large-image {
        height: 300px;
    }

    .feed-large-title {
        font-size: 1.75rem;
    }

    .feed-small-row {
        grid-template-columns: 1fr;
    }

    /* Homepage responsive */
    .hero-article {
        grid-template-columns: 1fr;
    }

    .hero-image {
        height: 300px;
    }

    .hero-content .article-title {
        font-size: 1.75rem;
    }

    .featured-grid {
        grid-template-columns: 1fr;
    }

    .latest-grid {
        grid-template-columns: 1fr;
    }

    .latest-image {
        width: 100px;
        height: 100px;
    }
}

/* Related Articles */
.related-articles {
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 3px solid var(--border-color);
}

.related-title {
    font-size: 1.75rem;
    margin-bottom: 2rem;
    color: var(--primary-color);
    font-weight: 700;
}

.related-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.related-article {
    background: #fff;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.related-article:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.related-link {
    display: block;
    color: var(--text-color);
}

.related-link:hover {
    color: var(--text-color);
}

.related-image {
    width: 100%;
    height: 180px;
    overflow: hidden;
}

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

.related-article:hover .related-image img {
    transform: scale(1.05);
}

.related-content {
    padding: 1.25rem;
}

.related-category {
    display: inline-block;
    background: var(--secondary-color);
    color: #fff;
    padding: 0.2rem 0.6rem;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 0.75rem;
}

.related-article-title {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    line-height: 1.3;
    color: var(--primary-color);
    font-weight: 700;
}

.related-date {
    font-size: 0.8rem;
    color: #999;
    display: block;
}

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

    .related-articles {
        margin-top: 3rem;
        padding-top: 2rem;
    }
}