/* rational.business -- Corporate Nautical Masonry */
:root {
    --deep-teal: #1A2F38;
    --ocean-teal: #2E5D6C;
    --sand: #F5F1EB;
    --white: #FFFFFF;
    --slate: #3A4A52;
    --copper: #B87333;
    --seafoam: #A8D5BA;
    --coral: #D4726A;
    --pale-sky: #D6E8EE;
}
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Source Sans 3', sans-serif; font-weight: 400; font-size: 15px; line-height: 1.7; color: var(--slate); background: var(--sand); overflow-x: hidden; }

/* Hero */
.hero {
    min-height: 80vh;
    padding: 80px 40px 0;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
}
.hero-content { display: flex; gap: 40px; align-items: flex-start; }
.hero-left { flex: 0 0 60%; }
.hero-right { flex: 0 0 calc(40% - 40px); display: flex; flex-direction: column; gap: 12px; }

.hero-title {
    font-family: 'Libre Baskerville', serif;
    font-weight: 700;
    font-size: 52px;
    color: var(--deep-teal);
    letter-spacing: -0.01em;
    line-height: 1.15;
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}
.hero-title.visible { opacity: 1; transform: translateX(0); }

.hero-sub {
    font-family: 'Source Sans 3', sans-serif;
    font-size: 18px;
    color: var(--slate);
    margin-top: 20px;
    max-width: 480px;
    opacity: 0;
    transition: opacity 0.4s ease-out;
}
.hero-sub.visible { opacity: 1; }

/* Hero data blocks */
.data-block {
    background: var(--white);
    border-bottom: 1px solid var(--ocean-teal);
    padding: 12px 16px;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s ease-out, transform 0.3s ease-out;
}
.data-block.visible { opacity: 1; transform: translateY(0); }
.data-label {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ocean-teal);
    display: block;
}
.data-value {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 400;
    font-size: 28px;
    color: var(--copper);
}
.data-unit {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 14px;
    color: var(--copper);
}

/* Hero rule */
.hero-rule {
    position: relative;
    margin-top: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.rule-line {
    position: absolute;
    left: 50%;
    top: 50%;
    height: 2px;
    background: var(--ocean-teal);
    width: 0;
    transform: translateX(-50%);
    transition: width 0.6s ease-out;
}
.rule-line.visible { width: 100vw; margin-left: calc(-50vw + 50%); left: 0; transform: none; }
.compass-rose {
    width: 40px;
    height: 40px;
    position: relative;
    z-index: 2;
    background: var(--sand);
    padding: 4px;
    opacity: 0;
    transform: rotate(-15deg);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}
.compass-rose.visible { opacity: 1; transform: rotate(0deg); }

/* Main content */
.main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 40px;
}

/* Ruled headers */
.ruled-header {
    border-top: 1px solid var(--ocean-teal);
    border-bottom: 1px solid var(--ocean-teal);
    padding: 16px 0;
    text-align: center;
    margin: 48px 0 32px;
    position: relative;
}
.ruled-header .border-top, .ruled-header .border-bottom { position: absolute; left: 0; height: 1px; background: var(--ocean-teal); width: 0; transition: width 0.4s ease-out; }
.ruled-header .border-top { top: -1px; }
.ruled-header .border-bottom { bottom: -1px; transition-delay: 0.3s; }
.ruled-title {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ocean-teal);
    opacity: 0;
    transition: opacity 0.3s ease-out 0.5s;
}
.ruled-header.visible .ruled-title { opacity: 1; }

/* Masonry grid */
.masonry {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 24px;
}

.m-block {
    background: var(--white);
    border-bottom: 1px solid var(--ocean-teal);
    padding: 24px;
    position: relative;
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.35s ease-out, transform 0.35s ease-out, border-color 0.25s, box-shadow 0.2s;
    background-image: repeating-linear-gradient(
        to bottom,
        transparent,
        transparent 23px,
        rgba(46,93,108,0.05) 23px,
        rgba(46,93,108,0.05) 24px
    );
}
.m-block.visible { opacity: 1; transform: translateY(0); }
.m-block:hover {
    border-bottom-color: var(--copper);
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(26,47,56,0.08);
}
.m-block-tall { grid-row: span 2; }

.block-label {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ocean-teal);
    display: block;
    margin-bottom: 12px;
}
.block-heading {
    font-family: 'Libre Baskerville', serif;
    font-weight: 700;
    font-size: 20px;
    color: var(--deep-teal);
    margin-bottom: 12px;
    line-height: 1.3;
}
.block-text { color: var(--slate); margin-bottom: 12px; }
.block-text:last-child { margin-bottom: 0; }
.block-data {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 14px;
    color: var(--copper);
    margin-bottom: 12px;
}

/* Chart fragments */
.chart-frag {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 60px;
    height: 30px;
}
.chart-line {
    stroke-dasharray: 120;
    stroke-dashoffset: 0;
}
.m-block:hover .chart-line {
    animation: chart-draw 0.4s ease-out;
}
@keyframes chart-draw {
    0% { stroke-dashoffset: 120; }
    100% { stroke-dashoffset: 0; }
}

/* Footer */
.footer {
    max-width: 1200px;
    margin: 60px auto 0;
    padding: 40px 40px 60px;
    position: relative;
}
.footer-rule {
    display: flex;
    justify-content: center;
    margin-bottom: 40px;
    border-top: 1px solid var(--ocean-teal);
    padding-top: 20px;
}
.compass-sm { width: 28px; height: 28px; opacity: 1; transform: none; background: var(--sand); padding: 2px; }
.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}
.footer-label {
    font-family: 'Source Sans 3', sans-serif;
    font-weight: 700;
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ocean-teal);
    display: block;
    margin-bottom: 8px;
}
.footer-text {
    font-size: 13px;
    color: var(--slate);
    line-height: 1.6;
}

/* Kelp corners */
.kelp-corner { position: absolute; width: 30px; bottom: 20px; }
.kelp-left { left: 10px; }
.kelp-right { right: 10px; }

@media (max-width: 900px) {
    .masonry { grid-template-columns: repeat(2, 1fr); }
    .hero-content { flex-direction: column; }
    .hero-left, .hero-right { flex: 1 1 100%; }
    .hero-title { font-size: 36px; }
    .footer-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
    .masonry { grid-template-columns: 1fr; }
    .m-block-tall { grid-row: span 1; }
    .hero { padding: 40px 20px 0; }
    .main-content { padding: 40px 20px; }
    .footer-grid { grid-template-columns: 1fr; }
    .hero-title { font-size: 28px; }
}
