/* =========================================
   eGUMUS V5 - ULTRA MINIMALIST STYLE SYSTEM
   ========================================= */

/* --- 1. VARIABLES --- */
:root {
    /* Colors - Slate & Blue Theme */
    --bg-body: #ffffff;
    --bg-surface: #f8fafc;
    --bg-subtle: #f1f5f9;

    --text-main: #0f172a;
    /* Slate 900 */
    --text-muted: #64748b;
    /* Slate 500 */
    --text-light: #94a3b8;
    /* Slate 400 */

    --accent: #2563eb;
    /* Blue 600 */
    --accent-hover: #1d4ed8;
    /* Blue 700 */
    --gold: #d97706;
    /* Amber 600 */
    --silver: #94a3b8;
    /* Slate 400 */

    --success: #10b981;
    /* Emerald 500 */
    --danger: #ef4444;
    /* Red 500 */

    --border: #e2e8f0;
    /* Slate 200 */

    /* Typography */
    --font-main: 'Outfit', system-ui, -apple-system, sans-serif;
    --font-heading: 'Outfit', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Spacing & Radius */
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-pill: 999px;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

/* --- DARK MODE --- */
body.dark-mode {
    --bg-body: #0f172a;
    --bg-surface: #1e293b;
    --bg-subtle: #334155;

    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-light: #64748b;

    --border: #334155;

    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5);
}

body.dark-mode header {
    background: rgba(15, 23, 42, 0.95);
    border-color: var(--border);
}

body.dark-mode .post-card-v4,
body.dark-mode .daily-summary-v4,
body.dark-mode .terminal-v4-wrap,
body.dark-mode .calc-card,
body.dark-mode .sidebar-widget {
    background-color: var(--bg-surface);
    border-color: var(--border);
}

/* --- 2. RESET & BASE --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 13px;
    /* GLOBAL SCALE DOWN: %20 Smaller (16px -> 13px) */
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.2s;
}

ul {
    list-style: none;
}

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

/* --- 3. LAYOUT --- */
.container {
    max-width: 1080px;
    /* Reduced from 1280px */
    margin: 0 auto;
    padding: 0 24px;
}

.main-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    /* Reduced Sidebar width */
    gap: 40px;
    /* Reduced gap */
    margin-top: 40px;
    padding-bottom: 60px;
}

/* --- SEARCH OVERLAY --- */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.95);
    z-index: 99999 !important;
    /* User Request: High z-index */
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 150px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    backdrop-filter: blur(5px);
}

.search-overlay.active {
    opacity: 1;
    visibility: visible;
}

.search-container {
    width: 100%;
    max-width: 700px;
    position: relative;
    padding: 0 20px;
}

.search-close {
    position: absolute;
    top: -50px;
    right: 20px;
    font-size: 2rem;
    color: #fff;
    cursor: pointer;
    transition: transform 0.2s;
}

.search-close:hover {
    transform: rotate(90deg);
    color: var(--accent);
}

.search-input-wrap {
    position: relative;
    margin-bottom: 30px;
}

.search-input {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 2px solid rgba(255, 255, 255, 0.2);
    font-size: 2rem;
    color: #fff;
    padding: 20px 0;
    font-family: var(--font-heading);
    font-weight: 700;
    outline: none;
    transition: border-color 0.3s;
}

.search-input:focus {
    border-color: var(--accent);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.search-results {
    margin-top: 20px;
}

.quick-result-card {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-md);
    padding: 20px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    animation: slideUp 0.3s ease;
}

.qr-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.qr-icon {
    font-size: 1.5rem;
    color: var(--accent);
}

.qr-name {
    font-size: 1.1rem;
    font-weight: 700;
}

.qr-price {
    font-family: var(--font-mono);
    font-size: 1.2rem;
    font-weight: 700;
}

.qr-change {
    font-size: 0.9rem;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    font-weight: 700;
}

.qr-change.up {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
}

.qr-change.down {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}




/* === HEADER MASTER STYLES (V8 - FINAL) === */
header {
    position: sticky !important;
    top: 0;
    z-index: 500 !important;
    /* Updated: 10 -> 500 (Fix pagination overlap) */
    background: rgba(255, 255, 255, 0.95);
    /* Glass effect base */
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 10px 0;
    height: 70px;
    display: flex;
    align-items: center;
    transition: background 0.3s, border-color 0.3s;
}

body.dark-mode header {
    background: rgba(15, 23, 42, 0.95);
    border-color: rgba(255, 255, 255, 0.05);
}

header .container {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 0 !important;
    position: relative;
    z-index: 10001;
    height: 100%;
}

.brand {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    line-height: 1.2;
    z-index: 10002;
    position: relative;
}

.brand-name {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.brand-name span {
    color: var(--accent);
}

.brand-slogan {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.05em;
}

/* Navigation Layout */
nav {
    margin-left: 40px !important;
    margin-right: auto;
    position: relative;
    z-index: 10002;
    display: flex;
    align-items: center;
    gap: 5px;
    pointer-events: none;
    /* FIX: Prevent nav container from blocking clicks */
}

nav a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 99px;
    /* Pill shape */
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    transition: all 0.2s;
    pointer-events: auto;
    /* Restore clicks for links */
}

nav a:hover,
nav a.active {
    background: var(--bg-subtle);
    color: var(--accent);
}

nav a i {
    font-size: 1.1em;
    opacity: 0.8;
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 999;
    /* User Request: 999 */
    position: relative;
    pointer-events: auto !important;
    /* Force clickable */
}

/* Action Buttons (Search & Theme) */
.action-btn {
    background: transparent !important;
    /* No background */
    border: none !important;
    /* No border */
    width: 38px;
    /* Smaller size */
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer !important;
    color: var(--text-main);
    position: relative;
    z-index: 10006;
    pointer-events: auto !important;
    transition: all 0.2s ease;
    outline: none !important;
    box-shadow: none !important;
    /* No shadow */
    -webkit-tap-highlight-color: transparent;
}

.action-btn:hover {
    background: rgba(0, 0, 0, 0.05) !important;
    /* Subtle hover */
    color: var(--accent) !important;
    transform: translateY(-1px);
}

.action-btn:active {
    transform: translateY(0);
}

.action-btn i {
    font-size: 1rem;
    /* Smaller icon */
    pointer-events: none;
}

/* Mobile Menu Toggle (Default Hidden) */
.mobile-menu-btn {
    display: none;
    /* Blocked in media query */
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--text-main);
    cursor: pointer;
    z-index: 10006;
    padding: 8px;
    pointer-events: auto !important;
    margin-left: 8px;
}

/* --- 5. HERO SLIDER (CORRECTED) --- */
.hero-slider-v4 {
    position: relative;
    width: 100%;
    height: 600px;
    overflow: hidden;
    margin-bottom: 60px;
}

.slider-container-v4 {
    width: 100%;
    height: 100%;
    position: relative;
}

.v4-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease, transform 8s ease;
    transform: scale(1.1);
    z-index: 0;
}

.v4-slide.active {
    opacity: 1;
    transform: scale(1);
    z-index: 1;
}

.v4-slide-img {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    filter: brightness(0.4);
}

.v4-slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.9), transparent);
}

.v4-slide-content {
    position: absolute;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 1280px;
    padding: 0 24px;
    z-index: 2;
    color: #fff;
}

.v4-slide-tag {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.v4-slide-title {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 24px;
    max-width: 900px;
}

.v4-slide-desc {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 700px;
    margin-bottom: 30px;
    line-height: 1.6;
}

.v4-slide-btn {
    display: inline-block;
    background: #fff;
    color: var(--text-main);
    padding: 12px 30px;
    border-radius: var(--radius-pill);
    font-weight: 700;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.v4-slide-btn:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-2px);
}

.v4-slider-nav {
    position: absolute;
    bottom: 40px;
    right: 40px;
    z-index: 10;
    display: flex;
    gap: 10px;
}

.v4-nav-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.3);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.v4-nav-btn:hover {
    background: #fff;
    color: var(--text-main);
}

.v4-slider-dots {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 8px;
}

.v4-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.v4-dot.active {
    background: #fff;
    transform: scale(1.2);
}

/* --- 6. POST CARDS & LISTS --- */
.post-feed-v4 {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.post-card-v4 {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 30px;
    align-items: center;
    border-bottom: 1px solid var(--border);
    padding-bottom: 40px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.post-card-v4:last-child {
    border-bottom: none;
}

.post-card-v4:hover {
    transform: translateX(10px);
}

.post-image-v4 {
    position: relative;
    height: 180px;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--bg-subtle);
}

.image-overlay {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
}

.post-card-v4:hover .image-overlay {
    transform: scale(1.1);
}

.category-tag {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-main);
    text-transform: uppercase;
    z-index: 2;
}

.post-content-v4 {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.post-meta-v4 {
    display: flex;
    gap: 10px;
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.post-title-v4 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-main);
    transition: color 0.2s;
}

.post-card-v4:hover .post-title-v4 {
    color: var(--accent);
}

.post-desc-v4 {
    font-size: 1rem;
    color: var(--text-muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.6;
}

.post-footer-v4 {
    margin-top: 8px;
}

.read-link-v4 {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-main);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.2s;
}

.read-link-v4 i {
    font-size: 0.8em;
    transition: transform 0.2s;
}

.post-card-v4:hover .read-link-v4 {
    gap: 12px;
    color: var(--accent);
}

/* --- 7. SIDEBAR --- */
.sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.sidebar-widget {
    margin-bottom: 0;
}

.widget-title {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-main);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.title-accent {
    width: 4px;
    height: 20px;
    background: var(--accent);
    border-radius: 2px;
}

.category-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.category-item a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-main);
    transition: all 0.2s;
}

.category-item a:hover {
    background: #fff;
    box-shadow: var(--shadow-md);
    transform: translateX(5px);
    color: var(--accent);
}

.category-icon {
    width: 24px;
    text-align: center;
    color: var(--text-muted);
}

/* Live Price Card in Sidebar */
.live-price-card {
    background: #0f172a;
    /* Slate 900 */
    border-radius: var(--radius-lg);
    padding: 24px;
    color: #fff;
    box-shadow: var(--shadow-lg);
}

.live-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.live-card-title {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.live-indicator {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--success);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }

    100% {
        opacity: 1;
    }
}

.live-price-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    font-size: 0.9rem;
}

.live-price-row:last-child {
    margin-bottom: 0;
}

.live-name {
    opacity: 0.7;
}

.live-val {
    font-family: var(--font-mono);
    font-weight: 700;
}

/* --- Terminal V4 Components --- */
.terminal-v4-wrap {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
    margin-bottom: 40px;
    box-shadow: var(--shadow-sm);
}

.live-price-hero {
    background: var(--bg-surface);
    border-radius: var(--radius-md);
    padding: 24px;
    text-align: center;
    margin-bottom: 30px;
    border: 1px solid var(--border);
}

.lph-label {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--text-muted);
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.lph-price {
    font-family: var(--font-mono);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-main);
    line-height: 1;
    margin-bottom: 8px;
}

.lph-change {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.lph-change.up {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.lph-change.down {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.lph-meta {
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    justify-content: center;
    gap: 8px;
}

.terminal-header-v4 {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--border);
}

.t-brand .t-main-title {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 8px;
}

.t-brand .t-subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 4px;
    font-weight: 500;
}

.t-nav-tabs {
    display: flex;
    gap: 4px;
}

.t-nav-tabs .t-btn {
    padding: 8px 16px;
    font-size: 0.8rem;
    font-weight: 700;
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
}

.t-nav-tabs .t-btn:hover {
    background: var(--bg-subtle);
    color: var(--text-main);
}

.t-nav-tabs .t-btn.active {
    background: var(--text-main);
    color: var(--bg-body);
}

.t-table-container {
    overflow-x: auto;
}

.t-table-v4 {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.t-table-v4 th {
    text-align: left;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-light);
    text-transform: uppercase;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    letter-spacing: 0.05em;
}

.t-table-v4 td {
    padding: 16px;
    border-bottom: 1px solid var(--bg-subtle);
    font-size: 0.9rem;
    vertical-align: middle;
}

.t-table-v4 tr:last-child td {
    border-bottom: none;
}

.t-table-v4 .t-row {
    transition: background 0.15s;
    cursor: pointer;
}

.t-table-v4 .t-row:hover {
    background: var(--bg-subtle);
}

.t-table-v4 .td-info {
    width: 40%;
}

.t-table-v4 .td-price-compact {
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--text-main);
}

.t-table-v4 .td-change {
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.85rem;
}

/* --- Terminal Alert Box --- */
.t-alert-box {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 100%);
    color: #fff;
    padding: 16px 24px;
    border-radius: var(--radius-md);
    margin-bottom: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: var(--shadow-md);
}

.t-alert-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.t-icon {
    font-size: 1.2rem;
    color: var(--accent);
    animation: pulse 2s infinite;
}

.t-msg {
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1.4;
}

.t-msg .highlight {
    font-weight: 700;
    color: var(--accent);
    margin-left: 4px;
}

.t-action-btn {
    font-size: 0.75rem;
    font-weight: 800;
    color: #0f172a;
    background: #fff;
    padding: 10px 20px;
    border-radius: var(--radius-pill);
    text-decoration: none;
    transition: all 0.2s;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.t-action-btn:hover {
    background: var(--accent);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

@media (max-width: 768px) {
    .t-alert-box {
        flex-direction: column;
        text-align: center;
        padding: 20px;
    }

    .t-alert-content {
        flex-direction: column;
        margin-bottom: 16px;
    }
}

.p-pill-compact {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.75rem;
    white-space: nowrap;
}

/* Calculator */
.calc-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.calc-form-v4 {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.calc-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.calc-group label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
}

.calc-input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
    background: var(--bg-surface);
}

.calc-input:focus {
    border-color: var(--accent);
    background: #fff;
}

.calc-flex-row {
    display: flex;
    align-items: flex-end;
    gap: 10px;
}

.calc-flex-row .calc-group {
    flex: 1;
}

.calc-select {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: #fff;
    font-family: var(--font-main);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    outline: none;
}

.calc-swap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: var(--bg-subtle);
    border-radius: 50%;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.8rem;
    margin-bottom: 5px;
    /* Align with select box */
    transition: all 0.2s;
}

.calc-swap:hover {
    background: var(--accent);
    color: #fff;
    transform: rotate(180deg);
}

.calc-result-box {
    margin-top: 8px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 16px;
    text-align: center;
}

.calc-res-label {
    display: block;
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--text-muted);
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.calc-res-val {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
}

.calc-res-unit {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--accent);
    margin-top: 4px;
}

/* Newsletter */
.newsletter-widget {
    background: var(--accent);
    color: #fff;
    padding: 30px;
    border-radius: var(--radius-lg);
    text-align: center;
}

.newsletter-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.newsletter-desc {
    font-size: 0.9rem;
    opacity: 0.9;
    margin-bottom: 20px;
}

.newsletter-input {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: var(--radius-sm);
    margin-bottom: 10px;
}

.newsletter-btn {
    width: 100%;
    padding: 12px;
    background: #0f172a;
    color: #fff;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 700;
    cursor: pointer;
}

/* --- 8. FOOTER --- */
footer {
    background: var(--bg-surface);
    border-top: 1px solid var(--border);
    padding: 80px 0 40px;
    margin-top: 80px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 60px;
    text-align: center;
}

.footer h4 {
    font-size: 0.9rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 24px;
    color: var(--text-main);
}

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

.footer-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.footer-links a:hover {
    color: var(--accent);
}

.footer-bottom {
    padding-top: 40px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-link {
    font-size: 1.2rem;
    color: var(--text-muted);
}

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

/* --- 9. TERMINAL & PERFORMANCE MODULE --- */
/* (Duplicates removed, keeping unique classes) */

.info-cluster {
    display: flex;
    align-items: center;
    gap: 12px;
}

.t-date {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-main);
}

.t-tag-inline {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--accent);
    background: rgba(37, 99, 235, 0.1);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
}

.p-pill-compact.up {
    color: var(--success);
    background: rgba(16, 185, 129, 0.1);
}

.p-pill-compact.down {
    color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
}

.forecast-alert {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, #0f172a 0%, #1e3a5f 100%);
    color: #fff;
    padding: 16px 24px;
    border-radius: var(--radius-md);
    margin-bottom: 32px;
}

.f-icon {
    font-size: 1.2rem;
    color: var(--accent);
}

.f-text {
    flex: 1;
    font-size: 0.9rem;
}

.f-link {
    font-size: 0.75rem;
    font-weight: 800;
    color: #fff;
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: var(--radius-pill);
    transition: all 0.2s;
}

.f-link:hover {
    background: #fff;
    color: var(--text-main);
}

/* --- 10. DAILY SUMMARY & MARKET SUMMARY (NEW) --- */
.daily-summary-v4 {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.3s ease;
}

.daily-summary-v4:hover {
    box-shadow: var(--shadow-lg);
}

.mod-header-v4 {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
}

.header-line {
    width: 4px;
    height: 24px;
    background: var(--accent);
    border-radius: 2px;
}

.mod-title-v4 {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-main);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0;
}

.summary-table-wrap {
    overflow-x: auto;
}

.summary-table {
    width: 100%;
    border-collapse: collapse;
}

.summary-table th {
    text-align: left;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.summary-table td {
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
    transition: background-color 0.2s;
}

.summary-table tr:last-child td {
    border-bottom: none;
}

.summary-table tbody tr {
    transition: background-color 0.2s;
}

.summary-table tbody tr:hover {
    background-color: var(--bg-subtle);
}

.summary-table tbody tr:hover td {
    color: var(--accent);
}

.summary-icon {
    width: 24px;
    text-align: center;
    color: var(--text-muted);
    margin-right: 8px;
    transition: color 0.2s;
}

.summary-table tbody tr:hover .summary-icon {
    color: var(--accent);
}

.emtiad {
    display: flex;
    align-items: center;
}

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

.fiyat {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
}

.change-up {
    color: var(--success);
}

.change-down {
    color: var(--danger);
}

/* Market Summary Specifics */
.market-summary .mod-title-v4 {
    color: var(--text-main);
}

.market-summary .header-line {
    background: #10b981;
    /* Green for money/market */
}

/* --- MARKET ANALYSIS CARD --- */
.market-analysis-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px;
    margin-bottom: 40px;
    box-shadow: var(--shadow-sm);
}

.mac-header {
    margin-bottom: 24px;
}

.mac-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.1rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--text-main);
    margin-bottom: 8px;
}

.mac-title i {
    color: var(--accent);
    font-size: 1.2rem;
}

.mac-subtitle {
    font-size: 0.95rem;
    color: var(--text-muted);
}

.mac-main-box {
    border: 2px solid var(--accent);
    border-radius: var(--radius-lg);
    padding: 30px;
    text-align: center;
    margin-bottom: 40px;
    background: #fff;
}

.mac-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.mac-price {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--text-main);
    line-height: 1;
    margin-bottom: 16px;
    font-family: var(--font-heading);
}

.mac-badge {
    display: inline-block;
    padding: 6px 16px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 1.1rem;
}

.mac-badge.up {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.mac-badge.down {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.mac-date {
    display: block;
    margin-top: 16px;
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 500;
}

.mac-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.mac-col-title {
    font-size: 0.9rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 20px;
    padding-left: 12px;
    border-left: 3px solid var(--accent);
}

.mac-table {
    width: 100%;
    border-collapse: collapse;
}

.mac-table th {
    text-align: left;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-light);
    font-weight: 700;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.mac-table td {
    padding: 16px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.95rem;
    color: var(--text-main);
    font-weight: 600;
}

.mac-table td:last-child {
    text-align: right;
}

.mac-table th:last-child {
    text-align: right;
}

.mac-change-tag {
    font-size: 0.85rem;
    padding: 2px 6px;
    border-radius: 4px;
}

.mac-change-tag.up {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.mac-change-tag.down {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.mac-row-title {
    display: block;
    color: var(--text-main);
}

.mac-row-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 400;
    margin-top: 2px;
}

.mac-total-val {
    color: var(--accent);
    font-weight: 800;
    font-family: var(--font-mono);
}

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

    .mac-price {
        font-size: 2.5rem;
    }
}

/* --- 11. RESPONSIVE --- */
@media (max-width: 992px) {

    .main-layout,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        order: 2;
    }

    .hero-slider-v4 {
        height: 400px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .mobile-menu-btn {
        display: block;
    }

    nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(10px);
        padding: 24px;
        flex-direction: column;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-lg);
    }

    nav.active {
        display: flex;
    }

    .v4-slide-title {
        font-size: 2rem;
    }

    .v4-slide-desc {
        font-size: 1rem;
        -webkit-line-clamp: 3;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .post-card-v4 {
        grid-template-columns: 1fr;
    }

    .post-image-v4 {
        height: 240px;
    }

    .footer-grid {
        gap: 40px;
    }
}

/* --- PAGINATION V4 --- */
.pagination-v4 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.page-numbers {
    display: flex;
    align-items: center;
    gap: 8px;
}

.page-link,
.page-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    min-width: 40px;
    padding: 0 16px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-muted);
    background: #fff;
    border: 1px solid var(--border);
    transition: all 0.2s;
    text-decoration: none;
}

.page-num {
    padding: 0;
    /* Sayılar için kare/dairemsi yapı */
}

.pagination-dots {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    min-width: 40px;
    font-size: 1.2rem;
    color: var(--text-muted);
    font-weight: 700;
    letter-spacing: 2px;
}

.page-link:hover,
.page-num:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.page-num.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    box-shadow: var(--shadow-md);
}

.page-link i {
    font-size: 0.8em;
}

.page-link.prev i {
    margin-right: 8px;
}

.page-link.next i {
    margin-left: 8px;
}

/* Responsive Pagination */
@media (max-width: 600px) {
    .pagination-v4 {
        gap: 10px;
        flex-wrap: wrap;
    }

    .page-link span {
        display: none;
        /* Mobilde sadece ikon kalsın */
    }

    .page-link {
        padding: 0;
        width: 40px;
    }

    .page-link i {
        margin: 0 !important;
    }
}

/* FIXES FOR MARKET ANALYSIS CARD */
.mac-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    align-items: start;
}

/* Ensure tables don't collapse weirdly (LEGACY - Keeping for backup but mostly replaced by list) */
.mac-table {
    width: 100%;
    border-collapse: collapse;
}

/* --- NEW LIST STYLE LAYOUT --- */
.mac-list-group {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-top: 1px solid var(--border);
}

.mac-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}

.mac-list-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    max-width: 50%;
}

.mac-list-right {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-end;
    text-align: right;
}

.mac-val {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-main);
    margin-bottom: 2px;
}

/* --- END LIST STYLE --- */

.mac-col {
    /* overflow removed as list style handles it better via flex wrapping if needed */
}

/* Special styling for large values */
.mac-total-val {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 800;
    color: var(--accent);
    font-size: 0.95rem;
    letter-spacing: -0.5px;
}

/* Responsive adjustment */
@media (max-width: 1200px) {
    .mac-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 900px) {
    .mac-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .mac-list-item {
        padding: 10px 0;
    }

    .mac-val,
    .mac-total-val {
        font-size: 0.9rem;
    }

    .mac-table td,
    .mac-table th {
        padding: 10px 4px;
        font-size: 0.85rem;
    }

    .mac-total-val {
        font-size: 0.85rem;
        letter-spacing: -1px;
        /* Squeeze text more on mobile */
    }
}

/* === ULTIMATE MOBILE FIX 2025 (COMPACT MODE V4 - 10% LARGER) === */

@media (max-width: 1100px) {

    /* 0. AGGRESSIVE SCALING (Zoom Out Effect) */
    html {
        font-size: 12px !important;
        /* Adjusted: 11px -> 12px */
    }

    /* 1. Global Layout & Reset */
    html,
    body {
        overflow-x: hidden !important;
        width: 100% !important;
        max-width: 100% !important;
    }

    .container {
        width: 100% !important;
        padding-left: 10px !important;
        /* Minimal padding */
        padding-right: 10px !important;
        box-sizing: border-box !important;
        max-width: 100% !important;
    }

    /* 2. Image & Media Handling */
    img {
        max-width: 100% !important;
        height: auto !important;
    }

    .post-image-v4 {
        height: 180px !important;
        /* Adjusted: 150px -> 180px */
    }

    .news-card-mini .img-wrap {
        aspect-ratio: 16/9 !important;
        max-height: 160px !important;
        /* Adjusted: 140px -> 160px */
    }

    /* 3. Typography Reduction */
    h1 {
        font-size: 1.4rem !important;
        margin-bottom: 8px !important;
    }

    h2 {
        font-size: 1.25rem !important;
        margin-bottom: 6px !important;
    }

    h3 {
        font-size: 1.1rem !important;
        margin-bottom: 6px !important;
    }

    h4 {
        font-size: 0.9rem !important;
        margin-bottom: 4px !important;
    }

    p,
    span,
    div {
        line-height: 1.4 !important;
    }

    /* 4. Compact Card Layouts */
    .news-grid-4,
    .news-grid-3,
    .companies-grid {
        display: flex !important;
        flex-direction: column !important;
        gap: 12px !important;
        /* Reduced gap */
    }

    .post-card-v4 {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        padding-bottom: 16px !important;
        margin-bottom: 16px !important;
        height: auto !important;
        border-bottom: 1px solid var(--border) !important;
    }

    .post-content-v4 {
        padding: 0 !important;
        gap: 6px !important;
    }

    .post-title-v4 {
        font-size: 1.2rem !important;
        line-height: 1.2 !important;
    }

    .post-desc-v4 {
        font-size: 0.9rem !important;
        -webkit-line-clamp: 3;
        display: -webkit-box !important;
        margin-bottom: 6px !important;
    }

    /* 5. Header & Menu Compact */
    header {
        padding: 10px 0 !important;
        height: auto !important;
    }

    header .container {
        height: 40px !important;
        /* Very compact header */
    }

    /* Force Mobile Menu on Tablet/Desktop Mode */
    nav {
        display: none !important;
    }

    nav.active {
        display: flex !important;
        position: absolute !important;
        top: 100% !important;
        left: 0 !important;
        width: 100% !important;
        background: rgba(255, 255, 255, 0.98) !important;
        flex-direction: column !important;
        padding: 20px !important;
        box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1) !important;
    }

    .mobile-menu-btn {
        display: block !important;
        font-size: 1.2rem !important;
    }

    .brand-name {
        font-size: 1.2rem !important;
    }

    .brand-slogan {
        display: none !important;
    }

    /* Hide slogan on mobile to save space */

    /* 6. Hero Slider Compact */
    .hero-slider-v4 {
        height: 240px !important;
        /* Adjusted: 250px -> 240px (Consistent) */
        margin-bottom: 20px !important;
    }

    .v4-slide-content {
        bottom: 20px !important;
        padding: 0 16px !important;
    }

    .v4-slide-title {
        font-size: 1.5rem !important;
        margin-bottom: 8px !important;
    }

    .v4-slide-desc {
        font-size: 0.85rem !important;
        -webkit-line-clamp: 2 !important;
        margin-bottom: 10px !important;
    }

    .v4-slide-btn {
        padding: 6px 16px !important;
        font-size: 0.8rem !important;
    }

    /* 7. Tables & Widgets */
    .t-table-container,
    .summary-table-wrap {
        display: block !important;
        width: 100% !important;
        overflow-x: auto !important;
        margin-bottom: 12px !important;
    }

    .t-table-v4,
    .summary-table {
        font-size: 0.8rem !important;
    }

    .t-table-v4 th,
    .t-table-v4 td,
    .summary-table th,
    .summary-table td {
        padding: 6px 8px !important;
    }

    .terminal-v4-wrap,
    .daily-summary-v4,
    .market-analysis-card,
    .sidebar-widget {
        padding: 16px !important;
        margin-bottom: 20px !important;
    }

    /* 8. Footer Compact */
    footer {
        padding: 30px 0 15px !important;
        margin-top: 30px !important;
    }

    .footer-grid {
        gap: 20px !important;
    }

    .footer-bottom {
        flex-direction: column !important;
        gap: 10px !important;
        text-align: center !important;
        padding-top: 20px !important;
    }
}