/* MarvinDigital – minimalistic consultancy page */

:root {
    --bg-ivory: #faf6f0;
    --bg-texture-line: rgba(62, 48, 32, 0.028);
    --card-parchment: #f2ebe0;
    --card-parchment-mid: #ebe2d4;
    --card-parchment-deep: #e3d8c6;
    --border-classic: #d4c6b4;
    --image-placeholder: #e8dfd2;
    --pill-warm: #ddd2c2;
    --text-body: #2c2820;
    --footer-band: #e8dcc9;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    width: 100%;
    overflow-x: hidden;
}

body {
    margin: 0;
    font-family: Georgia, "Times New Roman", Times, serif;
    font-size: 1rem;
    line-height: 1.5;
    color: var(--text-body);
    background-color: var(--bg-ivory);
    background-image:
        radial-gradient(ellipse 130% 70% at 50% -25%, rgba(255, 253, 248, 0.92) 0%, transparent 52%),
        radial-gradient(ellipse 90% 45% at 95% 100%, rgba(232, 222, 206, 0.32) 0%, transparent 48%),
        repeating-linear-gradient(
            105deg,
            transparent,
            transparent 5px,
            var(--bg-texture-line) 5px,
            var(--bg-texture-line) 6px
        );
    min-height: 100vh;
}

/* Header — nav is position:absolute so it stays top-right even if flex fails / CSS is cached */
.site-header {
    position: relative;
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 1.5rem 1.5rem;
    /* Reserve space so the logo never sits under the links */
    padding-right: clamp(9rem, 28vw, 13rem);
    border-bottom: 1px solid var(--border-classic);
    background: rgba(255, 253, 248, 0.55);
    box-sizing: border-box;
}

.header-logo {
    display: inline-block;
    max-width: 100%;
    text-decoration: none;
    vertical-align: top;
}

.header-nav {
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin: 0;
    text-align: right;
}

.header-nav-link {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-body);
    text-decoration: none;
    letter-spacing: 0.02em;
    border-bottom: 1px solid transparent;
    padding-bottom: 0.15rem;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.header-nav-link:hover {
    color: #1a1610;
    border-bottom-color: var(--border-classic);
}

.header-nav-link[aria-current="page"] {
    border-bottom-color: var(--text-body);
    cursor: default;
}

.header-nav-link[aria-current="page"]:hover {
    color: var(--text-body);
    border-bottom-color: var(--text-body);
}

.header-logo .logo-img {
    display: block;
    width: 300px;
    height: 150px;
    object-fit: contain;
}

.site-title {
    margin: 0 auto;
    font-size: 1.75rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.subpage-main {
    min-height: 60vh;
}

.subpage-title {
    margin: 0 0 1.5rem;
    font-size: 2rem;
    font-weight: 600;
}

/* Main container */
.main {
    max-width: 720px;
    margin: 0 auto;
    padding: 3rem 1.5rem 4rem;
}

.intro-block {
    margin: 0 0 2rem;
    text-align: left;
}

.intro-title {
    margin: 0 0 0.75rem;
    font-size: 2rem;
    font-weight: 600;
    line-height: 1.2;
    color: var(--text-body);
}

.intro-text {
    margin: 0;
    font-size: 1rem;
    line-height: 1.5;
    color: #444;
}

.services-heading {
    margin: 0 0 2rem;
    font-size: 1.5rem;
    font-weight: 600;
    text-align: left;
}

/* Services list */
.services-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Service block */
.service-block {
    background: var(--card-parchment);
    border: 1px solid var(--border-classic);
    border-radius: 12px;
    padding: 1.5rem;
    margin: 0;
    box-shadow: 0 1px 2px rgba(40, 32, 24, 0.06);
}

.service-block-header {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.service-title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.service-number {
    font-size: 0.875rem;
    color: #666;
}

.service-image-wrap {
    margin: 0 0 1rem;
    border-radius: 8px;
    overflow: hidden;
    background: var(--image-placeholder);
}

.service-image {
    display: block;
    max-width: 100%;
    height: auto;
}

.service-description {
    margin: 0 0 1rem;
    font-size: 0.9375rem;
    color: #444;
}

/* Keyword pills */
.service-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pill {
    display: inline-block;
    padding: 0.35rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--text-body);
    background: var(--pill-warm);
    border: 1px solid rgba(180, 165, 140, 0.35);
    border-radius: 999px;
}

/* Previous Projects section */
.previous-projects {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-classic);
}

.projects-heading {
    margin: 0 0 1.5rem;
    font-size: 1.65rem;
    font-weight: 600;
    text-align: left;
}

.projects-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    background: var(--card-parchment);
    border: 1px solid var(--border-classic);
    box-shadow: 0 1px 3px rgba(40, 32, 24, 0.07);
}

.carousel-arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    transform: translateY(-50%);
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    border: 1px solid var(--border-classic);
    border-radius: 50%;
    background: rgba(255, 253, 248, 0.92);
    color: var(--text-body);
    font-size: 1.5rem;
    line-height: 1;
    font-family: Georgia, "Times New Roman", Times, serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.carousel-arrow:hover {
    background: #fffefc;
    border-color: #a89880;
}

.carousel-arrow:focus {
    outline: 2px solid #666;
    outline-offset: 2px;
}

.carousel-arrow-prev {
    left: 0.5rem;
}

.carousel-arrow-next {
    right: 0.5rem;
}

.projects-track {
    display: flex;
    flex-wrap: nowrap;
    transition: transform 0.4s ease-in-out;
    will-change: transform;
}

.project-bubble {
    flex: 0 0 100%;
    min-width: 0;
    display: flex;
    flex-direction: column;
    padding: 1.25rem;
    background: var(--card-parchment-mid);
    border-radius: 12px;
    height: 420px;
}

.project-bubble-top {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-sector {
    flex-shrink: 0;
}

.project-title {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;
    line-height: 1.3;
}

.project-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    align-items: stretch;
    flex: 1 1 auto;
    min-height: 0;
}

.project-image-wrap {
    margin: 0;
    border-radius: 8px;
    overflow: hidden;
    background: var(--image-placeholder);
    min-height: 240px;
    height: 100%;
}

.project-image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-text {
    min-height: 0;
    padding: 0.25rem 0 0.25rem 0.25rem;
    font-size: 1.0625rem;
    line-height: 1.55;
    color: #444;
    overflow-y: auto;
}

.project-text p {
    margin: 0;
}

.project-external-link {
    margin: 0.75rem 0 0;
    font-size: 1.0625rem;
}

.project-external-link a {
    color: #333;
    text-decoration: underline;
}

.project-external-link a:hover {
    color: #000;
}

.project-bubble .pill {
    font-size: 0.9375rem;
    padding: 0.4rem 0.85rem;
}

/* Services page */
.service-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.service-tab {
    border: 1px solid var(--border-classic);
    background: var(--card-parchment);
    color: var(--text-body);
    border-radius: 999px;
    padding: 0.5rem 1rem;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
}

.service-tab.is-active {
    background: var(--card-parchment-deep);
    border-color: #b0a08c;
    font-weight: 600;
}

.service-detail-panel {
    background: var(--card-parchment);
    border: 1px solid var(--border-classic);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 2px rgba(40, 32, 24, 0.06);
}

.service-detail-intro {
    margin: 0 0 1rem;
    color: #444;
}

.service-detail-list {
    margin: 0;
    padding-left: 1.25rem;
    color: #444;
}

.service-detail-list li {
    margin-bottom: 0.75rem;
}

/* About page */
.about-section {
    margin-bottom: 1.5rem;
}

.about-heading {
    margin: 0 0 1rem;
    font-size: 1.5rem;
}

.with-divider {
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-classic);
}

.about-text {
    margin: 0;
    color: #444;
}

.about-image-wrap {
    display: block;
    float: none;
    clear: both;
    margin: 0 auto 0.25rem;
    max-width: 150px;
    border-radius: 12px;
    overflow: hidden;
    background: var(--image-placeholder);
}

.about-image {
    display: block;
    width: 100%;
    height: auto;
}

.about-separator {
    border: 0;
    border-top: 1px solid var(--border-classic);
    margin: 0 0 1.25rem;
}

.founder-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    align-items: start;
    margin-bottom: 1.5rem;
}

.founder-media {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.founder-layout .about-image-wrap {
    margin: 0;
    max-width: 150px;
    min-height: 0;
    height: auto;
}

.founder-layout .about-image {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.founder-name {
    margin: 0.35rem 0 0;
    text-align: center;
    font-size: 1rem;
    color: var(--text-body);
}

.founder-label {
    margin: 0.2rem 0 0;
    text-align: center;
    font-size: 0.9375rem;
    color: var(--text-body);
}

.founder-text {
    margin: 0;
}

/* Footer */
.site-footer {
    background: var(--footer-band);
    border-top: 1px solid var(--border-classic);
    padding: 2rem 1.5rem;
    margin-top: 0;
}

.footer-inner {
    max-width: 960px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 2rem;
}

.footer-column {
    margin: 0;
}

.footer-logo {
    display: block;
    width: 200px;
    height: 100px;
    object-fit: contain;
    margin-bottom: 0.75rem;
}

.footer-city,
.footer-email {
    margin: 0 0 0.5rem;
    font-size: 0.9375rem;
    color: #333;
}

.footer-email a {
    color: #333;
}

.footer-heading {
    margin: 0 0 0.75rem;
    font-size: 1rem;
    font-weight: 600;
}

.footer-heading-link,
.footer-logo-link {
    color: inherit;
    text-decoration: none;
}

.footer-heading-link:hover,
.footer-link:hover,
.footer-email a:hover {
    text-decoration: underline;
}

.footer-list {
    margin: 0;
    padding-left: 1.25rem;
    font-size: 0.9375rem;
    color: #444;
}

.footer-list li {
    margin-bottom: 0.35rem;
}

.footer-link {
    color: #333;
}

@media (max-width: 600px) {
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .site-header {
        padding: 1rem;
        padding-right: clamp(7.5rem, 42vw, 10rem);
    }

    .header-nav {
        right: 0.75rem;
        gap: 0.75rem;
    }

    .header-logo .logo-img {
        width: min(200px, 52vw);
        height: auto;
        max-height: 100px;
    }

    .header-nav-link {
        font-size: 0.875rem;
    }

    .subpage-title {
        font-size: 1.75rem;
    }
}

/* Responsive: two columns on wider screens */
@media (min-width: 900px) {
    .main {
        max-width: 960px;
    }

    .services-list {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 1.5rem;
    }
}
