:root {
    /* Oletukset, jotka periytyvät teemasta jos mahdollista (Block-teemat, Astra, Elementor, jne.) */
    --vm-accent: var(--wp--preset--color--accent, 
                 var(--ast-global-color-0, 
                 var(--e-global-color-accent, 
                 var(--wp--preset--color--primary, 
                 var(--wp--preset--color--link, 
                 #2323b1)))));
    --vm-bg-soft: rgba(128, 128, 128, 0.1);
    --vm-border: rgba(128, 128, 128, 0.2);
    --vm-radius: 12px;
}

.vm-container {
    font-family: inherit; /* Käytä teeman omaa fonttia */
    color: inherit;
    background-color: transparent;
    padding: 1.5rem;
    border-radius: var(--vm-radius);
    max-width: 600px;
    margin: 1rem auto;
    border: 1px solid var(--vm-border);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    line-height: 1.5;
}

.vm-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: inherit;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-left: 4px solid var(--vm-accent);
    padding-left: 1rem;
    opacity: 0.9;
}

/* Opening Hours Styles */
.vm-hours-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.vm-hour-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--vm-border);
}

.vm-hour-item:last-child {
    border-bottom: none;
}

.vm-hour-label {
    font-weight: 600;
}

.vm-hour-value {
    opacity: 0.8;
}

.vm-hour-highlight .vm-hour-value {
    color: #ff4d4d; /* Säilytetään punainen huomioarvo */
    font-weight: 700;
}

/* Price List Styles */
.vm-price-section {
    margin-bottom: 2rem;
}

.vm-section-title {
    font-size: 1rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
    opacity: 0.8;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.vm-price-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--vm-bg-soft);
    padding: 0.75rem 1rem;
    margin-bottom: 0.5rem;
    border-radius: 8px;
    transition: transform 0.2s ease, background 0.2s ease;
}

.vm-price-item:hover {
    transform: translateX(4px);
    background: rgba(128, 128, 128, 0.15);
}

.vm-price-name {
    font-weight: 500;
}

.vm-price-tag {
    font-weight: 700;
    color: var(--vm-accent);
}

.vm-price-unit {
    font-size: 0.8rem;
    opacity: 0.6;
    margin-left: 2px;
}

/* Tournament List Styles */
.vm-tournament-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.vm-tournament-card {
    background: var(--vm-bg-soft);
    border: 1px solid var(--vm-border);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
}

.vm-tournament-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
    border-color: var(--vm-accent);
}

.vm-tournament-image-wrapper {
    width: 100%;
    height: 150px;
    overflow: hidden;
    border-bottom: 1px solid var(--vm-border);
}

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

.vm-tournament-card:hover .vm-tournament-image {
    transform: scale(1.05);
}

.vm-tournament-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.vm-tournament-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
}

.vm-tournament-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin: 0;
    color: inherit;
    line-height: 1.3;
}

.vm-tournament-badge {
    background-color: var(--vm-bg-soft);
    border: 1px solid var(--vm-accent);
    color: var(--vm-accent);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: 20px;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vm-tournament-desc {
    font-size: 0.9rem;
    opacity: 0.8;
    margin: 0;
    line-height: 1.4;
}

.vm-tournament-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.25rem;
    gap: 1rem;
    flex-wrap: wrap;
}

.vm-tournament-date {
    display: flex;
    align-items: center;
    font-size: 0.85rem;
    opacity: 0.75;
    font-weight: 500;
}

.vm-calendar-icon, .vm-doc-icon {
    font-size: 1rem;
    margin-right: 0.35rem;
}

.vm-tournament-doc-btn {
    display: inline-flex;
    align-items: center;
    background-color: var(--vm-accent);
    border: 1px solid var(--vm-accent);
    color: #fff !important;
    text-decoration: none !important;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.vm-tournament-doc-btn:hover {
    background-color: var(--ast-global-color-1, var(--wp--preset--color--secondary, #161671));
    border-color: var(--ast-global-color-1, var(--wp--preset--color--secondary, #161671));
    color: #fff !important;
}

/* News Feed Styles */
.vm-news-feed {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.vm-news-section-title {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    font-weight: 700;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vm-news-items-grid {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.vm-news-card {
    background: var(--vm-bg-soft);
    border: 1px solid var(--vm-border);
    border-radius: var(--vm-radius);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    display: flex;
    flex-direction: column;
}

.vm-news-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
    border-color: var(--vm-accent);
}

/* Featured card special styling */
.vm-news-card.vm-featured {
    border-left: 4px solid var(--vm-accent);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.vm-news-image-wrapper {
    width: 100%;
    max-height: 220px;
    overflow: hidden;
    border-bottom: 1px solid var(--vm-border);
}

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

.vm-news-card:hover .vm-news-image {
    transform: scale(1.03);
}

.vm-news-card-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.vm-news-card-header {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.vm-news-badge {
    align-self: flex-start;
    background-color: var(--vm-accent);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vm-news-card-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
    color: inherit;
    line-height: 1.3;
}

.vm-news-date {
    display: flex;
    align-items: center;
    font-size: 0.8rem;
    opacity: 0.7;
    font-weight: 500;
    margin-top: 0.2rem;
}

.vm-news-summary {
    font-size: 0.95rem;
    opacity: 0.9;
    margin: 0;
    line-height: 1.5;
}

/* Expandable content area */
.vm-news-body-wrapper {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.vm-news-body {
    padding-top: 0.75rem;
    border-top: 1px solid var(--vm-border);
    font-size: 0.95rem;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.vm-news-body h1, .vm-news-body h2, .vm-news-body h3, .vm-news-body h4 {
    margin: 0.5rem 0 0.25rem 0;
    font-weight: 700;
}

.vm-news-body h1 { font-size: 1.3rem; }
.vm-news-body h2 { font-size: 1.2rem; }
.vm-news-body h3 { font-size: 1.1rem; }

.vm-news-body p {
    margin: 0 0 0.5rem 0;
}

.vm-news-body figure.image {
    margin: 0.5rem 0;
    border-radius: 6px;
    overflow: hidden;
    max-width: 100%;
}

.vm-news-body img {
    max-width: 100%;
    height: auto;
    display: block;
}

.vm-news-footer {
    display: flex;
    justify-content: flex-end;
    margin-top: 0.5rem;
}

.vm-news-toggle-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background-color: transparent;
    border: 1px solid var(--vm-border);
    color: inherit;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.vm-news-toggle-btn:hover {
    background-color: var(--vm-bg-soft);
    border-color: var(--vm-accent);
}

.vm-news-arrow {
    font-size: 0.65rem;
    transition: transform 0.3s ease;
    display: inline-block;
}

/* When expanded */
.vm-news-card.vm-expanded {
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

/* Responsive */
@media (max-width: 480px) {
    .vm-container {
        padding: 1rem;
    }
    .vm-price-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
    .vm-tournament-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    .vm-tournament-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        width: 100%;
    }
    .vm-tournament-doc-btn {
        width: 100%;
        justify-content: center;
    }
    .vm-news-card-content {
        padding: 1rem;
    }
    .vm-news-image-wrapper {
        max-height: 160px;
    }
}
