:root {
    --bg-color: #fffefa;
    --text-color: #000000;
    --accent-green: #a8d672;
    /* Light green from description/image intuition */
    --accent-green-text: #76c043;
    /* Darker for text */
    --font-main: 'Space Grotesk', sans-serif;
    --grid-size: 30px;
    --grid-color: rgba(0, 0, 0, 0.1);
}

body {
    font-family: var(--font-main);
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    background-color: var(--bg-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

*,
*:before,
*:after {
    box-sizing: inherit;
}

/* Grid Background removed from global, applied to main */

.page-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    width: 100%;
    overflow-x: hidden;
}

/* Header */
header {
    padding: 10px 40px;
    display: flex;
    align-items: center;
    background-color: var(--bg-color);
    z-index: 20;
    /* Optional: Sticky header? No request for it, but solid background requested. */
}

.header-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-icon {
    width: 48px;
    height: 48px;
    padding: 8px;
    background: var(--bg-color);
    border-radius: 0;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
}

/* Main Content */
main {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 80px 20px;
    /* Increased padding for visual breathing room */
    position: relative;

    /* Grid Background Implementation for Main Only */
    background-color: var(--bg-color);
    background-size: var(--grid-size) var(--grid-size);
    background-image:
        linear-gradient(to right, var(--grid-color) 1px, transparent 1px),
        linear-gradient(to bottom, var(--grid-color) 1px, transparent 1px);
    background-position: top left;

    /* Clear separation borders */
    border-top: 1px solid #000;
    border-bottom: 1px solid #000;
    width: 100%;
}

/* Decorations */
.decorations-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.decor-img {
    position: absolute;
    height: auto;
}

.top-left {
    left: 5.32%;
    top: 4.93%;
    width: 20%;
}

.top-right {
    right: 7.18%;
    top: 4.93%;
    width: 21.5%;
}

.bottom-left {
    left: 5.67%;
    bottom: 9.23%;
    width: 18.5%;
}

.bottom-right {
    right: 6.66%;
    bottom: 8.67%;
    width: 20.3%;
}

.hero-section {
    position: relative;
    z-index: 2;
    /* Ensure content is above decorations */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
    max-width: 1200px;
}

.slogan-wrapper {
    position: relative;
    margin-bottom: 18px;
}

/* "like a zine!" */
.zine-badge {
    position: absolute;
    top: -50px;
    /* Adjust based on crossover visual */
    right: 0;
    /* Adjust horizontal position to match image */
    color: var(--accent-green-text);
    font-size: 48px;
    font-weight: 700;
    /* Boldish */
    transform: rotate(-5deg);
    white-space: nowrap;
    z-index: 10;
    /* Positioning relative to the slogan wrapper */
    /* Based on image: centered above "no overthinking"? */
    right: 17%;
}

.slogan {
    font-size: 50px;
    font-weight: 700;
    line-height: 1.2;
    margin: 0;
    white-space: normal;
    /* Changed from nowrap to prevent clipping on smaller screens */
    max-width: 100%;
    padding: 0 20px;
    /* Add base padding to ensure no edge touching */
}

.strikethrough-text {
    position: relative;
    white-space: nowrap;
    /* Prevent line break within "no overthinking" */
}

/* The green strikethrough line */
.strikethrough-text::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 4px;
    background-color: var(--accent-green);
    transform: rotate(-2deg);
    opacity: 0.8;
}

.subtitle {
    font-size: 26px;
    font-weight: 400;
    /* Regular */
    line-height: 1.4;
    max-width: 600px;
    margin-bottom: 24px;
    margin-top: 0;
}

/* iOS Button */
.btn-ios {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background-color: var(--accent-green);
    color: #000;
    padding: 16px 32px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    border: 2px solid #000;
    /* Box shadow for offset effect */
    box-shadow: 4px 4px 0px #000;
    transition:
        transform 0.1s,
        box-shadow 0.1s;
}

.btn-ios:hover {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px #000;
}

.btn-ios:active {
    transform: translate(4px, 4px);
    box-shadow: 0 0 0 #000;
}

/* Footer */
.site-footer {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    /* Align bottom */
    padding: 40px 60px;
    width: 100%;
    background-color: var(--bg-color);
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.footer-header-logo {
    display: none;
}

.social-links {
    display: flex;
    gap: 40px;
    /* Space out "A few social media" */
}

.social-item {
    text-decoration: none;
    color: #000;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

/* Optional: Square checkboxes styles if they were in the design, but assume simple text/icon for now */
.social-item::before {
    content: '';
    display: inline-block;
    width: 12px;
    height: 12px;
    background: var(--accent-green);
    border: 1px solid #000;
}

.legal-links {
    display: flex;
    gap: 40px;
    font-size: 0.9rem;
    color: #000;
}

.legal-links a {
    color: #000;
    text-decoration: none;
}

.footer-logo img {
    height: 150px;
    /* Adjust size of the footer icon */
    width: auto;
    object-fit: contain;
}

/* Mobile Break */
.mobile-break {
    display: none;
}

@media (max-width: 768px) {
    main {
        min-height: 110vh;
        /* Reduced from 130vh to ~85% of that value */
        padding-top: 0;
        /* Spacing handled by decoration flow now */
        padding-bottom: 40px;
    }

    .mobile-break {
        display: block;
    }

    .hero-section {
        align-items: flex-start;
        padding-left: 24px;
        /* Unified left padding */
        padding-right: 16px;
    }

    .slogan-wrapper {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

    .zine-badge {
        position: static;
        order: 0;
        margin-top: 0;
        margin-bottom: 10px;
        font-size: 32px;
        /* Slightly smaller for mobile */
        /* Slightly smaller for mobile */
        right: auto;
        transform: none;
        align-self: flex-start;
        margin-left: 0;
        /* Strict left alignment */
    }

    .slogan {
        font-size: 36px;
        text-align: left;
        white-space: normal;
        /* Allow wrapping on small screens */
        padding: 0;
        /* Remove padding to align with container */
        order: 1;
    }

    .subtitle {
        font-size: 18px;
        padding: 0;
        /* Remove padding to align with container */
        text-align: left;
        align-self: flex-start;
        /* Slightly more padding for subtitle */
    }

    .btn-ios {
        align-self: flex-start;
        margin-left: 0;
    }

    .footer-content {
        display: contents;
        /* Removes wrapper for grid placement */
    }

    /* Mobile branding duplicate */
    .footer-header-logo {
        grid-area: branding;
        display: flex;
        align-items: center;
        gap: 12px;
        /* Matches header-logo style */
        margin-bottom: 20px;
    }

    .site-footer {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            'branding branding'
            'social social'
            'legal logo';
        gap: 40px;
        padding: 40px 20px 0 20px;
        /* 0 padding bottom, handled by margin if needed */
        align-items: start;
    }

    .social-links {
        grid-area: social;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 20px;
        width: 100%;
    }

    .social-item {
        justify-content: flex-start;
    }

    .legal-links {
        grid-area: legal;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        font-size: 14px;
        align-self: end;
        /* Align to bottom */
        margin-bottom: 20px;
        /* Spacing from bottom edge */
    }

    .legal-links .copyright {
        order: 1;
        margin-top: 10px;
        /* Optional spacing above copyright */
    }

    .footer-logo {
        grid-area: logo;
        justify-self: end;
        align-self: end;
        margin-bottom: 0;
        line-height: 0;
        /* Remove inline spacing */
    }

    .footer-logo img {
        height: 100px;
        margin-bottom: 0;
        display: block;
    }
}

/* Responsive Decorations */
/* Mobile-specific duplicate image */
.mobile-top-left,
.mobile-bottom-left,
.mobile-bottom-right {
    display: none;
}

@media (max-width: 1200px) {
    .top-left {
        width: 17%;
    }

    .top-right {
        width: 18%;
    }

    .bottom-left {
        width: 16%;
    }

    .bottom-right {
        width: 17%;
    }
}

@media (max-width: 768px) {
    .decorations-layer {
        position: relative;
        height: auto;
        display: flex;
        flex-direction: column;
        z-index: 1;
        width: 100%;
    }

    .decor-img {
        position: absolute;
        /* Default for others */
    }

    .top-left {
        display: none;
        /* Hide original background image on mobile */
    }

    .mobile-top-left {
        display: none;
        margin-top: 64px;
        margin-left: -12px;
        margin-right: -16px;
        /* Negative margin to pull to right edge despite container padding */
        width: calc(100% + 12px + 16px);
        height: auto;
        /* Maintain aspect ratio */
        align-self: flex-start;
    }

    .top-right {
        position: relative;
        /* Flow layout participation */
        align-self: flex-start;
        /* Align start to respect margin-left */
        margin-left: 75px;
        margin-top: 50px;
        margin-right: 0;
        margin-bottom: 35px;
        width: calc(100% - 75px);
        /* Scale to fill remaining width */
        height: auto;
        /* Maintain aspect ratio */
        right: auto;
        top: auto;
    }

    .bottom-left {
        display: none;
    }

    .mobile-bottom-left {
        display: block;
        width: 100%;
        margin: 0;
        margin-bottom: 0px;
        /* User requested 0, and reduced main padding */
        transform: rotate(21deg);
        height: auto;
        /* Maintain aspect ratio */
        align-self: center;
        /* Or flex-start if needed */
    }

    .bottom-right {
        display: none;
    }

    .mobile-bottom-right {
        display: block;
        width: 100%;
        margin: 0;
        /* Adjust alignment/margins as needed to look good in stack */
        margin-bottom: -60px;
        /* Slight overlap or spacing adjustment */
        align-self: flex-end;
    }
}

@media (max-width: 600px) {
    .desktop-break {
        display: none;
    }
}