/* Reset WordPress block defaults */
.wp-block-group,
.wp-block-columns,
.wp-block-column,
.wp-block-heading,
.wp-block-paragraph,
.wp-block-separator,
.wp-block-image,
.wp-block-buttons,
.wp-block-button {
    margin: 0;
    padding: 0;
}

.wp-block-separator {
    border: none;
}

/* Reset WordPress button defaults - let custom CSS take over */
.wp-block-button {
    background: transparent;
}

.wp-block-button__link {
    background: none;
    border-radius: 0;
    padding: 0;
}

:root {
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quad: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ============================================
   by Miles — Design System
   ============================================ */

/* ============================================
   Reset & Base
   ============================================ */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--wp--preset--font-family--body);
    font-size: 16px;
    line-height: 1.6;
    font-weight: 300;
    color: var(--wp--preset--color--text-primary);
    background-color: var(--wp--preset--color--bg-deep);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   Noise Overlay
   ============================================ */

.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1000;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ============================================
   Hero Section
   ============================================ */

.hero {
    position: relative;
    width: 100vw;
    height: 100vh;
    min-height: 700px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.hero-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle 500px at 20% 10%, var(--wp--preset--color--gradient-teal) 0%, transparent 70%),
        radial-gradient(circle 400px at 80% 30%, var(--wp--preset--color--gradient-emerald) 0%, transparent 65%),
        radial-gradient(circle 450px at 50% 100%, var(--wp--preset--color--gradient-deep) 0%, transparent 70%),
        linear-gradient(180deg, var(--wp--preset--color--bg-deep) 0%, var(--wp--preset--color--bg-base) 100%);
    z-index: 0;
}

.hero-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    z-index: 1;
    will-change: transform, opacity;
}

.hero-glow-1 {
    width: 700px;
    height: 700px;
    top: -200px;
    left: -100px;
    background: radial-gradient(circle, rgba(13, 120, 150, 0.6) 0%, rgba(13, 80, 100, 0.3) 40%, transparent 70%);
    animation: float1 12s ease-in-out infinite;
}

.hero-glow-2 {
    width: 600px;
    height: 600px;
    top: 25%;
    right: -150px;
    background: radial-gradient(circle, rgba(212, 165, 116, 0.5) 0%, rgba(212, 165, 116, 0.2) 40%, transparent 70%);
    animation: float2 10s ease-in-out infinite;
}

.hero-glow-3 {
    width: 550px;
    height: 550px;
    bottom: -100px;
    left: 30%;
    background: radial-gradient(circle, rgba(20, 180, 100, 0.4) 0%, rgba(15, 100, 60, 0.2) 40%, transparent 70%);
    animation: float3 14s ease-in-out infinite;
}

@keyframes float1 {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.7;
    }
    25% {
        transform: translate(80px, 40px) scale(1.25);
        opacity: 1;
    }
    50% {
        transform: translate(40px, 80px) scale(1.1);
        opacity: 0.85;
    }
    75% {
        transform: translate(-40px, 30px) scale(1.3);
        opacity: 0.9;
    }
}

@keyframes float2 {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.6;
    }
    33% {
        transform: translate(-70px, 50px) scale(1.35);
        opacity: 1;
    }
    66% {
        transform: translate(-30px, -40px) scale(1.15);
        opacity: 0.8;
    }
}

@keyframes float3 {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.5;
    }
    40% {
        transform: translate(60px, -30px) scale(1.4);
        opacity: 0.9;
    }
    70% {
        transform: translate(-50px, -60px) scale(1.2);
        opacity: 0.7;
    }
}

/* ============================================
   Hero Content
   ============================================ */

.hero-content {
    position: relative;
    z-index: 10;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 var(--wp--preset--spacing--xl);
    max-width: 900px;
    margin: 0 auto;
}

.hero-tagline.hero-tagline.hero-tagline {
    display: flex;
    align-items: center;
    gap: clamp(0.75rem, 2vw, 1.5rem);
    margin-block-end: var(--wp--preset--spacing--lg);
    animation: fadeUp 0.8s var(--ease-out-expo) 0.1s both;
    margin-block-start: -15vh;
}

.tagline-line {
    width: clamp(30px, 6vw, 60px);
    height: 1px;
    background: linear-gradient(90deg, transparent 0%, var(--wp--preset--color--accent) 50%, transparent 100%);
    opacity: 0.6;
}

.tagline-text {
    font-family: var(--wp--preset--font-family--body);
    font-size: clamp(0.625rem, 1.2vw, 0.75rem);
    font-weight: 400;
    letter-spacing: clamp(0.12em, 0.5vw, 0.2em);
    text-transform: uppercase;
    color: var(--wp--preset--color--accent);
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-title.hero-title {
    font-family: var(--wp--preset--font-family--display);
    font-size: clamp(3rem, 6vw, 5rem);
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-block-end: var(--wp--preset--spacing--md);
    animation: fadeUp 0.8s var(--ease-out-expo) 0.2s both;
    text-wrap: balance;
}

.title-line {
    display: block;
}

.title-accent {
    color: var(--wp--preset--color--accent);
    font-style: italic;
}

.hero-description.hero-description {
    font-size: clamp(1rem, 1.5vw, 1.125rem);
    color: var(--wp--preset--color--text-secondary);
    max-width: 560px;
    margin-block-end: var(--wp--preset--spacing--xl);
    line-height: 1.7;
    letter-spacing: -0.02em;
    animation: fadeUp 0.8s var(--ease-out-expo) 0.3s both;
    text-wrap: balance;
}

/* ============================================
   Email Form
   ============================================ */

.email-form {
    width: 100%;
    max-width: 480px;
    animation: fadeUp 0.8s var(--ease-out-expo) 0.4s both;
}

.input-wrapper {
    display: flex;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 50px;
    padding: 4px 4px 4px 0;
    transition: all 0.4s var(--ease-out-expo);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.input-wrapper:hover {
    border-color: rgba(255, 255, 255, 0.18);
}

.input-wrapper:focus-within {
    border-color: rgba(212, 165, 116, 0.5);
    box-shadow: 0 0 0 3px rgba(212, 165, 116, 0.08),
                0 4px 20px rgba(0, 0, 0, 0.15);
}

.email-input {
    flex: 1;
    background: transparent;
    border: none;
    padding: 0.875rem 1.5rem;
    font-family: var(--wp--preset--font-family--body);
    font-size: 0.9375rem;
    font-weight: 300;
    color: var(--wp--preset--color--text-primary);
    outline: none;
    letter-spacing: -0.01em;
}

.email-input::placeholder {
    color: var(--wp--preset--color--text-muted);
    font-weight: 300;
    opacity: 0.8;
}

.submit-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    background: linear-gradient(135deg, var(--wp--preset--color--accent) 0%, var(--wp--preset--color--accent-muted) 100%);
    border: none;
    border-radius: 50px;
    font-family: var(--wp--preset--font-family--body);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--wp--preset--color--bg-deep);
    cursor: pointer;
    transition: all 0.4s var(--ease-out-expo);
    white-space: nowrap;
    letter-spacing: -0.01em;
}

.submit-btn:hover {
    background: linear-gradient(135deg, var(--wp--preset--color--accent-bright) 0%, var(--wp--preset--color--accent) 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(212, 165, 116, 0.35);
}

.submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(212, 165, 116, 0.25);
}

.btn-arrow {
    transition: transform 0.4s var(--ease-out-expo);
    font-size: 0.9em;
}

.submit-btn:hover .btn-arrow {
    transform: translateX(3px);
}

.form-note.form-note {
    margin-block-start: var(--wp--preset--spacing--sm);
    font-size: 0.75rem;
    color: var(--wp--preset--color--text-muted);
}

.form-social-proof.form-social-proof {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--wp--preset--spacing--sm);
    margin-block-start: var(--wp--preset--spacing--md);
}

/* ============================================
   Social Proof Stats
   ============================================ */

.social-proof.social-proof {
    display: flex;
    align-items: center;
    gap: var(--wp--preset--spacing--lg);
    margin-block-start: var(--wp--preset--spacing--xl);
    animation: fadeUp 0.8s var(--ease-out-expo) 0.5s both;
}

.proof-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.proof-number {
    font-family: var(--wp--preset--font-family--display);
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--wp--preset--color--text-primary);
}

.proof-label {
    font-size: 0.75rem;
    color: var(--wp--preset--color--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.proof-divider {
    width: 1px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
}

/* ============================================
   Scroll Indicator
   ============================================ */

.scroll-indicator {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    margin: 0 auto;
    width: fit-content;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--wp--preset--spacing--sm);
    z-index: 10;
    animation: fadeUp 0.8s var(--ease-out-expo) 0.7s both;
}

.scroll-text {
    font-size: 0.75rem;
    color: var(--wp--preset--color--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.scroll-arrow {
    color: var(--wp--preset--color--text-muted);
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(8px); }
}

/* Hide scroll indicator on short viewports */
@media (max-height: 850px) {
    .scroll-indicator {
        display: none;
    }
}

/* ============================================
   Trusted By
   ============================================ */

.trusted-by {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: var(--wp--preset--spacing--md) var(--wp--preset--spacing--xl);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--wp--preset--spacing--lg);
    background: linear-gradient(to top, rgba(5, 5, 8, 0.8) 0%, transparent 100%);
    z-index: 10;
    animation: fadeUp 0.8s var(--ease-out-expo) 0.8s both;
}

.trusted-label {
    font-size: 0.75rem;
    color: var(--wp--preset--color--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.logo-strip {
    display: flex;
    align-items: center;
    gap: var(--wp--preset--spacing--xl);
}

.company-logo {
    height: 24px;
    width: auto;
    opacity: 0.4;
    filter: grayscale(100%) brightness(2);
    transition: opacity 0.3s var(--ease-out-quad);
}

.company-logo:hover {
    opacity: 0.7;
}

.company-logo-text {
    font-family: var(--wp--preset--font-family--body);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--wp--preset--color--text-muted);
    opacity: 0.5;
    letter-spacing: 0.02em;
    transition: opacity 0.3s var(--ease-out-quad);
}

.company-logo-text:hover {
    opacity: 0.8;
}

/* ============================================
   Portfolio Section
   ============================================ */

.portfolio {
    position: relative;
    background: var(--wp--preset--color--bg-deep);
    padding: var(--wp--preset--spacing--3-xl) 0;
}

.portfolio-header.portfolio-header {
    text-align: center;
    padding: 0 var(--wp--preset--spacing--xl);
    margin-block-end: var(--wp--preset--spacing--2-xl);
}

.portfolio-title.portfolio-title {
    font-family: var(--wp--preset--font-family--display);
    font-size: clamp(2.4rem, 4vw, 4rem);
    font-weight: 500;
    color: var(--wp--preset--color--text-primary);
    margin-block-end: var(--wp--preset--spacing--sm);
    letter-spacing: -0.02em;
    text-wrap: balance;
}

.portfolio-subtitle {
    font-size: 1rem;
    color: var(--wp--preset--color--text-secondary);
    text-wrap: pretty;
}

/* ============================================
   Portfolio Grid - Masonry Style
   ============================================ */

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--wp--preset--spacing--md);
    padding: 0 var(--wp--preset--spacing--lg);
    max-width: 1400px;
    margin: 0 auto;
}

.portfolio-column {
    display: flex;
    flex-direction: column;
    gap: var(--wp--preset--spacing--md);
}

.portfolio-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    background: var(--wp--preset--color--bg-elevated);
    transition: all 0.4s var(--ease-out-expo);
}

.portfolio-item::before {
    content: '';
    position: absolute;
    inset: 0;
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    pointer-events: none;
    z-index: 2;
}

.portfolio-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4);
}

.portfolio-item img {
    display: block;
    width: 100%;
    height: auto;
    transition: transform 0.6s var(--ease-out-expo);
}

.portfolio-item:hover img {
    transform: scale(1.03);
}

/* ============================================
   CTA Section with Animated Background
   ============================================ */

.cta-section {
    position: relative;
    padding: var(--wp--preset--spacing--3-xl) var(--wp--preset--spacing--xl);
    text-align: center;
    overflow: hidden;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.cta-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle 500px at 80% 90%, var(--wp--preset--color--gradient-teal) 0%, transparent 70%),
        radial-gradient(circle 400px at 20% 70%, var(--wp--preset--color--gradient-emerald) 0%, transparent 65%),
        radial-gradient(circle 450px at 50% 0%, var(--wp--preset--color--gradient-deep) 0%, transparent 70%),
        linear-gradient(0deg, var(--wp--preset--color--bg-deep) 0%, var(--wp--preset--color--bg-base) 100%);
    z-index: 0;
}

.cta-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 1;
}

.cta-glow-1 {
    width: 500px;
    height: 500px;
    bottom: -150px;
    right: -100px;
    background: radial-gradient(circle, rgba(13, 61, 74, 0.5) 0%, transparent 70%);
    animation: float1 12s ease-in-out infinite;
}

.cta-glow-2 {
    width: 400px;
    height: 400px;
    top: -100px;
    left: 20%;
    background: radial-gradient(circle, rgba(212, 165, 116, 0.2) 0%, transparent 70%);
    animation: float2 10s ease-in-out infinite;
}

.cta-glow-3 {
    width: 350px;
    height: 350px;
    bottom: 20%;
    left: -100px;
    background: radial-gradient(circle, rgba(15, 45, 36, 0.4) 0%, transparent 70%);
    animation: float3 14s ease-in-out infinite;
}

.cta-content.cta-content {
    position: relative;
    z-index: 10;
    margin-block-end: var(--wp--preset--spacing--2-xl);
}

/* ============================================
   Footer
   ============================================ */

.footer-title.footer-title {
    font-family: var(--wp--preset--font-family--display);
    font-size: clamp(2.4rem, 3vw, 4rem);
    font-weight: 500;
    color: var(--wp--preset--color--text-primary);
    margin-block-end: var(--wp--preset--spacing--lg);
    text-wrap: balance;
    line-height: 1.2;
}

.footer-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--wp--preset--spacing--xs);
    padding: 1rem 2rem;
    background: linear-gradient(135deg, var(--wp--preset--color--accent) 0%, var(--wp--preset--color--accent-muted) 100%);
    border-radius: 50px;
    font-family: var(--wp--preset--font-family--body);
    font-size: 1rem;
    font-weight: 500;
    color: var(--wp--preset--color--bg-deep);
    text-decoration: none;
    transition: all 0.4s var(--ease-out-expo);
}

.footer-btn:hover {
    background: linear-gradient(135deg, var(--wp--preset--color--accent-bright) 0%, var(--wp--preset--color--accent) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 165, 116, 0.35);
}

.footer-bottom {
    position: relative;
    z-index: 10;
    display: flex;
    justify-content: center;
    width: 100%;
    max-width: 1200px;
    padding-top: var(--wp--preset--spacing--lg);
}

.footer-logo {
    font-size: 1rem;
    font-weight: 500;
    color: var(--wp--preset--color--text-secondary);
}

.footer-copy {
    font-size: 0.875rem;
    color: var(--wp--preset--color--text-muted);
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .portfolio-column-3 {
        display: none;
    }
}

@media (max-width: 768px) {
    .hero-content {
        padding: 0 var(--wp--preset--spacing--lg);
    }

    .hero-tagline.hero-tagline {
        margin-block-end: var(--wp--preset--spacing--sm);
    }

    /* Scale down animated blobs on tablet */
    .hero-glow-1 {
        width: 400px;
        height: 400px;
        top: -100px;
        left: -100px;
    }

    .hero-glow-2 {
        width: 350px;
        height: 350px;
        right: -100px;
    }

    .hero-glow-3 {
        width: 300px;
        height: 300px;
        bottom: -50px;
    }

    /* Keep form inline on mobile - just make it more compact */
    .email-form {
        max-width: 100%;
    }

    .input-wrapper {
        padding: 3px 3px 3px 0;
    }

    .email-input {
        padding: 0.625rem 1rem;
        font-size: 0.8125rem;
        min-width: 0;
    }

    .submit-btn {
        padding: 0.625rem 1rem;
        font-size: 0.75rem;
    }

    .btn-arrow {
        font-size: 1em;
        display: none;
    }

    /* Make social proof more compact */
    .form-social-proof {
        gap: 0.75rem;
    }

    .avatar {
        width: 26px;
        height: 26px;
        margin-left: -8px;
    }

    .waitlist-count {
        font-size: 0.75rem;
    }

    .social-proof {
        gap: var(--wp--preset--spacing--md);
    }

    .proof-number {
        font-size: 1.5rem;
    }

    .proof-label {
        font-size: 0.6875rem;
    }

    .scroll-indicator {
        bottom: 20px;
    }

    .trusted-by {
        flex-direction: column;
        gap: var(--wp--preset--spacing--sm);
        padding: var(--wp--preset--spacing--md);
    }

    .logo-strip {
        gap: var(--wp--preset--spacing--lg);
        flex-wrap: wrap;
        justify-content: center;
    }

    .company-logo {
        height: 18px;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
        padding: 0 var(--wp--preset--spacing--md);
    }

    .portfolio-column-3 {
        display: none;
    }

    .portfolio-column-1 {
        padding-top: 0;
    }

    .footer-bottom {
        flex-direction: column;
        gap: var(--wp--preset--spacing--sm);
        text-align: center;
    }
}

@media (max-width: 480px) {
    .proof-divider {
        display: none;
    }

    .social-proof {
        flex-wrap: wrap;
        justify-content: center;
    }

    /* Scale down animated blobs even more on small mobile */
    .hero-glow-1 {
        width: 250px;
        height: 250px;
        top: -80px;
        left: -60px;
        filter: blur(60px);
    }

    .hero-glow-2 {
        width: 200px;
        height: 200px;
        top: 30%;
        right: -60px;
        filter: blur(60px);
    }

    .hero-glow-3 {
        width: 180px;
        height: 180px;
        bottom: 0;
        left: 20%;
        filter: blur(60px);
    }

    /* Also scale down CTA section glows */
    .cta-glow-1 {
        width: 200px;
        height: 200px;
    }

    .cta-glow-2 {
        width: 150px;
        height: 150px;
    }

    .cta-glow-3 {
        width: 120px;
        height: 120px;
    }

    div.scroll-indicator {
        display: flex;
    }

    .portfolio {
        padding-top: var(--wp--preset--spacing--xl);
    }

    .portfolio-title {
        line-height: 1.3;
    }
}

/* ============================================
   Success State for Form
   ============================================ */

.email-form.success .input-wrapper {
    border-color: rgba(34, 197, 94, 0.4);
    background: rgba(34, 197, 94, 0.1);
}

.email-form.success .submit-btn {
    background: #22c55e;
}

.success-message.success-message {
    margin-block-start: var(--wp--preset--spacing--sm);
    font-size: 0.875rem;
    color: #22c55e;
}