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

:root {
    --purple: #5E00FF;
    --blue: #0086FF;
    --green: #00C853;
    --bg-primary: #F2F2F2;
    --bg-secondary: #FFFFFF;
    --text-primary: #0A0A0A;
    --text-secondary: #666666;
    --text-tertiary: #999999;
    --border: #E5E5E5;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Background Canvas */
#gradient-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

/* Navigation */
.nav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
}

.nav-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.125rem;
    color: var(--text-primary);
}

.back-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: color 0.2s ease;
}

.back-link:hover {
    color: var(--purple);
}

/* Contact Container */
.contact-container {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem 2rem;
    z-index: 10;
}

.contact-card {
    position: relative;
    width: 100%;
    max-width: 680px;
    padding: 3rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    z-index: 20;
}

/* Contact Header */
.contact-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.contact-header h1 {
    font-size: 2.25rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
}

.contact-header p {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
    max-width: 500px;
    margin: 0 auto;
}

/* Contact Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.875rem 1rem;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 0.9375rem;
    font-family: inherit;
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-tertiary);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--purple);
    background: var(--bg-secondary);
    box-shadow: 0 0 0 3px rgba(94, 0, 255, 0.1);
}

.form-group select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%23666666' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Submit Button */
.btn-primary {
    width: 100%;
    padding: 0.875rem;
    background: linear-gradient(135deg, var(--purple), var(--blue));
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 0.5rem;
    box-shadow: 0 4px 12px rgba(94, 0, 255, 0.2);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(94, 0, 255, 0.3);
}

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

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Contact Info */
.contact-info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    padding-top: 2.5rem;
    border-top: 1px solid var(--border);
}

.info-item {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
}

.info-item svg {
    flex-shrink: 0;
    color: var(--purple);
    margin-top: 0.125rem;
}

.info-item h3 {
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.info-item p {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* Success Message */
.success-message {
    display: none;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(0, 200, 83, 0.1), rgba(0, 200, 83, 0.05));
    border: 1px solid var(--green);
    border-radius: 12px;
    margin-top: 1.5rem;
    align-items: flex-start;
    gap: 1rem;
}

.success-message.show {
    display: flex;
    animation: slideIn 0.4s ease-out;
}

.success-message svg {
    flex-shrink: 0;
    color: var(--green);
    stroke-width: 2.5;
}

.success-message h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--green);
    margin-bottom: 0.25rem;
}

.success-message p {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

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

/* Floating Shapes */
.floating-shape {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
}

.shape-1 {
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, rgba(94, 0, 255, 0.15), transparent);
    top: 10%;
    left: 5%;
    animation: float 8s ease-in-out infinite;
}

.shape-2 {
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, rgba(0, 134, 255, 0.12), transparent);
    bottom: 15%;
    right: 10%;
    animation: float 10s ease-in-out infinite;
    animation-delay: 2s;
}

.shape-3 {
    width: 180px;
    height: 180px;
    background: linear-gradient(135deg, rgba(94, 0, 255, 0.1), transparent);
    top: 50%;
    right: 5%;
    animation: float 9s ease-in-out infinite;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(180deg);
    }
}

/* Loading State */
.btn-primary.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.btn-primary.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Responsive */
@media (max-width: 768px) {
    .contact-container {
        padding: 5rem 1rem 1rem;
    }

    .contact-card {
        padding: 2rem;
        max-width: 100%;
    }

    .contact-header h1 {
        font-size: 1.875rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .contact-info {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .floating-shape {
        display: none;
    }
}

@media (max-width: 480px) {
    .contact-header h1 {
        font-size: 1.5rem;
    }

    .contact-header p {
        font-size: 0.9375rem;
    }

    .contact-card {
        padding: 1.5rem;
    }
}