/**
 * Finnish Listed Companies - Salient Theme
 * All styles scoped to .tm-layout - won't affect ticker tape
 */

/* ============================================
   Variables
   ============================================ */
:root {
    --tm-primary: #1a365d;
    --tm-primary-light: #2c5282;
    --tm-accent: #3182ce;
    --tm-success: #38a169;
    --tm-gray-50: #f7fafc;
    --tm-gray-100: #edf2f7;
    --tm-gray-200: #e2e8f0;
    --tm-gray-300: #cbd5e0;
    --tm-gray-400: #a0aec0;
    --tm-gray-500: #718096;
    --tm-gray-600: #4a5568;
    --tm-gray-700: #2d3748;
    --tm-gray-800: #1a202c;
    --tm-radius: 8px;
    --tm-shadow: 0 1px 3px rgba(0,0,0,0.08);
    --tm-shadow-md: 0 4px 6px rgba(0,0,0,0.1);
}

/* ============================================
   Main Layout - background via pseudo element
   ============================================ */
.tm-layout {
    display: flex;
    gap: 30px;
    width: 100%;
    padding: 30px 0;
    position: relative;
}

/* Full-width gray background without affecting other elements */
.tm-layout::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100vw;
    background: var(--tm-gray-50);
    z-index: -1;
}

/* ============================================
   Sidebar
   ============================================ */
.tm-layout .tm-sidebar {
    width: 250px;
    flex-shrink: 0;
    align-self: flex-start;
    position: sticky;
    top: 120px;
    background: white;
    border-radius: var(--tm-radius);
    padding: 20px;
    box-shadow: var(--tm-shadow);
}

.tm-layout .tm-sidebar-header {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--tm-gray-100);
}

.tm-layout .tm-sidebar-header h1 {
    font-size: 1.375rem;
    font-weight: 700;
    color: var(--tm-gray-800);
    margin: 0 0 4px 0;
    line-height: 1.2;
}

.tm-layout .tm-sidebar-header p {
    font-size: 0.8125rem;
    color: var(--tm-gray-500);
    margin: 0;
}

/* ============================================
   Filter Form
   ============================================ */
.tm-layout .tm-filter-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.tm-layout .tm-filter-group > label:first-child {
    display: block;
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--tm-gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.tm-layout .tm-filter-group input[type="text"],
.tm-layout .tm-filter-group select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--tm-gray-200);
    border-radius: 4px;
    font-size: 0.875rem;
    color: var(--tm-gray-800);
    background: white;
}

.tm-layout .tm-filter-group input:focus,
.tm-layout .tm-filter-group select:focus {
    outline: none;
    border-color: var(--tm-accent);
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.15);
}

/* Radio Group */
.tm-layout .tm-radio-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.tm-layout .tm-radio {
    display: flex;
    align-items: center;
    padding: 8px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8125rem;
    color: var(--tm-gray-700);
    transition: 0.15s;
}

.tm-layout .tm-radio:hover {
    background: var(--tm-gray-50);
}

.tm-layout .tm-radio.active {
    background: var(--tm-primary);
    color: white;
}

.tm-layout .tm-radio.active span {
    color: white;
}

.tm-layout .tm-radio.active .tm-count {
    color: white;
    opacity: 0.8;
}

.tm-layout .tm-radio input {
    display: none;
}

.tm-layout .tm-radio .tm-count {
    margin-left: auto;
    font-size: 0.6875rem;
    opacity: 0.7;
}

/* Buttons */
.tm-layout .tm-filter-buttons {
    display: flex;
    gap: 8px;
}

.tm-layout .tm-btn-primary,
.tm-layout .tm-btn-secondary {
    flex: 1;
    padding: 8px 14px;
    border-radius: 4px;
    font-size: 0.8125rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    border: none;
    transition: 0.15s;
}

.tm-layout .tm-btn-primary {
    background: var(--tm-primary);
    color: white;
}

.tm-layout .tm-btn-primary:hover {
    background: var(--tm-primary-light);
    color: white;
}

.tm-layout .tm-btn-secondary {
    background: var(--tm-gray-100);
    color: var(--tm-gray-600);
}

.tm-layout .tm-btn-secondary:hover {
    background: var(--tm-gray-200);
    color: var(--tm-gray-700);
}

/* ============================================
   Main Content
   ============================================ */
.tm-layout .tm-main {
    flex: 1;
    min-width: 0;
}

/* Results Bar */
.tm-layout .tm-results-bar {
    margin-bottom: 15px;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--tm-gray-600);
}

/* ============================================
   Company Grid
   ============================================ */
.tm-layout .tm-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.tm-layout .tm-card {
    display: flex;
    flex-direction: column;
    background: white;
    border-radius: var(--tm-radius);
    padding: 18px;
    text-decoration: none;
    border: 1px solid var(--tm-gray-100);
    transition: 0.15s;
}

.tm-layout .tm-card:hover {
    border-color: var(--tm-accent);
    box-shadow: var(--tm-shadow-md);
    transform: translateY(-2px);
}

.tm-layout .tm-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.tm-layout .tm-ticker {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--tm-primary);
}

/* Market Logos */
.tm-layout .tm-market-logo {
    font-size: 0.625rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    padding: 3px 8px;
    border-radius: 3px;
}

.tm-layout .tm-market-logo.tm-market-main {
    background: linear-gradient(135deg, #0066cc 0%, #004999 100%);
    color: white;
}

.tm-layout .tm-market-logo.tm-market-firstnorth {
    background: linear-gradient(135deg, #00a651 0%, #008040 100%);
    color: white;
}

/* Legacy badge style (keep for compatibility) */
.tm-layout .tm-market {
    font-size: 0.5625rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 3px;
    text-transform: uppercase;
}

.tm-layout .tm-market-main {
    background: var(--tm-primary);
    color: white;
}

.tm-layout .tm-market-firstnorth {
    background: var(--tm-success);
    color: white;
}

.tm-layout .tm-card-name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--tm-gray-800);
    line-height: 1.3;
    margin-bottom: 4px;
}

.tm-layout .tm-card-sector {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.75rem;
    color: var(--tm-gray-500);
    margin-bottom: 10px;
}

.tm-layout .tm-sector-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.tm-layout .tm-sector-icon svg {
    width: 14px;
    height: 14px;
    opacity: 0.7;
}

.tm-layout .tm-card-excerpt {
    font-size: 0.875rem;
    color: var(--tm-gray-600);
    line-height: 1.5;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid var(--tm-gray-100);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ============================================
   Pagination
   ============================================ */
.tm-layout .tm-pagination {
    margin-top: 24px;
    text-align: center;
}

.tm-layout .tm-pagination .page-numbers {
    display: inline-block;
    padding: 6px 10px;
    margin: 0 2px;
    border-radius: 4px;
    text-decoration: none;
    color: var(--tm-gray-600);
    background: white;
    border: 1px solid var(--tm-gray-200);
    font-size: 0.8125rem;
}

.tm-layout .tm-pagination .page-numbers:hover {
    border-color: var(--tm-gray-300);
}

.tm-layout .tm-pagination .page-numbers.current {
    background: var(--tm-primary);
    color: white;
    border-color: var(--tm-primary);
}

/* No Results */
.tm-layout .tm-no-results {
    text-align: center;
    padding: 40px;
    background: white;
    border-radius: var(--tm-radius);
    color: var(--tm-gray-600);
}

/* ============================================
   Single Company Sidebar
   ============================================ */
.tm-layout .tm-back {
    display: inline-block;
    font-size: 0.8125rem;
    color: var(--tm-accent);
    text-decoration: none;
    margin-bottom: 15px;
}

.tm-layout .tm-back:hover {
    color: var(--tm-primary);
}

.tm-layout .tm-company-info {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--tm-gray-100);
}

.tm-layout .tm-company-info h1 {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--tm-gray-800);
    margin: 0 0 10px 0;
    line-height: 1.3;
}

.tm-layout .tm-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

.tm-layout .tm-badge-ticker,
.tm-layout .tm-badge-market {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.6875rem;
    font-weight: 600;
}

.tm-layout .tm-badge-ticker {
    background: var(--tm-primary);
    color: white;
}

.tm-layout .tm-badge-market {
    background: var(--tm-gray-100);
    color: var(--tm-gray-700);
}

.tm-layout .tm-badge-market.tm-market-firstnorth {
    background: var(--tm-success);
    color: white;
}

.tm-layout .tm-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    border-bottom: 1px solid var(--tm-gray-50);
}

.tm-layout .tm-info-row:last-child {
    border-bottom: none;
}

.tm-layout .tm-label {
    font-size: 0.6875rem;
    color: var(--tm-gray-500);
}

.tm-layout .tm-value {
    font-size: 0.75rem;
    color: var(--tm-gray-800);
    font-weight: 500;
}

.tm-layout .tm-mono {
    font-family: 'SF Mono', Monaco, Consolas, monospace;
    font-size: 0.6875rem;
}

/* Navigation */
.tm-layout .tm-nav,
.tm-layout .tm-related {
    margin-bottom: 20px;
}

.tm-layout .tm-nav-title {
    display: block;
    font-size: 0.625rem;
    font-weight: 600;
    color: var(--tm-gray-400);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.tm-layout .tm-nav a {
    display: block;
    padding: 6px 10px;
    margin: 0 -10px;
    font-size: 0.8125rem;
    color: var(--tm-gray-600);
    text-decoration: none;
    border-radius: 4px;
}

.tm-layout .tm-nav a:hover {
    background: var(--tm-gray-50);
    color: var(--tm-gray-800);
}

.tm-layout .tm-nav a.tm-nav-tab.active {
    background: var(--tm-primary);
    color: white;
}

/* Placeholder */
.tm-layout .tm-placeholder {
    background: white;
    border-radius: var(--tm-radius);
    padding: 40px;
    text-align: center;
    color: var(--tm-gray-500);
    box-shadow: var(--tm-shadow);
}

/* ============================================
   News List
   ============================================ */
.tm-layout .tm-news-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.tm-layout .tm-news-item {
    background: white;
    padding: 16px 20px;
    border-bottom: 1px solid var(--tm-gray-100);
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.tm-layout .tm-news-item:first-child {
    border-radius: var(--tm-radius) var(--tm-radius) 0 0;
}

.tm-layout .tm-news-item:last-child {
    border-radius: 0 0 var(--tm-radius) var(--tm-radius);
    border-bottom: none;
}

.tm-layout .tm-news-item:only-child {
    border-radius: var(--tm-radius);
}

.tm-layout .tm-news-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 6px;
    overflow: hidden;
    background: var(--tm-gray-100);
}

.tm-layout .tm-news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tm-layout .tm-news-content {
    flex: 1;
    min-width: 0;
}

.tm-layout .tm-news-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.tm-layout .tm-news-favicon {
    width: 16px;
    height: 16px;
    border-radius: 2px;
    flex-shrink: 0;
}

.tm-layout .tm-news-source {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--tm-gray-600);
}

.tm-layout .tm-news-date {
    font-size: 0.75rem;
    color: var(--tm-gray-400);
}

.tm-layout .tm-news-date::before {
    content: '·';
    margin-right: 8px;
    color: var(--tm-gray-300);
}

.tm-layout .tm-news-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--tm-gray-800);
    margin: 0 0 6px 0;
    line-height: 1.4;
}

.tm-layout .tm-news-title a {
    color: var(--tm-gray-800);
    text-decoration: none;
    transition: 0.15s;
}

.tm-layout .tm-news-title a:hover {
    color: var(--tm-accent);
}

.tm-layout .tm-news-snippet {
    font-size: 0.9375rem;
    color: var(--tm-gray-600);
    margin: 0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

@media (max-width: 480px) {
    .tm-layout .tm-news-thumb {
        width: 60px;
        height: 60px;
    }
}

/* Related */
.tm-layout .tm-related {
    padding-top: 20px;
    border-top: 1px solid var(--tm-gray-100);
}

.tm-layout .tm-related-item {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    margin: 0 -10px;
    text-decoration: none;
    border-radius: 4px;
}

.tm-layout .tm-related-item:hover {
    background: var(--tm-gray-50);
}

.tm-layout .tm-rel-ticker {
    font-size: 0.625rem;
    font-weight: 700;
    color: var(--tm-accent);
}

.tm-layout .tm-rel-name {
    font-size: 0.75rem;
    color: var(--tm-gray-700);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ============================================
   Tabs
   ============================================ */
.tm-layout .tm-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--tm-gray-200);
}

.tm-layout .tm-tab {
    padding: 12px 24px;
    background: none;
    border: none;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--tm-gray-500);
    cursor: pointer;
    position: relative;
    transition: 0.15s;
}

.tm-layout .tm-tab:hover {
    color: var(--tm-gray-700);
}

.tm-layout .tm-tab.active {
    color: var(--tm-primary);
}

.tm-layout .tm-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--tm-primary);
}

.tm-layout .tm-tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    margin-left: 6px;
    background: var(--tm-gray-200);
    border-radius: 10px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--tm-gray-600);
}

.tm-layout .tm-tab.active .tm-tab-count {
    background: var(--tm-primary);
    color: white;
    opacity: 0.9;
}

.tm-layout .tm-tab-content {
    display: none;
}

.tm-layout .tm-tab-content.active {
    display: block;
}

/* Section Header */
.tm-layout .tm-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.tm-layout .tm-section-header h2 {
    margin: 0;
}

.tm-layout .tm-link-btn {
    background: none;
    border: none;
    color: var(--tm-accent);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: 0.15s;
}

.tm-layout .tm-link-btn:hover {
    background: var(--tm-gray-100);
}

/* ============================================
   Yhteenveto Layout (2/3 + 1/3)
   ============================================ */
.tm-layout .tm-yhteenveto-layout {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
    align-items: start;
}

.tm-layout .tm-yhteenveto-main {
    min-width: 0;
}

.tm-layout .tm-yhteenveto-main .tm-content-box {
    background: white;
    border-radius: var(--tm-radius);
    padding: 24px 28px;
    box-shadow: var(--tm-shadow);
    font-size: 1rem;
}

/* Table of Contents */
.tm-layout .tm-toc {
    background: var(--tm-gray-50);
    border: 1px solid var(--tm-gray-200);
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 24px;
}

.tm-layout .tm-toc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.tm-layout .tm-toc-title {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--tm-gray-600);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.tm-layout .tm-toc-toggle {
    width: 24px;
    height: 24px;
    border: none;
    background: var(--tm-gray-200);
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    color: var(--tm-gray-600);
    transition: 0.15s;
}

.tm-layout .tm-toc-toggle:hover {
    background: var(--tm-gray-300);
}

.tm-layout .tm-toc-list {
    margin: 0;
    padding: 0 0 0 20px;
    list-style: decimal;
}

.tm-layout .tm-toc-list li {
    margin-bottom: 8px;
    line-height: 1.4;
}

.tm-layout .tm-toc-list li:last-child {
    margin-bottom: 0;
}

.tm-layout .tm-toc-list a {
    color: var(--tm-gray-700);
    text-decoration: none;
    font-size: 1rem;
    transition: 0.15s;
}

.tm-layout .tm-toc-list a:hover {
    color: var(--tm-accent);
}

.tm-layout .tm-toc-collapsed .tm-toc-list {
    display: none;
}

.tm-layout .tm-toc-collapsed .tm-toc-header {
    margin-bottom: 0;
}

/* Nested H3 sublist */
.tm-layout .tm-toc-sublist {
    margin: 6px 0 0 0;
    padding: 0 0 0 18px;
    list-style: disc;
}

.tm-layout .tm-toc-sublist li {
    margin-bottom: 4px;
    line-height: 1.3;
}

.tm-layout .tm-toc-sublist li:last-child {
    margin-bottom: 0;
}

.tm-layout .tm-toc-sublist a {
    font-size: 0.9rem;
    color: var(--tm-gray-600);
}

.tm-layout .tm-toc-sublist a:hover {
    color: var(--tm-accent);
}

/* Scroll margin for headings */
.tm-layout .tm-content-body h2[id],
.tm-layout .tm-content-body h3[id] {
    scroll-margin-top: 100px;
}

/* Horizontal divider before h2 (except first) */
.tm-layout .tm-content-body h2:not(:first-child) {
    border-top: 1px solid var(--tm-gray-200);
    padding-top: 1.5em;
    margin-top: 2em;
}

/* H2 with icons */
.tm-layout .tm-content-body h2 {
    display: flex;
    align-items: center;
    gap: 10px;
}

.tm-layout .tm-content-body h2::before {
    content: '';
    width: 24px;
    height: 24px;
    background-size: contain;
    background-repeat: no-repeat;
    flex-shrink: 0;
    opacity: 0.7;
}

/* Section-specific icons */
.tm-layout .tm-content-body h2.tm-icon-company::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234b5563'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 21V5a2 2 0 00-2-2H7a2 2 0 00-2 2v16m14 0h2m-2 0h-5m-9 0H3m2 0h5M9 7h1m-1 4h1m4-4h1m-1 4h1m-5 10v-5a1 1 0 011-1h2a1 1 0 011 1v5m-4 0h4'/%3E%3C/svg%3E");
}

.tm-layout .tm-content-body h2.tm-icon-business::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234b5563'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 13.255A23.931 23.931 0 0112 15c-3.183 0-6.22-.62-9-1.745M16 6V4a2 2 0 00-2-2h-4a2 2 0 00-2 2v2m4 6h.01M5 20h14a2 2 0 002-2V8a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z'/%3E%3C/svg%3E");
}

.tm-layout .tm-content-body h2.tm-icon-finance::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234b5563'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 19v-6a2 2 0 00-2-2H5a2 2 0 00-2 2v6a2 2 0 002 2h2a2 2 0 002-2zm0 0V9a2 2 0 012-2h2a2 2 0 012 2v10m-6 0a2 2 0 002 2h2a2 2 0 002-2m0 0V5a2 2 0 012-2h2a2 2 0 012 2v14a2 2 0 01-2 2h-2a2 2 0 01-2-2z'/%3E%3C/svg%3E");
}

.tm-layout .tm-content-body h2.tm-icon-strategy::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234b5563'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 20l-5.447-2.724A1 1 0 013 16.382V5.618a1 1 0 011.447-.894L9 7m0 13l6-3m-6 3V7m6 10l4.553 2.276A1 1 0 0021 18.382V7.618a1 1 0 00-.553-.894L15 4m0 13V4m0 0L9 7'/%3E%3C/svg%3E");
}

.tm-layout .tm-content-body h2.tm-icon-risk::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234b5563'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z'/%3E%3C/svg%3E");
}

.tm-layout .tm-content-body h2.tm-icon-summary::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%234b5563'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z'/%3E%3C/svg%3E");
}

/* H3 styling */
.tm-layout .tm-content-body h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--tm-gray-700);
    margin: 1.75em 0 0.5em 0;
    padding-bottom: 0.25em;
    border-bottom: 2px solid var(--tm-gray-100);
}

.tm-layout .tm-content-body h3:first-child,
.tm-layout .tm-content-body h2 + h3 {
    margin-top: 0.75em;
}

/* Pros/Cons styling for h3 */
.tm-layout .tm-content-body h3.tm-pros {
    color: #059669;
    border-bottom-color: #d1fae5;
}

.tm-layout .tm-content-body h3.tm-pros::before {
    content: '✓ ';
}

.tm-layout .tm-content-body h3.tm-cons {
    color: #dc2626;
    border-bottom-color: #fee2e2;
}

.tm-layout .tm-content-body h3.tm-cons::before {
    content: '✗ ';
}

/* Lists */
.tm-layout .tm-content-body ul {
    margin: 0.75em 0 1.25em 0;
    padding-left: 0;
    list-style: none !important;
}

.tm-layout .tm-content-body ul li {
    position: relative;
    padding-left: 1.5em;
    margin-bottom: 0.625em;
    line-height: 1.6;
    list-style: none !important;
    font-size: 1rem;
}

.tm-layout .tm-content-body ul li::marker {
    content: none;
    display: none;
}

.tm-layout .tm-content-body ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 6px;
    height: 6px;
    background: var(--tm-accent);
    border-radius: 50%;
}

/* Bold labels in list items */
.tm-layout .tm-content-body ul li strong:first-child {
    color: var(--tm-gray-800);
    font-weight: 600;
}

/* Pros list (after .tm-pros heading) */
.tm-layout .tm-content-body h3.tm-pros + ul li::before {
    background: #059669;
}

/* Cons list (after .tm-cons heading) */
.tm-layout .tm-content-body h3.tm-cons + ul li::before {
    background: #dc2626;
}

/* Ordered lists */
.tm-layout .tm-content-body ol {
    margin: 0.75em 0 1.25em 0;
    padding-left: 1.5em;
}

.tm-layout .tm-content-body ol li {
    margin-bottom: 0.625em;
    line-height: 1.6;
    padding-left: 0.25em;
    font-size: 1rem;
}

/* Paragraphs after headings */
.tm-layout .tm-content-body h2 + p,
.tm-layout .tm-content-body h3 + p {
    margin-top: 0.5em;
}

/* Tables if any */
.tm-layout .tm-content-body table {
    width: 100%;
    border-collapse: collapse;
    margin: 1em 0;
    font-size: 1rem;
}

.tm-layout .tm-content-body th,
.tm-layout .tm-content-body td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--tm-gray-200);
}

.tm-layout .tm-content-body th {
    background: var(--tm-gray-50);
    font-weight: 600;
    color: var(--tm-gray-700);
}

.tm-layout .tm-content-body tr:hover td {
    background: var(--tm-gray-50);
}

.tm-layout .tm-yhteenveto-main .tm-content-box h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--tm-gray-800);
    margin: 1.5em 0 0.75em 0;
}

.tm-layout .tm-yhteenveto-main .tm-content-box h2:first-child {
    margin-top: 0;
}

.tm-layout .tm-yhteenveto-main .tm-content-box h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--tm-gray-700);
    margin: 1.25em 0 0.5em 0;
}

.tm-layout .tm-yhteenveto-main .tm-content-box p {
    margin: 0 0 1em 0;
    line-height: 1.7;
    font-size: 1rem;
}

.tm-layout .tm-yhteenveto-main .tm-content-box ul,
.tm-layout .tm-yhteenveto-main .tm-content-box ol {
    margin: 0 0 1em 0;
    padding-left: 1.5em;
}

.tm-layout .tm-yhteenveto-main .tm-content-box li {
    margin-bottom: 0.5em;
    line-height: 1.6;
}

.tm-layout .tm-content-placeholder {
    color: var(--tm-gray-500);
    text-align: center;
    padding: 60px 20px;
}

/* AI Disclaimer */
.tm-layout .tm-ai-disclaimer {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-top: 2em;
    padding: 12px 14px;
    background: var(--tm-gray-50);
    border: 1px solid var(--tm-gray-200);
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--tm-gray-500);
    line-height: 1.5;
}

.tm-layout .tm-ai-disclaimer svg {
    flex-shrink: 0;
    margin-top: 1px;
    opacity: 0.6;
}

/* Sidebar */
.tm-layout .tm-yhteenveto-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.tm-layout .tm-sidebar-ticker {
    background: white;
    border-radius: var(--tm-radius);
    padding: 16px;
    box-shadow: var(--tm-shadow);
}

.tm-layout .tm-sidebar-ticker .tradingview-widget-container {
    width: 100%;
}

/* Sidebar News */
.tm-layout .tm-sidebar-news {
    background: white;
    border-radius: var(--tm-radius);
    padding: 16px;
    box-shadow: var(--tm-shadow);
}

.tm-layout .tm-sidebar-news-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--tm-gray-100);
}

.tm-layout .tm-sidebar-news-header h3 {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--tm-gray-800);
    margin: 0;
}

.tm-layout .tm-link-btn-sm {
    font-size: 0.75rem;
    padding: 4px 8px;
}

.tm-layout .tm-sidebar-news-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tm-layout .tm-sidebar-news-item {
    display: flex;
    gap: 10px;
    text-decoration: none;
    padding: 8px;
    margin: -8px;
    border-radius: 6px;
    transition: 0.15s;
}

.tm-layout .tm-sidebar-news-item:hover {
    background: var(--tm-gray-50);
}

.tm-layout .tm-sidebar-news-thumb {
    width: 60px;
    height: 45px;
    flex-shrink: 0;
    border-radius: 4px;
    overflow: hidden;
    background: var(--tm-gray-100);
}

.tm-layout .tm-sidebar-news-thumb img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

.tm-layout .tm-sidebar-news-content {
    flex: 1;
    min-width: 0;
}

.tm-layout .tm-sidebar-news-meta {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 4px;
}

.tm-layout .tm-sidebar-news-meta .tm-news-favicon {
    width: 12px;
    height: 12px;
}

.tm-layout .tm-sidebar-news-meta .tm-news-source {
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--tm-gray-500);
}

.tm-layout .tm-sidebar-news-meta .tm-news-date {
    font-size: 0.6875rem;
    color: var(--tm-gray-400);
}

.tm-layout .tm-sidebar-news-meta .tm-news-date::before {
    content: '·';
    margin: 0 4px;
}

.tm-layout .tm-sidebar-news-title {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--tm-gray-800);
    margin: 0;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tm-layout .tm-sidebar-news-item:hover .tm-sidebar-news-title {
    color: var(--tm-accent);
}

@media (max-width: 900px) {
    .tm-layout .tm-yhteenveto-layout {
        grid-template-columns: 1fr;
    }
    
    .tm-layout .tm-yhteenveto-sidebar {
        order: -1;
    }
}

/* ============================================
   Widget Sections
   ============================================ */
.tm-layout .tm-section {
    margin-bottom: 20px;
}

.tm-layout .tm-section h2 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--tm-gray-800);
    margin: 0 0 10px 0;
}

.tm-layout .tm-widget-wrap,
.tm-layout .tm-widget-box,
.tm-layout .tm-content-box {
    background: white;
    border-radius: var(--tm-radius);
    box-shadow: var(--tm-shadow);
    overflow: hidden;
}

.tm-layout .tm-widget-box {
    padding: 16px;
}

.tm-layout .tm-content-box {
    padding: 20px;
    color: var(--tm-gray-700);
    line-height: 1.7;
}

/* Two Column Layout */
.tm-layout .tm-two-col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

/* TradingView - scoped to our layout */
.tm-layout .tradingview-widget-copyright {
    display: none !important;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1100px) {
    .tm-layout .tm-two-col {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .tm-layout .tm-sidebar {
        width: 220px;
    }
    
    .tm-layout .tm-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .tm-layout {
        flex-direction: column;
        gap: 20px;
    }
    
    .tm-layout .tm-sidebar {
        width: 100%;
        position: relative;
        top: 0;
    }
    
    .tm-layout .tm-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .tm-layout .tm-card {
        padding: 14px;
    }
    
    .tm-layout .tm-card-excerpt {
        display: none;
    }
    
    .tm-layout .tm-nav,
    .tm-layout .tm-related {
        display: none;
    }
    
    .tm-layout .tm-two-col {
        gap: 15px;
    }
    
    .tm-layout .tm-tabs {
        gap: 0;
    }
    
    .tm-layout .tm-tab {
        flex: 1;
        padding: 10px 12px;
        font-size: 0.875rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .tm-layout .tm-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   FAQ Section Styles
   ============================================ */
.tm-layout .company-faq-section {
    padding: 0;
}

/* FAQ Table of Contents */
.tm-layout .faq-toc {
    background: var(--tm-gray-50);
    border: 1px solid var(--tm-gray-200);
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 24px;
}

.tm-layout .faq-toc-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.tm-layout .faq-toc-title {
    font-size: 0.8125rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--tm-gray-600);
    margin: 0;
}

.tm-layout .faq-toc-toggle {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    background: var(--tm-gray-200);
    color: var(--tm-gray-600);
    border: none;
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.15s;
}

.tm-layout .faq-toc-toggle:hover {
    background: var(--tm-gray-300);
}

.tm-layout .faq-toc ol {
    margin: 0;
    padding: 0 0 0 20px;
    list-style: decimal;
}

.tm-layout .faq-toc li {
    margin-bottom: 8px;
    line-height: 1.4;
}

.tm-layout .faq-toc li:last-child {
    margin-bottom: 0;
}

.tm-layout .faq-toc a {
    color: var(--tm-gray-700);
    text-decoration: none;
    transition: color 0.2s;
}

.tm-layout .faq-toc a:hover {
    color: var(--tm-accent);
}

.tm-layout .faq-toc.collapsed ol {
    display: none;
}

.tm-layout .faq-toc.collapsed .faq-toc-header {
    margin-bottom: 0;
}

.tm-layout .faq-item {
    background: #fff;
    border: 1px solid var(--tm-gray-200);
    border-radius: var(--tm-radius);
    margin-bottom: 16px;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}

.tm-layout .faq-item:hover {
    box-shadow: var(--tm-shadow-md);
}

.tm-layout .faq-item:target {
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.3);
}

.tm-layout .faq-question {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--tm-primary);
    margin: 0;
    padding: 16px 20px;
    background: var(--tm-gray-50);
    border-bottom: 1px solid var(--tm-gray-200);
    scroll-margin-top: 100px;
}

.tm-layout .faq-answer {
    padding: 16px 20px;
}

.tm-layout .faq-answer p {
    margin: 0 0 8px 0;
    color: var(--tm-gray-700);
    line-height: 1.7;
}

.tm-layout .faq-answer p:last-child {
    margin-bottom: 0;
}

.tm-layout .faq-updated {
    display: inline-block;
    margin-top: 8px;
    font-size: 0.75rem;
    color: var(--tm-gray-400);
    font-style: italic;
}

/* Empty state for UKK tab */
.tm-layout .faq-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--tm-gray-500);
}

.tm-layout .faq-empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
    opacity: 0.5;
}

.tm-layout .faq-empty p {
    margin: 0;
    font-size: 1rem;
}

/* Responsive */
@media (max-width: 768px) {
    .tm-layout .faq-question {
        font-size: 1rem;
        padding: 14px 16px;
    }
    
    .tm-layout .faq-answer {
        padding: 14px 16px;
    }
}