/**
 * ProductPoll Marketing Website Styles
 * Under Construction / Coming Soon Page
 * Design based on Figma specifications
 */

/* ============================================
   CSS Variables (Design Tokens)
   ============================================ */
:root {
    /* Colors */
    --color-black: #000000;
    --color-dark-gray: #141414;           /* Top banner background */
    --color-medium-gray: #4f4f4f;         /* Footer text */
    --color-light-gray: #646464;          /* Form placeholder */
    --color-off-white: #f8f8f8;           /* Main text color */
    --color-accent-green: #03ffa1;        /* Logo accent color */
    --color-accent-dark-green: #005133;   /* Logo 'p' background */

    /* Typography */
    --font-family: 'Geologica', -apple-system, BlinkMacSystemFont, sans-serif;

    /* Spacing */
    --spacing-xs: 8px;
    --spacing-sm: 16px;
    --spacing-md: 24px;
    --spacing-lg: 40px;
    --spacing-xl: 60px;

    /* Border Radius */
    --radius-sm: 5px;
    --radius-md: 10px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
}

/* ============================================
   Reset & Base Styles
   ============================================ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    /* Make sure html fills the full viewport height */
    height: 100%;
}

body {
    font-family: var(--font-family);
    background-color: var(--color-black);
    color: var(--color-off-white);
    /* Fill exactly the screen height - no scrolling needed */
    min-height: 100vh;
    height: 100%;
    display: flex;
    flex-direction: column;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ============================================
   Top Banner (Under Construction Notice)
   ============================================ */
.top-banner {
    background-color: var(--color-dark-gray);
    padding: 6px var(--spacing-md);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    /* Fixed at the top of the screen */
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
}

.banner-icon {
    flex-shrink: 0;
}

.banner-text {
    font-size: 14px;
    font-weight: 200;
    color: var(--color-off-white);
    letter-spacing: 0.02em;
}

/* ============================================
   Main Content Area
   ============================================ */
.main-content {
    /* Take up all available space between banner and footer */
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Content starts from top, not centered */
    justify-content: flex-start;
    /* Add top padding to account for fixed banner (~29px height) */
    padding: calc(var(--spacing-lg) + 29px) var(--spacing-md) var(--spacing-lg);
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* ============================================
   Logo Styles
   ============================================ */
.logo {
    /* Space between logo and title - proportional to design */
    margin-bottom: 80px;
}

/* Logo image from SVG file */
.logo-img {
    height: 26px;
    width: auto;
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    text-align: center;
    /* Space between hero section and feedback section - proportional */
    margin-bottom: 100px;
}

.hero-title {
    font-size: clamp(32px, 6vw, 57px);
    font-weight: 300;
    color: var(--color-off-white);
    letter-spacing: -0.02em;
    line-height: 1.2;
}

/* Subtitle under the main hero title */
.hero-subtitle {
    color: #6E6E6E;
    text-align: center;
    font-family: var(--font-family);
    /* Responsive font size - scales between 16px and 25px based on screen width */
    font-size: clamp(16px, 4vw, 20px);
    font-weight: 200;
    line-height: 1.25;
    /* Space from title - proportional to design */
    margin-top: 8px;
    max-width: 675px;
    /* Add padding on mobile so text doesn't touch screen edges */
    padding: 0 var(--spacing-sm);
}

/* ============================================
   CTA Button (See How It Works)
   ============================================ */
.cta-button-wrapper {
    /* Wrapper for button + FREE badge positioning */
    position: relative;
    display: inline-block;
    /* Space from subtitle - proportional to design */
    margin-top: 45px;
    /* Smooth transition for hover effect (badge moves with button) */
    transition: transform var(--transition-fast);
    cursor: pointer;
}

.cta-button {
    /* Button size and shape - pill style */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 202px;
    height: 40px;
    border-radius: 20px;
    text-decoration: none;

    /* Dark gradient background */
    background: linear-gradient(180deg, #0c0c0c 0%, #0d0d0d 100%);

    /* Gradient border effect (white to gray, left to right) */
    border: 1px solid transparent;
    background-image:
        linear-gradient(180deg, #0c0c0c 0%, #0d0d0d 100%),
        linear-gradient(90deg, #ffffff 0%, #999999 100%);
    background-origin: border-box;
    background-clip: padding-box, border-box;

    /* Text styling */
    color: #ffffff;
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: 200;

    /* Smooth hover transition */
    transition: all var(--transition-fast);
    cursor: pointer;
}

.cta-button-wrapper:hover {
    /* Move the whole wrapper (button + badge) together on hover */
    transform: translateY(-2px);
}

.cta-button-wrapper:hover .cta-button {
    /* Slightly lighter button on hover */
    background-image:
        linear-gradient(180deg, #141414 0%, #1a1a1a 100%),
        linear-gradient(90deg, #ffffff 0%, #bbbbbb 100%);
}

.free-badge {
    /* Position: 14px from right edge, 10px above button top (half overflow) */
    position: absolute;
    top: -10px;
    right: 14px;

    /* Badge size and shape */
    width: 46px;
    height: 18px;
    border-radius: 4px;

    /* Green background */
    background-color: var(--color-accent-green);

    /* Text styling */
    color: #000000;
    font-family: var(--font-family);
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    line-height: 18px;
}

/* Responsive button for mobile */
@media (max-width: 480px) {
    .cta-button {
        width: 180px;
        height: 36px;
        font-size: 14px;
        border-radius: 18px;
    }

    .free-badge {
        right: 10px;
        font-size: 11px;
        width: 38px;
        height: 16px;
        line-height: 16px;
        top: -8px;
    }
}

/* ============================================
   Feedback Section
   ============================================ */
.feedback-section {
    width: 100%;
    max-width: 611px;
    text-align: center;
}

.feedback-heading {
    font-size: 18px;
    font-weight: 300;
    color: var(--color-off-white);
    margin-bottom: var(--spacing-sm); /* Reduced gap before text box */
}

/* Feedback Card - with glowing effect, now acts as the textarea */
.feedback-card {
    background-color: var(--color-dark-gray);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    border: 1px solid transparent;
    /* Gradient border effect */
    background-image:
        linear-gradient(var(--color-dark-gray), var(--color-dark-gray)),
        linear-gradient(135deg, #464646 0%, #232323 100%);
    background-origin: border-box;
    background-clip: padding-box, border-box;
    /* White glow shadow */
    box-shadow: 0 0 100px rgba(255, 255, 255, 0.15);
    text-align: left;
    /* Card now acts as textarea container */
    position: relative;
    min-height: 212px;
    display: flex;
    flex-direction: column;
    cursor: text;
}

/* Placeholder text - shows when input is empty */
.feedback-placeholder {
    position: absolute;
    top: var(--spacing-md);
    left: var(--spacing-md);
    font-size: 14px;
    font-weight: 200;
    font-style: italic;
    color: #646464;
    pointer-events: none;
    transition: opacity var(--transition-fast);
}

/* Hide placeholder when user has typed something */
.feedback-placeholder.hidden {
    opacity: 0;
}

/* The editable area - fills the card */
.feedback-input {
    flex: 1;
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 300;
    color: var(--color-off-white);
    line-height: 1.6;
    outline: none;
    min-height: 120px;
    /* Leave space for the submit button at bottom */
    padding-bottom: 50px;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* Empty state cursor indicator */
.feedback-input:empty::after {
    content: '';
}

/* Submit Button - positioned at bottom right of the card */
.submit-btn {
    position: absolute;
    bottom: var(--spacing-md);
    right: var(--spacing-md);
    background-color: var(--color-black);
    color: var(--color-off-white);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 200;
    padding: 7px 24px;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    /* Gradient border for button */
    background-image:
        linear-gradient(var(--color-black), var(--color-black)),
        linear-gradient(180deg, #3d3d3d 0%, #525252 100%);
    background-origin: border-box;
    background-clip: padding-box, border-box;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.submit-btn:hover {
    background-image:
        linear-gradient(#111, #111),
        linear-gradient(180deg, #4d4d4d 0%, #626262 100%);
    transform: translateY(-1px);
}

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

.submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    background-color: var(--color-dark-gray);
    padding: 8px var(--spacing-md);
    margin-top: auto;
    
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px; /* Reduce gap between stacked items on mobile */
}

.footer-links {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.footer-link {
    color: var(--color-medium-gray);
    text-decoration: none;
    font-size: 14px;
    font-weight: 300;
    transition: color var(--transition-fast);
}

.footer-link:hover {
    color: var(--color-off-white);
}

.footer-divider {
    color: var(--color-medium-gray);
    font-size: 14px;
}

.footer-contact {
    font-size: 14px;
    font-weight: 200;
    color: var(--color-medium-gray);
}

.email-link {
    color: var(--color-medium-gray);
    text-decoration: underline;
    transition: color var(--transition-fast);
}

.email-link:hover {
    color: var(--color-off-white);
}

/* ============================================
   Success Modal
   ============================================ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: var(--color-dark-gray);
    border-radius: var(--radius-md);
    padding: var(--spacing-lg);
    text-align: center;
    max-width: 320px;
    width: 90%;
    transform: scale(0.9);
    transition: transform var(--transition-normal);
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-content h3 {
    font-size: 20px;
    font-weight: 600;
    margin-top: var(--spacing-sm);
    margin-bottom: var(--spacing-xs);
}

.modal-content p {
    color: #888;
    font-size: 14px;
    margin-bottom: var(--spacing-md);
}

.modal-close-btn {
    background-color: var(--color-accent-green);
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    padding: 10px 30px;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.modal-close-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* Success Checkmark Animation */
.success-checkmark svg {
    width: 56px;
    height: 56px;
}

.checkmark-circle {
    stroke: var(--color-accent-green);
    stroke-width: 2;
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    animation: strokeCircle 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark-check {
    stroke: var(--color-accent-green);
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: strokeCheck 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

@keyframes strokeCircle {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes strokeCheck {
    100% {
        stroke-dashoffset: 0;
    }
}

/* ============================================
   Responsive Design
   ============================================ */
@media (max-width: 768px) {
    .main-content {
        /* Keep top padding for fixed banner */
        padding: calc(var(--spacing-md) + 29px) var(--spacing-sm) var(--spacing-md);
    }

    /* Reduce spacing proportionally on tablet */
    .logo {
        margin-bottom: 50px;
    }

    .hero {
        margin-bottom: 60px;
    }

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

    .cta-button-wrapper {
        margin-top: 30px;
    }

    .feedback-section {
        max-width: 100%;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 3px;
    }

    .footer-links {
        order: 2;
    }

    .footer-contact {
        order: 1;
    }
}

@media (max-width: 480px) {
    .main-content {
        /* Extra top padding on small screens for fixed banner */
        padding: calc(var(--spacing-sm) + 35px) var(--spacing-sm) var(--spacing-sm);
    }

    .top-banner {
        padding: 6px var(--spacing-sm);
    }

    .banner-text {
        font-size: 12px;
    }

    /* Reduce spacing even more on mobile */
    .logo {
        margin-bottom: 35px;
    }

    .hero {
        margin-bottom: 40px;
    }

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

    .cta-button-wrapper {
        margin-top: 25px;
    }

    .feedback-heading {
        font-size: 16px;
    }

    .feedback-card {
        padding: var(--spacing-sm);
    }
}
