/**
 * Verkehrsverein Speyer CMS v1.0.0
 * Frontend Styles
 */

/* Header */
.site-header {
    background: white;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow-small);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 40px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.site-branding {
    flex-shrink: 0;
}

.site-logo {
    text-decoration: none;
    color: var(--text-color);
}

.site-name {
    font-size: 24px;
    font-weight: 600;
}

.site-tagline {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* Navigation */
.main-navigation {
    flex: 1;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    font-size: 14px;
}

.menu-list {
    /*display: flex;*/
    list-style: none;
    gap: 8px;
}

.menu-list li a {
    display: block;
    padding: 8px 16px;
    text-decoration: none;
    color: var(--text-color);
    border-radius: var(--border-radius-small);
    transition: background var(--transition-fast);
    font-size: 15px;
}

.menu-list li a:hover,
.menu-list li a.active {
    background: var(--surface-color);
}

/* Search */
.header-search {
    flex-shrink: 0;
}

.search-form input {
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-small);
    width: 200px;
    font-size: 14px;
}

.search-form button {
    margin-left: 8px;
    padding: 8px 16px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius-small);
    cursor: pointer;
}

/* Content */
.content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px;
}

.hero-section {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, var(--surface-color) 0%, white 100%);
    border-radius: var(--border-radius-large);
    margin-bottom: 40px;
}

.hero-section h1 {
    font-size: 48px;
    font-weight: 600;
    margin-bottom: 16px;
}

.hero-section .tagline {
    font-size: 20px;
    color: var(--text-secondary);
}

/* Articles Grid */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.article-card {
    background: white;
    border-radius: var(--border-radius-medium);
    padding: 30px;
    box-shadow: var(--shadow-small);
    transition: transform var(--transition-fast);
}

.article-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
}

.article-card h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 12px;
}

.article-card h2 a {
    color: var(--text-color);
    text-decoration: none;
}

.article-meta {
    display: flex;
    gap: 12px;
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.article-excerpt {
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.6;
}

.read-more {
    display: inline-block;
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
}

 /*Page 
.page-content {
    display: grid;
    gap: 40px;
}
*/
.single-page {
    background: white;
    border-radius: var(--border-radius-large);
    padding: 40px;
    box-shadow: var(--shadow-small);
}

.page-header h1 {
    font-size: 40px;
    font-weight: 600;
    margin-bottom: 16px;
}

.page-meta {
    display: flex;
    gap: 16px;
    font-size: 14px;
    color: var(--text-secondary);
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 30px;
}

.page-body {
    font-size: 17px;
    line-height: 1.8;
    color: var(--text-color);
}

.page-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--border-radius-medium);
    margin: 20px 0;
}

.page-actions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

/* Sidebar */
.page-sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.sidebar-widget {
    background: white;
    border-radius: var(--border-radius-medium);
    padding: 24px;
    box-shadow: var(--shadow-small);
}

.sidebar-widget h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
}

.related-pages {
    list-style: none;
}

.related-pages li {
    margin-bottom: 12px;
}

.related-pages a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 15px;
}

/* Footer */
.site-footer {
    background: var(--text-color);
    color: white;
    padding: 60px 0 20px;
    margin-top: 80px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-info h3 {
    font-size: 20px;
    margin-bottom: 12px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 8px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 14px;
}

.footer-links a:hover {
    color: white;
}

.footer-admin {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 13px;
}

.footer-admin a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 40px;
}

.pagination-link,
.pagination-current {
    padding: 10px 16px;
    border-radius: var(--border-radius-small);
    text-decoration: none;
    font-size: 14px;
}

.pagination-link {
    background: white;
    color: var(--text-color);
    border: 1px solid var(--border-color);
}

.pagination-link:hover {
    background: var(--surface-color);
}

.pagination-current {
    background: var(--primary-color);
    color: white;
}

/* Search Results */
.search-header {
    text-align: center;
    margin-bottom: 40px;
}

.search-form-page {
    max-width: 600px;
    margin: 20px auto 0;
    display: flex;
    gap: 12px;
}

.search-form-page input {
    flex: 1;
    padding: 12px 20px;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius-small);
    font-size: 16px;
}

.search-form-page button {
    padding: 12px 24px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius-small);
    cursor: pointer;
}

.search-result-item {
    background: white;
    border-radius: var(--border-radius-medium);
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-small);
}

.search-result-item h2 {
    font-size: 24px;
    margin-bottom: 12px;
}

.search-result-item h2 a {
    color: var(--text-color);
    text-decoration: none;
}

.search-result-item mark {
    background: #FFEB3B;
    padding: 2px 4px;
}

/* Responsive */
@media (max-width: 768px) {
    .header-container {
        flex-wrap: wrap;
        padding: 20px;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .menu-list {
        display: none;
        flex-direction: column;
        width: 100%;
    }
    
    .content-wrapper {
        padding: 20px;
    }
    
    .hero-section h1 {
        font-size: 32px;
    }
    
    .articles-grid {
        grid-template-columns: 1fr;
    }
    
    .page-content {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
    }
}

/* Featured Grid - 4 Beiträge auf Startseite */
.featured-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin: 40px 0;
}

.featured-card {
    background: white;
    border-radius: var(--border-radius-large);
    overflow: hidden;
    box-shadow: var(--shadow-medium);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    display: flex;
    flex-direction: column;
}

.featured-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-large);
}

.featured-image {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: var(--surface-color);
    position: relative;
}

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

.featured-card:hover .featured-image img {
    transform: scale(1.05);
}

.featured-content {
    padding: 30px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.featured-category {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-color);
    color: white;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    align-self: flex-start;
}

.featured-content h2 {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 16px;
    line-height: 1.4;
}

.featured-content h2 a {
    color: var(--text-color);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.featured-content h2 a:hover {
    color: var(--primary-color);
}

.featured-excerpt {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
    flex: 1;
}

.featured-content .button {
    align-self: flex-start;
}

/* Recent Section */
.recent-section {
    margin-top: 60px;
    padding-top: 60px;
    border-top: 1px solid var(--border-color);
}

.section-title {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 30px;
    text-align: center;
}

.recent-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.recent-card {
    background: white;
    border-radius: var(--border-radius-medium);
    padding: 24px;
    box-shadow: var(--shadow-small);
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.recent-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.recent-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 12px;
}

.recent-card h3 a {
    color: var(--text-color);
    text-decoration: none;
}

.recent-card h3 a:hover {
    color: var(--primary-color);
}

.category-badge {
    display: inline-block;
    padding: 3px 10px;
    background: var(--surface-color);
    color: var(--text-secondary);
    border-radius: 8px;
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.recent-excerpt {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 16px;
}

.read-more-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: gap var(--transition-fast);
}

.read-more-link:hover {
    gap: 8px;
}

/* Responsive Anpassungen */
@media (max-width: 1024px) {
    .featured-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .featured-image {
        height: 300px;
    }
    
    .recent-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .featured-image {
        height: 220px;
    }
    
    .featured-content {
        padding: 20px;
    }
    
    .recent-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-section {
        padding: 40px 20px;
    }
    
    .hero-section h1 {
        font-size: 32px;
    }
}

/* TinyMCE Custom Styles */
.info-box {
    background: #E5F1FF;
    border-left: 4px solid #0066CC;
    padding: 20px;
    margin: 20px 0;
    border-radius: 8px;
}

.note-box {
    background: #FFF4E5;
    border-left: 4px solid #FF9500;
    padding: 20px;
    margin: 20px 0;
    border-radius: 8px;
}

.caption {
    display: block;
    font-size: 13px;
    color: #86868B;
    margin-top: 8px;
    font-style: italic;
}

blockquote {
    border-left: 4px solid #D2D2D7;
    padding-left: 20px;
    margin: 20px 0;
    font-style: italic;
    color: #666666;
}

/* Custom Image Styles - v1.0.3 */
figure {
    margin: 20px 0;
}

figure img {
    display: block;
}

figcaption {
    display: block;
    font-size: 13px;
    color: #86868B;
    margin-top: 8px;
    font-style: italic;
    line-height: 1.4;
}

/* Float Clear */
.clear, [style*="clear: both"] {
    clear: both;
}

/* Responsive Images */
img {
    max-width: 100%;
    height: auto;
}

/* Image Margins */
img[style*="float: left"] {
    margin-right: 20px;
}

img[style*="float: right"] {
    margin-left: 20px;
}

/* Header & Navigation v1.0.3.2 */

/* Header Container */
.site-header {
    background: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Branding */
.site-branding {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.site-logo {
    text-decoration: none;
    display: block;
}

.site-logo img {
    width: auto;
    display: block;
}

.site-name {
    font-size: 24px;
    font-weight: 700;
    color: var(--heading-color);
    text-decoration: none;
}

.site-tagline {
    font-size: 1.2em;
    color: var(--text-secondary);
    margin: 0;
}

/* Navigation direkt unter Header */
.main-navigation {
    background: var(--primary-color);
    border-bottom: 3px solid var(--accent-color);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
    position: relative;
}

.menu-list {
    list-style: none;
    margin: 0;
    padding: 0;
    /*display: flex;*/
    gap: 0;
}

.menu-list li {
    margin: 0;
}

.menu-list a {
    display: block;
    padding: 16px 24px;
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.menu-list a:hover,
.menu-list a.active {
    background: rgba(255,255,255,0.15);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    padding: 16px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
}

/* Header Search */
.header-search {
    display: flex;
    align-items: center;
}

.search-form {
    display: flex;
    gap: 8px;
}

.search-form input[type="search"] {
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    min-width: 200px;
}

.search-form button {
    padding: 8px 20px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.search-form button:hover {
    background: var(--link-hover-color);
}

/* Content Wrapper */
.site-main {
    min-height: calc(100vh - 200px);
}

.content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 30px;
}

/* Responsive */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
    
    .header-search {
        width: 100%;
    }
    
    .search-form {
        width: 100%;
    }
    
    .search-form input[type="search"] {
        flex: 1;
        min-width: auto;
    }
    
    .menu-toggle {
        display: block;
        width: 100%;
        text-align: left;
    }
    
    .menu-list {
        display: none;
        flex-direction: column;
        width: 100%;
    }
    
    .menu-list.active {
        display: flex;
    }
    
    .menu-list a {
        border-top: 1px solid rgba(255,255,255,0.1);
    }
}

/* Mobile Menu Script */

/* Footer v1.0.3.2 */
.site-footer {
    background: var(--heading-color, #1D1D1F);
    color: white;
    margin-top: 80px;
    padding: 60px 0 20px;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h3 {
    color: white;
    font-size: 18px;
    margin-bottom: 16px;
}

.footer-section p {
    color: rgba(255,255,255,0.8);
    line-height: 1.6;
    margin-bottom: 8px;
}

.footer-section a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
}

.footer-section a:hover {
    color: white;
    text-decoration: underline;
}

.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-menu li {
    margin-bottom: 8px;
}

.footer-menu a {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: color 0.2s ease;
}

.footer-menu a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    text-align: center;
}

.footer-bottom p {
    color: rgba(255,255,255,0.6);
    font-size: 14px;
    margin: 8px 0;
}

.powered-by {
    font-size: 12px !important;
}

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

/* Dropdown-Menüs v1.0.3.3 */

/* Submenu Container */
.menu-item-with-submenu {
    position: relative;
}

.submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 220px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-radius: 0 0 8px 8px;
    padding: 8px 0;
    z-index: 1000;
    list-style: none;
    margin: 0;
}

.menu-item-with-submenu:hover .submenu {
    display: block;
}

.submenu li {
    margin: 0;
}

.submenu a {
    display: block;
    padding: 12px 20px;
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.submenu a:hover,
.submenu a.active {
    background: var(--surface-color);
    color: var(--primary-color);
}

/* Mobile Submenu */
@media (max-width: 768px) {
    .submenu {
        position: static;
        display: none;
        box-shadow: none;
        background: rgba(255,255,255,0.05);
        margin-top: 0;
    }
    
    .menu-item-with-submenu.submenu-open .submenu {
        display: block;
    }
    
    .menu-item-with-submenu > a::after {
        content: ' ▼';
        font-size: 10px;
        margin-left: 6px;
    }
    
    .menu-item-with-submenu.submenu-open > a::after {
        content: ' ▲';
    }
    
    .submenu a {
        padding-left: 40px;
        font-size: 14px;
    }
}
