* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: #fff;
    color: #000;
    min-height: 100vh;
    line-height: 1.6;
}

.page {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 4rem 1rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

h1 {
    font-size: 2.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.site-title-link {
    color: inherit;
    text-decoration: none;
}

.site-title-link:hover {
    color: #333;
}

.links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    width: 100%;
    padding-bottom: 1.5rem;
    margin-bottom: 3rem;
    border-bottom: 1px solid #e0e0e0;
}

.links a {
    color: #0e1d67;
    font-size: 1rem;
    transition: color 0.2s;
}

.links a:hover {
    color: #1d34f1;
}

.about {
    width: 100%;
    display: flex;
    gap: 2rem;
    margin-bottom: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid #e0e0e0;
}

.about-photo {
    width: 200px;
    height: auto;
    border-radius: 6px;
    object-fit: cover;
    flex-shrink: 0;
    align-self: flex-start;
}

.about-text p {
    margin-bottom: 0.75rem;
    color: #333;
}

.about-social-links {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
    margin-top: 1rem;
}

.about-social-links a {
    color: #0e1d67;
    font-size: 0.95rem;
    text-decoration: underline;
    transition: color 0.2s;
}

.about-social-links a:hover {
    color: #1d34f1;
}

@media (max-width: 600px) {
    .about {
        flex-direction: column;
        align-items: center;
    }
    .about-photo {
        width: 160px;
    }
}

.coming-soon {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 4rem 1rem;
}

.studio-logo {
    max-width: 360px;
    width: 100%;
    height: auto;
    margin-bottom: 1.5rem;
}

.studio-title {
    font-size: 3rem;
    font-weight: 600;
}

.studio-subtitle {
    font-size: 1.1rem;
    color: #666;
    margin-top: 0.5rem;
}

.coming-soon-banner {
    margin-top: 3rem;
    margin-bottom: 3rem;
}

.studio-links a {
    color: #0e1d67;
    font-size: 1rem;
    text-decoration: underline;
}

.studio-links a:hover {
    color: #1d34f1;
}

.section-title {
    width: 100%;
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 2rem;
}

.projects {
    width: 100%;
}

.project {
    margin-bottom: 3rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid #e0e0e0;
}

.project:last-child {
    border-bottom: none;
}

.project h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.project h2 .anchor-link {
    color: #ccc;
    text-decoration: none;
    font-weight: 400;
    margin-left: 0.4rem;
    opacity: 0;
    transition: opacity 0.2s;
}

.project h2:hover .anchor-link {
    opacity: 1;
}

.project h2 .anchor-link:hover {
    color: #0e1d67;
}

.project h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 1rem 0 0.5rem;
}

.project .date {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
}

.project p {
    margin-bottom: 0.75rem;
}

.project ul,
.project ol {
    margin: 0 0 1rem 1.5rem;
}

.project li {
    margin-bottom: 0.25rem;
}

.project img {
    max-width: 100%;
    height: auto;
    margin: 0.75rem 0;
    border-radius: 4px;
}

.project a {
    color: #0e1d67;
}

.project a:hover {
    color: #1d34f1;
}

.tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 0.75rem;
}

.tag {
    display: inline-block;
    padding: 0.15rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: #0e1d67;
    background: #eef0f8;
    border-radius: 999px;
    white-space: nowrap;
}

.video-embed {
    position: relative;
    padding-bottom: 56.25%;
    margin: 0.75rem 0;
}

.video-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* ===== CALCULATORS PAGE ===== */

.calc-toc {
    width: 100%;
    margin-bottom: 2.5rem;
    padding: 1.25rem 1.5rem;
    background: #f8f9fb;
    border-left: 3px solid #0e1d67;
    border-radius: 0 4px 4px 0;
}

.calc-toc-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem 0.5rem;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
    line-height: 1.8;
}

.calc-toc-row:last-child { margin-bottom: 0; }

.calc-toc-row strong {
    min-width: 170px;
    color: #000;
}

.calc-toc-row a {
    color: #0e1d67;
    text-decoration: none;
}

.calc-toc-row a:hover {
    color: #1d34f1;
    text-decoration: underline;
}

.calc-main { width: 100%; }

.calc-category {
    width: 100%;
    font-size: 1.4rem;
    font-weight: 600;
    margin: 3rem 0 1.25rem;
    padding-bottom: 0.4rem;
    border-bottom: 2px solid #0e1d67;
    color: #0e1d67;
}

.calc-section {
    width: 100%;
    margin-bottom: 2.5rem;
    padding-bottom: 2.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.calc-section:last-child { border-bottom: none; }

.calc-section h3 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.35rem;
}

.calc-desc {
    color: #555;
    font-size: 0.95rem;
    margin-bottom: 1rem;
}

.calc-divider {
    border: none;
    border-top: 1px solid #ddd;
    margin: 1rem 0;
}

.calc-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

@media (max-width: 720px) {
    .calc-row { grid-template-columns: 1fr; }
}

.calc-formula {
    font-family: 'Courier New', Courier, monospace;
    background: #f4f5f9;
    border-left: 3px solid #0e1d67;
    padding: 1rem 1.1rem;
    border-radius: 0 4px 4px 0;
    font-size: 0.88rem;
    line-height: 1.7;
}

.calc-formula .f-main {
    font-size: 1rem;
    font-weight: 700;
    color: #0e1d67;
    margin-bottom: 0.5rem;
    display: block;
}

.calc-formula .f-sub {
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid #ddd;
}

.calc-formula .f-vars {
    color: #444;
    font-size: 0.82rem;
}

.calc-interactive {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.calc-interactive label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    flex-wrap: wrap;
}

.calc-interactive input[type="number"],
.calc-interactive select {
    padding: 0.3rem 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.9rem;
    font-family: inherit;
    background: #fff;
}

.calc-interactive input[type="number"] {
    width: 110px;
}

.calc-interactive select {
    width: auto;
}

.calc-interactive input[type="number"]:focus,
.calc-interactive select:focus {
    outline: none;
    border-color: #0e1d67;
    box-shadow: 0 0 0 2px rgba(14,29,103,0.1);
}

.calc-outputs {
    margin-top: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.calc-out {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    background: #eef0f8;
    border-radius: 4px;
    font-size: 0.9rem;
}

.calc-out-label {
    color: #555;
    font-size: 0.82rem;
    min-width: 130px;
    flex-shrink: 0;
}

.calc-out-value {
    font-weight: 600;
    color: #0e1d67;
    font-family: 'Courier New', Courier, monospace;
}

.calc-out.warn .calc-out-value { color: #b85000; }
.calc-out.error-row .calc-out-value { color: #c00; }

.calc-hint {
    font-size: 0.8rem;
    color: #777;
    margin-top: 0.15rem;
}
