/*
Theme Name: Titanrolling
Theme URI: titanrolling.local
Author: Titanrolling
Description: clone structure for with Free ACF.
Version: 1.0.0
Text Domain: titanrolling
*/

:root {
    --background: 220 25% 97%;
    --foreground: 220 40% 13%;
    --navy: 220 60% 15%;
    --navy-light: 220 45% 22%;
    --navy-dark: 220 65% 10%;
    --accent: 355 85% 44%;
    --accent-light: 355 75% 55%;
    --steel: 215 15% 58%;
    --border: 214 25% 88%;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Inter, system-ui, sans-serif;
    color: hsl(var(--foreground));
    background: hsl(var(--background));
}

h1, h2, h3, h4 {
    font-family: "Space Grotesk", sans-serif;
    margin: 0 0 12px;
}

a {
    color: inherit;
    text-decoration: none;
}

.tr-main {
    min-height: 60vh;
}

.tr-container {
    width: min(1320px, calc(100% - 48px));
    margin: 0 auto;
}

.tr-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(135deg, hsl(var(--navy-dark)), hsl(var(--navy)));
    color: #fff;
    border-bottom: 1px solid rgba(255,255,255,.15);
}

.tr-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    min-height: 80px;
}

.tr-logo {
    display: inline-flex;
    align-items: center;
    font-family: "Space Grotesk", sans-serif;
    font-weight: 700;
    font-size: 24px;
}

.tr-logo-image {
    display: block;
    width: auto;
    height: 42px;
    max-width: min(280px, 42vw);
}

.tr-nav {
    display: flex;
    gap: 28px;
    font-weight: 600;
}

.tr-nav a {
    opacity: .92;
}

.tr-nav a:hover {
    opacity: 1;
}

.tr-cta,
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    padding: 11px 18px;
    font-size: 14px;
    font-weight: 700;
    transition: .2s ease;
    border: 1px solid transparent;
}

.tr-cta,
.btn-accent {
    background: hsl(var(--accent));
    color: #fff;
}

.tr-cta:hover,
.btn-accent:hover {
    background: hsl(var(--accent-light));
}

.btn-ghost {
    border-color: rgba(255,255,255,.35);
    color: #fff;
}

.tr-hero {
    position: relative;
    color: #fff;
    padding: 130px 0 92px;
    background: linear-gradient(135deg, hsl(var(--navy-dark)), hsl(var(--navy-light)));
}

.tr-hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, hsl(var(--navy-dark) / .9), hsl(var(--navy) / .68), hsl(var(--navy-dark) / .42));
}

.tr-hero-content {
    position: relative;
    max-width: 820px;
}

.tr-kicker {
    text-transform: uppercase;
    letter-spacing: .16em;
    font-size: 11px;
    font-weight: 700;
    opacity: .75;
    margin-bottom: 10px;
}

.tr-hero h1 {
    font-size: clamp(36px, 5vw, 62px);
    line-height: 1.06;
    margin-bottom: 16px;
}

.tr-hero p {
    font-size: clamp(16px, 2vw, 20px);
    color: rgba(255,255,255,.9);
    margin-bottom: 24px;
}

.tr-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.tr-section {
    padding: 72px 0;
}

.tr-section-alt {
    background: #fff;
    border-top: 1px solid hsl(var(--border));
    border-bottom: 1px solid hsl(var(--border));
}

.tr-section h2 {
    font-size: clamp(30px, 4vw, 44px);
    margin-bottom: 26px;
}

.tr-grid {
    display: grid;
    gap: 20px;
}

.tr-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.tr-grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.tr-card {
    overflow: hidden;
    border-radius: 14px;
    background: #fff;
    border: 1px solid hsl(var(--border));
    box-shadow: 0 8px 22px rgba(12, 18, 34, .06);
}

.tr-card-image-link {
    display: block;
    aspect-ratio: 4 / 3;
    background: #e6ebf1;
}

.tr-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tr-image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #e7ecf3, #d9e0e9);
}

.tr-card-body {
    padding: 18px;
}

.tr-card-body h3 {
    font-size: 20px;
}

.tr-card-body p {
    margin: 0;
    color: #4a5a72;
    line-height: 1.58;
}

.tr-market-card {
    border: 1px solid hsl(var(--border));
    border-radius: 12px;
    padding: 20px;
    background: #fff;
    min-height: 130px;
}

.tr-page-hero {
    padding: 126px 0 46px;
    background: linear-gradient(135deg, hsl(var(--navy-dark)), hsl(var(--navy)));
    color: #fff;
}

.tr-page-hero h1 {
    font-size: clamp(34px, 4.4vw, 54px);
}

.tr-page-hero p {
    max-width: 860px;
    color: rgba(255,255,255,.9);
}

.tr-category-block {
    margin-bottom: 46px;
}

.tr-category-block:last-child {
    margin-bottom: 0;
}

.tr-product-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 28px;
}

.tr-single-image img {
    width: 100%;
    border-radius: 12px;
    margin-bottom: 18px;
}

.tr-copy-text {
    line-height: 1.68;
    color: #374a65;
}

.tr-side-panel {
    border: 1px solid hsl(var(--border));
    border-radius: 12px;
    background: #fff;
    padding: 22px;
    align-self: start;
    position: sticky;
    top: 100px;
}

.tr-side-panel h3 {
    margin-top: 0;
    margin-bottom: 10px;
}

.tr-side-panel ul {
    margin: 0 0 18px;
    padding-left: 18px;
    color: #4a5a72;
}

.tr-side-panel li {
    margin-bottom: 6px;
}

.tr-side-contact {
    margin: 0;
    color: #374a65;
}

.tr-back-link {
    display: inline-block;
    margin-bottom: 14px;
    color: rgba(255,255,255,.85);
    font-weight: 600;
}

.tr-doc-card .tr-card-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tr-doc-type {
    font-size: 11px;
    letter-spacing: .15em;
    font-weight: 700;
    color: #8d2035;
}

.tr-muted {
    color: #6f7f95;
    font-size: 14px;
}

.tr-cta-block {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border: 1px solid hsl(var(--border));
    background: #fff;
    border-radius: 14px;
    padding: 22px;
}

.tr-error-section {
    padding: 84px 0;
}

.tr-error-card {
    max-width: 780px;
    margin: 0 auto;
    border-radius: 18px;
    border: 1px solid hsl(var(--border));
    background: #fff;
    box-shadow: 0 16px 42px rgba(15, 22, 38, .08);
    padding: 52px 44px;
    text-align: center;
}

.tr-error-kicker {
    color: hsl(var(--accent));
    opacity: 1;
    margin-bottom: 14px;
}

.tr-error-card h1 {
    margin-bottom: 14px;
    font-size: clamp(34px, 4.2vw, 54px);
}

.tr-error-lead {
    margin: 0 auto;
    max-width: 620px;
    color: #465b78;
    line-height: 1.65;
}

.tr-error-actions {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin: 30px 0 22px;
}

.tr-error-btn-secondary {
    background: transparent;
    color: hsl(var(--navy));
    border-color: hsl(var(--border));
}

.tr-error-btn-secondary:hover {
    background: hsl(var(--background));
}

.tr-error-search {
    display: flex;
    gap: 10px;
    margin: 0 auto 18px;
    max-width: 520px;
}

.tr-error-search-input {
    min-width: 0;
    flex: 1;
    border: 1px solid hsl(var(--border));
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 15px;
    color: hsl(var(--foreground));
    background: #fff;
}

.tr-error-search-input:focus {
    outline: none;
    border-color: hsl(var(--accent));
    box-shadow: 0 0 0 3px hsl(var(--accent) / .14);
}

.tr-error-inline-link {
    color: hsl(var(--accent));
    font-weight: 700;
}

.tr-error-inline-link:hover {
    text-decoration: underline;
}

.screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.tr-search-hero {
    padding-bottom: 38px;
}

.tr-search-hero p {
    max-width: 820px;
}

.tr-search-section {
    padding-top: 42px;
}

.tr-search-form {
    display: flex;
    gap: 10px;
    margin-bottom: 26px;
}

.tr-search-input {
    min-width: 0;
    flex: 1;
    border: 1px solid hsl(var(--border));
    border-radius: 10px;
    padding: 11px 14px;
    font-size: 15px;
    color: hsl(var(--foreground));
    background: #fff;
}

.tr-search-input:focus {
    outline: none;
    border-color: hsl(var(--accent));
    box-shadow: 0 0 0 3px hsl(var(--accent) / .14);
}

.tr-search-results {
    display: grid;
    gap: 14px;
}

.tr-search-card {
    border: 1px solid hsl(var(--border));
    border-radius: 14px;
    background: #fff;
    padding: 22px;
}

.tr-search-meta {
    margin: 0 0 10px;
    font-size: 12px;
    color: #6f7f95;
    display: flex;
    align-items: center;
    gap: 7px;
}

.tr-search-type {
    display: inline-flex;
    align-items: center;
    background: hsl(var(--background));
    border: 1px solid hsl(var(--border));
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: hsl(var(--navy));
}

.tr-search-card h2 {
    margin-bottom: 10px;
    font-size: clamp(24px, 2.7vw, 34px);
}

.tr-search-card h2 a:hover {
    color: hsl(var(--accent));
}

.tr-search-summary {
    margin: 0 0 14px;
    line-height: 1.62;
    color: #415570;
}

.tr-search-readmore {
    font-weight: 700;
    color: hsl(var(--accent));
}

.tr-search-readmore:hover {
    text-decoration: underline;
}

.tr-search-empty {
    text-align: center;
    border: 1px solid hsl(var(--border));
    border-radius: 14px;
    background: #fff;
    padding: 34px 24px;
}

.tr-search-empty h2 {
    margin-bottom: 10px;
}

.tr-search-empty p {
    margin: 0 auto;
    max-width: 620px;
    color: #4a5a72;
}

.tr-search-empty-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.tr-search-pagination {
    margin-top: 22px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tr-search-page a,
.tr-search-page span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    border-radius: 10px;
    border: 1px solid hsl(var(--border));
    background: #fff;
    padding: 0 12px;
    font-weight: 700;
    color: hsl(var(--navy));
}

.tr-search-page a:hover {
    border-color: hsl(var(--accent));
    color: hsl(var(--accent));
}

.tr-search-page.is-current span {
    background: hsl(var(--accent));
    border-color: hsl(var(--accent));
    color: #fff;
}

.tr-footer {
    background: linear-gradient(135deg, hsl(var(--navy-dark)), hsl(var(--navy)));
    color: #fff;
    margin-top: 40px;
    padding-top: 44px;
}

.tr-footer-grid {
    display: grid;
    gap: 24px;
    grid-template-columns: 2fr 1fr 1fr;
}

.tr-footer p,
.tr-footer li {
    color: rgba(255,255,255,.82);
}

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

.tr-footer-logo {
    display: inline-flex;
    align-items: center;
    margin-bottom: 14px;
}

.tr-footer-logo-image {
    display: block;
    width: auto;
    height: 36px;
    max-width: min(240px, 55vw);
}

.tr-copy {
    border-top: 1px solid rgba(255,255,255,.18);
    margin-top: 28px;
    padding: 14px 24px;
    text-align: center;
    color: rgba(255,255,255,.76);
    font-size: 14px;
}

@media (max-width: 1100px) {
    .tr-grid-3,
    .tr-grid-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tr-product-layout {
        grid-template-columns: 1fr;
    }

    .tr-side-panel {
        position: static;
    }
}

@media (max-width: 760px) {
    .tr-container {
        width: min(1320px, calc(100% - 28px));
    }

    .tr-header-inner {
        min-height: 66px;
    }

    .tr-logo-image {
        height: 34px;
    }

    .tr-nav,
    .tr-cta {
        display: none;
    }

    .tr-grid-3,
    .tr-grid-4,
    .tr-footer-grid,
    .tr-cta-block {
        grid-template-columns: 1fr;
        display: grid;
    }

    .tr-error-section {
        padding: 56px 0;
    }

    .tr-error-card {
        padding: 34px 20px;
    }

    .tr-error-search {
        flex-direction: column;
    }

    .tr-search-form {
        flex-direction: column;
    }

    .tr-search-pagination {
        justify-content: center;
    }

    .tr-search-card {
        padding: 18px;
    }
}
