/* Far Point Global - Global Freight Index Styles */

/* Page Layout */
.freight-page {
    min-height: 100vh;
    padding-top: 120px;
    padding-bottom: 0;
}

/* Hero Section */
.freight-hero {
    padding: 4rem 5rem 6rem;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
}
.freight-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 40% 40%, rgba(201,169,98,0.06) 0%, transparent 50%),
                radial-gradient(ellipse at 80% 70%, rgba(201,169,98,0.04) 0%, transparent 40%);
    pointer-events: none;
}
.freight-hero-grid {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255,255,255,0.012) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(255,255,255,0.012) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse at center, black 20%, transparent 70%);
    pointer-events: none;
}
.freight-hero-content {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}
.freight-hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.8rem, 6vw, 4.5rem);
    font-weight: 300;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}
.freight-hero-title em {
    font-style: italic;
    color: var(--accent);
}
.freight-hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 700px;
    line-height: 1.8;
    font-weight: 300;
}

/* ─── Global Summary Section ─── */
.freight-summary {
    padding: 4rem 5rem;
    max-width: 1400px;
    margin: 0 auto;
}
.summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2px;
    background: var(--border);
}

/* Global Index Card */
.global-index-card {
    background: var(--bg-secondary);
    padding: 3rem;
    position: relative;
    overflow: hidden;
}
.global-index-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), var(--accent-light), var(--accent));
}
.global-index-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}
.global-index-label {
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-weight: 300;
}
.global-index-value {
    display: flex;
    align-items: baseline;
    gap: 1rem;
    margin-bottom: 0.75rem;
}
.index-price {
    font-family: var(--font-display);
    font-size: clamp(3rem, 5vw, 4rem);
    font-weight: 300;
    color: var(--accent);
    line-height: 1;
}
.index-change {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 1.25rem;
    font-weight: 500;
}
.index-change.negative {
    color: #f87171;
}
.index-change.positive {
    color: #4ade80;
}
.global-index-unit {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-muted);
}

/* Volatility Card */
.volatility-card {
    background: var(--bg-secondary);
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.volatility-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.volatility-icon {
    color: var(--text-muted);
}
.volatility-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--text-muted);
}
.volatility-value {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    font-weight: 300;
    color: var(--text-primary);
    line-height: 1;
    margin-bottom: 2rem;
}

/* Volatility Gauge */
.volatility-gauge {
    width: 100%;
}
.gauge-track {
    position: relative;
    height: 4px;
    background: rgba(255,255,255,0.08);
    border-radius: 2px;
    overflow: visible;
}
.gauge-fill {
    height: 100%;
    background: linear-gradient(90deg, #4ade80, #fbbf24, #f87171);
    border-radius: 2px;
    opacity: 0.6;
    width: 100%;
}
.gauge-marker {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 12px;
    height: 12px;
    background: var(--accent);
    border-radius: 50%;
    border: 2px solid var(--bg-secondary);
    box-shadow: 0 0 10px rgba(201,169,98,0.4);
}
.gauge-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 0.75rem;
}
.gauge-min {
    font-size: 0.85rem;
    font-weight: 500;
    color: #4ade80;
}
.gauge-max {
    font-size: 0.85rem;
    font-weight: 500;
    color: #f87171;
}
.gauge-hint {
    display: block;
    font-size: 0.6rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    color: var(--text-muted);
    margin-top: 0.15rem;
}

/* ─── Route Sections ─── */
.freight-routes {
    padding: 0 5rem 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* Region */
.route-region {
    border-bottom: 1px solid var(--border);
}
.route-region:first-child {
    border-top: 1px solid var(--border);
}

/* Region Header */
.region-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 0;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-primary);
    font-family: var(--font-body);
    transition: all 0.3s var(--ease);
}
.region-header:hover {
    padding-left: 0.5rem;
}
.region-title {
    font-family: var(--font-body);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: var(--text-primary);
}
.region-chevron {
    color: var(--text-muted);
    transition: transform 0.4s var(--ease);
}
.route-region.collapsed .region-chevron {
    transform: rotate(-180deg);
}

/* Routes Grid */
.region-routes {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2px;
    background: var(--border);
    margin-bottom: 2rem;
    overflow: hidden;
    max-height: 600px;
    transition: max-height 0.5s var(--ease), margin-bottom 0.5s var(--ease), opacity 0.4s ease;
    opacity: 1;
}
.route-region.collapsed .region-routes {
    max-height: 0;
    margin-bottom: 0;
    opacity: 0;
}

/* Route Card */
.route-card {
    background: var(--bg-secondary);
    padding: 2rem 2.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s var(--ease);
}
.route-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transition: transform 0.4s var(--ease);
    transform-origin: left;
}
.route-card:hover {
    background: var(--bg-tertiary);
}
.route-card:hover::before {
    transform: scaleX(1);
}

/* Ticker Badge */
.ticker-badge {
    display: inline-block;
    padding: 0.3rem 0.75rem;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-primary);
    border: 1px solid var(--border);
    margin-bottom: 0.75rem;
    font-family: var(--font-body);
}
.ticker-badge-primary {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(201,169,98,0.08);
}

/* Route Name */
.route-name {
    font-size: 1rem;
    color: var(--text-secondary);
    font-weight: 300;
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

/* Route Price Row */
.route-price-row {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
}
.route-price {
    font-family: var(--font-display);
    font-size: 1.8rem;
    font-weight: 300;
    line-height: 1;
}
.route-change {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.95rem;
    font-weight: 500;
}
.route-change.negative {
    color: #f87171;
}
.route-change.positive {
    color: #4ade80;
}

/* Color-code prices by magnitude */
.route-price {
    color: var(--text-primary);
}

/* ─── Disclaimer ─── */
.freight-disclaimer {
    padding: 3rem 5rem 5rem;
    max-width: 1400px;
    margin: 0 auto;
}

/* ─── Responsive ─── */
@media (max-width: 1200px) {
    .freight-hero {
        padding: 3rem 3rem 5rem;
    }
    .freight-summary,
    .freight-routes,
    .freight-disclaimer {
        padding-left: 3rem;
        padding-right: 3rem;
    }
}
@media (max-width: 900px) {
    .summary-grid {
        grid-template-columns: 1fr;
    }
    .region-routes {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 768px) {
    .freight-hero {
        padding: 2rem 1.5rem 4rem;
    }
    .freight-summary,
    .freight-routes,
    .freight-disclaimer {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    .global-index-card,
    .volatility-card {
        padding: 2rem 1.5rem;
    }
    .route-card {
        padding: 1.5rem;
    }
    .index-price {
        font-size: 2.5rem;
    }
    .volatility-value {
        font-size: 2.5rem;
    }
}
