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

:root {
    --primary-orange: #FF6B4A;
    --orange-dark: #FF4E28;
    --orange-light: #FF8B6A;
    --background-cream: #FFF8F5;
    --background-dark: #1A1A1A;
    --text-dark: #1A1A1A;
    --text-gray: #666666;
    --text-light: #999999;
    --white: #FFFFFF;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--background-cream);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 32px;
}

/* Header */
.header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 24px 0;
}

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

.logo {
    width: 40px;
    height: 40px;
    filter: brightness(0) saturate(100%) invert(56%) sepia(79%) saturate(2788%) hue-rotate(337deg) brightness(101%) contrast(101%);
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: rotate(360deg) scale(1.1);
}

.logo-text {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, var(--primary-orange) 0%, var(--orange-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Navigation Menu */
.top-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    background: transparent;
    height: auto;
    position: relative;
}

.menu {
    display: flex;
    flex-direction: row;
    list-style-type: none;
    margin: 0;
    padding: 0;
    gap: 32px;
    align-items: center;
}

.menu > li {
    margin: 0;
}

.menu-button-container {
    display: none;
    height: 30px;
    width: 30px;
    cursor: pointer;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
}

#menu-toggle {
    display: none;
}

.menu-button,
.menu-button::before,
.menu-button::after {
    display: block;
    background-color: var(--text-dark);
    position: absolute;
    height: 3px;
    width: 30px;
    transition: transform 400ms cubic-bezier(0.23, 1, 0.32, 1);
    border-radius: 2px;
}

.menu-button::before {
    content: '';
    margin-top: -8px;
}

.menu-button::after {
    content: '';
    margin-top: 8px;
}

#menu-toggle:checked + .menu-button-container .menu-button::before {
    margin-top: 0px;
    transform: rotate(405deg);
}

#menu-toggle:checked + .menu-button-container .menu-button {
    background: rgba(255, 255, 255, 0);
}

#menu-toggle:checked + .menu-button-container .menu-button::after {
    margin-top: 0px;
    transform: rotate(-405deg);
}

@media (max-width: 768px) {
    .menu-button-container {
        display: flex;
        z-index: 102;
    }
    
    .menu {
        position: fixed;
        top: 70px;
        left: 0;
        flex-direction: column;
        width: 100%;
        justify-content: flex-start;
        align-items: center;
        gap: 0;
        background-color: var(--white);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        max-height: 0;
        overflow: hidden;
        transition: max-height 400ms cubic-bezier(0.23, 1, 0.32, 1);
        z-index: 101;
    }
    
    #menu-toggle:checked ~ .menu {
        max-height: 500px;
    }
    
    .menu > li {
        display: flex;
        justify-content: center;
        align-items: center;
        width: 100%;
        padding: 16px 20px;
        border-bottom: 1px solid var(--background-cream);
        opacity: 0;
        transform: translateY(-10px);
        transition: opacity 300ms ease, transform 300ms ease;
    }
    
    #menu-toggle:checked ~ .menu > li {
        opacity: 1;
        transform: translateY(0);
    }
    
    .menu > li:last-child {
        border-bottom: none;
    }
    
    .menu > li a {
        display: block;
        width: 100%;
        text-align: center;
    }
}

/* Definition Card */
.definition-card {
    background: var(--white);
    border: 2px solid #E8E8E8;
    border-left: 4px solid var(--primary-orange);
    border-radius: 12px;
    padding: 24px 24px;
    max-width: 540px;
    margin-bottom: 32px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    /* Removed initial animation for faster LCP */
}

.word-title {
    font-size: 22px;
    font-weight: 900;
    color: var(--text-dark);
    margin-bottom: 6px;
    font-family: 'Georgia', serif;
}

.phonetic {
    font-size: 14px;
    color: var(--text-gray);
    font-style: italic;
    margin-bottom: 6px;
    font-family: 'Georgia', serif;
}

.part-of-speech {
    font-size: 13px;
    color: var(--primary-orange);
    font-weight: 600;
    font-style: italic;
    margin-bottom: 10px;
    text-transform: lowercase;
}

.definition-text {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-dark);
    font-family: 'Georgia', serif;
    padding-left: 18px;
    position: relative;
}

.definition-text::before {
    content: '1.';
    position: absolute;
    left: 0;
    color: var(--text-gray);
    font-weight: 600;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    padding: 140px 0 80px;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 107, 74, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 107, 74, 0.06) 0%, transparent 50%),
        linear-gradient(135deg, var(--background-cream) 0%, #FFF 50%, var(--background-cream) 100%);
    z-index: 0;
}

.hero-background::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(255, 107, 74, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    will-change: transform;
    /* Animation deferred for performance */
}

.hero-background::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 107, 74, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    will-change: transform;
    /* Animation deferred for performance */
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    position: relative;
    z-index: 1;
}

/* Left Content - animations removed for LCP optimization */

.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 107, 74, 0.1);
    border: 1px solid rgba(255, 107, 74, 0.2);
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 500;
    color: var(--primary-orange);
    margin-bottom: 24px;
    /* Removed animation for faster LCP */
}

.badge-emoji {
    font-size: 16px;
    animation: sparkle 2s ease-in-out infinite;
}

.hero-title {
    font-size: 64px;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 24px;
    color: var(--text-dark);
    contain: layout style paint;
    /* Removed animation for faster LCP */
}

.highlight {
    background: linear-gradient(135deg, var(--primary-orange) 0%, var(--orange-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    display: inline-block;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: 8px;
    left: 0;
    right: 0;
    height: 12px;
    background: rgba(255, 107, 74, 0.2);
    z-index: -1;
    border-radius: 4px;
}

.hero-description {
    font-size: 18px;
    line-height: 1.7;
    color: var(--text-gray);
    margin-bottom: 24px;
    max-width: 540px;
    /* Removed animation for faster LCP */
}

/* Signup Form */
.signup-form-wrapper {
    margin-bottom: 24px;
    /* Removed animation for faster LCP */
}

.form-group {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    max-width: 540px;
}

.email-input,
#EMAIL {
    flex: 1;
    padding: 16px 20px !important;
    font-size: 16px !important;
    border: 2px solid #D0D0D0 !important;
    border-radius: 12px !important;
    font-family: 'Inter', sans-serif !important;
    transition: all 0.3s ease !important;
    background: var(--white) !important;
    color: var(--text-dark) !important;
    font-weight: 500 !important;
}

.email-input:focus,
#EMAIL:focus {
    outline: none !important;
    border-color: var(--primary-orange) !important;
    box-shadow: 0 0 0 4px rgba(255, 107, 74, 0.1) !important;
    transform: translateY(-2px) !important;
}

.email-input::placeholder,
#EMAIL::placeholder {
    color: #999999 !important;
    font-weight: 400 !important;
}

.submit-button {
    padding: 16px 32px;
    font-size: 16px;
    font-weight: 700;
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-orange) 0%, var(--orange-dark) 100%);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 16px rgba(255, 107, 74, 0.3);
    white-space: nowrap;
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 107, 74, 0.4);
}

.submit-button:active {
    transform: translateY(0);
}

.form-hint {
    font-size: 14px;
    color: var(--text-light);
    max-width: 540px;
}

/* Timeline */
.timeline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    max-width: 100%;
    margin-top: 32px;
    /* Removed animation for faster LCP */
}

.timeline-item {
    position: relative;
    transition: all 0.4s ease;
}

.timeline-panel {
    background: var(--white);
    border: 2px solid #E8E8E8;
    border-radius: 16px;
    padding: 24px 20px;
    text-align: center;
    transition: all 0.4s ease;
    height: 100%;
}

.timeline-item.active .timeline-panel {
    background: var(--white);
    border-color: var(--primary-orange);
    box-shadow: 0 8px 24px rgba(255, 107, 74, 0.2);
    transform: translateY(-4px);
}

.timeline-number {
    width: 40px;
    height: 40px;
    background: #F5F5F5;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    color: var(--text-gray);
    margin: 0 auto 16px;
    transition: all 0.4s ease;
}

.timeline-item.active .timeline-number {
    background: linear-gradient(135deg, var(--primary-orange), var(--orange-dark));
    color: var(--white);
    transform: scale(1.1);
}

.timeline-panel h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 8px;
    line-height: 1.3;
}

.timeline-panel p {
    font-size: 13px;
    color: var(--text-gray);
    line-height: 1.5;
}

/* Right Content - Phone */
.hero-right {
    position: relative;
    /* Removed animation for faster LCP */
    margin-top: -60px;
}

.phone-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.phone-mockup {
    max-width: 400px;
    width: 100%;
    height: auto;
    border-radius: 32px;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.15),
        0 0 0 1px rgba(0, 0, 0, 0.05);
    transition: opacity 0.5s ease, transform 0.6s ease;
    content-visibility: auto;
    /* Defer float animation until after load */
}

.phone-mockup:hover {
    transform: scale(1.05) rotateY(5deg);
}

.phone-mockup.fade-out {
    opacity: 0;
}

.phone-mockup.fade-in {
    opacity: 1;
}

.phone-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(255, 107, 74, 0.2) 0%, transparent 70%);
    z-index: -1;
    filter: blur(60px);
    animation: pulse 4s ease-in-out infinite;
}

/* Footer */
.footer {
    background-color: var(--background-dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 32px 0;
    text-align: center;
}

.footer p {
    font-size: 14px;
}

.footer-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--primary-orange);
}

/* Privacy Policy Page */
.privacy-content {
    padding: 80px 0;
    background: var(--background-cream);
    min-height: calc(100vh - 200px);
}

.privacy-wrapper {
    max-width: 900px;
    margin: 0 auto;
    background: var(--white);
    padding: 60px;
    border-radius: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.privacy-wrapper h1 {
    font-size: 42px;
    font-weight: 900;
    color: var(--text-dark);
    margin-bottom: 12px;
    line-height: 1.2;
}

.last-updated {
    font-size: 14px;
    color: var(--text-gray);
    margin-bottom: 48px;
}

.privacy-section {
    margin-bottom: 40px;
}

.privacy-section h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 16px;
    margin-top: 32px;
}

.privacy-section h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 12px;
    margin-top: 24px;
}

.privacy-section p {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-gray);
    margin-bottom: 16px;
}

.privacy-section ul {
    margin: 16px 0 16px 24px;
}

.privacy-section li {
    font-size: 16px;
    line-height: 1.8;
    color: var(--text-gray);
    margin-bottom: 8px;
}

.privacy-section strong {
    color: var(--text-dark);
    font-weight: 600;
}

.highlight-box {
    background: linear-gradient(135deg, rgba(255, 107, 74, 0.1), rgba(255, 107, 74, 0.05));
    padding: 24px;
    border-radius: 12px;
    border-left: 4px solid var(--primary-orange);
    margin: 24px 0 16px 0;
    font-size: 18px;
}

/* Animations */
@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(30px, -30px) rotate(5deg);
    }
    66% {
        transform: translate(-20px, 20px) rotate(-5deg);
    }
}

@keyframes floatPhone {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
        transform: translate(-50%, -50%) scale(1);
    }
    50% {
        opacity: 0.8;
        transform: translate(-50%, -50%) scale(1.1);
    }
}

@keyframes sparkle {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2) rotate(10deg);
    }
}

/* Message Panels */
.sib-form-message-panel {
    display: none;
    padding: 12px 16px !important;
    margin-bottom: 16px;
    border-radius: 8px !important;
    animation: slideDown 0.3s ease-out;
}

.sib-form-message-panel.sib-form-message-panel--active {
    display: block !important;
}

.sib-form-message-panel__text {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px !important;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 60px;
        text-align: center;
    }

    .hero-left {
        order: 1;
    }

    .hero-right {
        order: 2;
        margin-top: 0;
    }

    .hero-title {
        font-size: 52px;
    }

    .hero-description {
        margin-left: auto;
        margin-right: auto;
    }

    .form-group {
        margin-left: auto;
        margin-right: auto;
    }

    .form-hint {
        margin-left: auto;
        margin-right: auto;
        text-align: center;
    }

    .timeline {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .definition-card {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .hero {
        padding: 120px 0 60px;
    }

    .header {
        padding: 20px 0;
    }

    .definition-card {
        padding: 16px 20px;
        margin-bottom: 24px;
    }

    .word-title {
        font-size: 20px;
    }

    .phonetic {
        font-size: 13px;
    }

    .definition-text {
        font-size: 14px;
    }

    .hero-title {
        font-size: 40px;
    }

    .hero-description {
        font-size: 16px;
    }

    .signup-form-wrapper {
        padding: 0;
        width: 100%;
    }

    .form-group {
        flex-direction: column;
        gap: 12px;
        max-width: 100%;
        margin: 0;
        width: 100%;
    }

    .email-input,
    #EMAIL {
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .submit-button {
        width: 100%;
        justify-content: center;
        box-sizing: border-box;
    }

    .form-hint {
        padding: 0;
        box-sizing: border-box;
        text-align: center;
    }

    .phone-mockup {
        max-width: 320px;
    }

    .timeline {
        grid-template-columns: 1fr;
        margin-top: 32px;
        gap: 12px;
    }

    .timeline-panel {
        padding: 20px 16px;
    }

    .timeline-panel h4 {
        font-size: 14px;
    }

    .timeline-panel p {
        font-size: 12px;
    }

    .timeline-number {
        width: 36px;
        height: 36px;
        font-size: 16px;
        margin-bottom: 12px;
    }

    .privacy-content {
        padding: 40px 0;
    }

    .privacy-wrapper {
        padding: 32px 24px;
    }

    .privacy-wrapper h1 {
        font-size: 32px;
    }

    .privacy-section h2 {
        font-size: 24px;
    }

    .privacy-section h3 {
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 32px;
    }

    .logo {
        width: 32px;
        height: 32px;
    }

    .logo-text {
        font-size: 16px;
    }

    .stats {
        flex-wrap: wrap;
        gap: 24px;
    }

    .stat-item {
        flex: 1;
        min-width: 100px;
    }
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Hide input autofill styles */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 1000px white inset;
    transition: background-color 5000s ease-in-out 0s;
}

/* Input hidden */
.input--hidden {
    position: absolute;
    left: -9999px;
}
