* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

:root {
    /* HSL color definitions matching original */
    --primary: 262, 83%, 58%;
    --primary-foreground: 0, 0%, 100%;
    --accent: 195, 100%, 65%;
    --muted: 210, 40%, 96.1%;
    --muted-foreground: 215.4, 16.3%, 46.9%;
    --destructive: 0, 84.2%, 60.2%;
    --border: 214.3, 31.8%, 91.4%;
    --foreground: 222.2, 84%, 4.9%;
}

body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, hsl(262, 83%, 58%) 0%, hsl(280, 100%, 70%) 50%, hsl(195, 100%, 65%) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    color: hsl(var(--foreground));
}

.container {
    width: 100%;
    max-width: 672px;
    margin: 0 auto;
}

.card {
    background: white;
    border-radius: 1rem;
    box-shadow: 0 25px 50px -12px hsla(var(--primary), 0.25);
    overflow: hidden;
}

.card-content {
    padding: 2rem;
}

/* Header Section */
.header {
    text-align: center;
    margin-bottom: 2rem;
}

.title {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2.5rem;
    line-height: 1;
}

.title-line-1 {
    font-size: clamp(2rem, 6vw, 3.75rem);
    font-weight: 700;
    background: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(var(--accent)) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    margin-bottom: 0.35rem;
    animation: slideInFromLeft 0.8s ease-out;
}

.title-line-2 {
    font-size: clamp(2.5rem, 9vw, 5rem);
    font-weight: 900;
    background: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(var(--accent)) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    letter-spacing: 0.02em;
    animation: slideInFromRight 0.8s ease-out;
}

@keyframes slideInFromLeft {
    0% {
        opacity: 0;
        transform: translateX(-30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInFromRight {
    0% {
        opacity: 0;
        transform: translateX(30px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

.value-prop {
    background: linear-gradient(135deg, hsla(var(--primary), 0.1) 0%, hsla(var(--accent), 0.1) 100%);
    padding: 1rem;
    border-radius: 0.5rem;
    border-left: 4px solid hsl(var(--primary));
    position: relative;
    overflow: hidden;
}

.value-prop::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        45deg,
        hsla(var(--primary), 0.1) 25%,
        transparent 25%,
        transparent 50%,
        hsla(var(--primary), 0.1) 50%,
        hsla(var(--primary), 0.1) 75%,
        transparent 75%,
        transparent
    );
    background-size: 40px 40px;
    animation: barber-stripes 2s linear infinite;
}

@keyframes barber-stripes {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 40px 0;
    }
}

.value-prop-content {
    background: rgba(255, 255, 255, 0.9);
    padding: 0.75rem;
    border-radius: 0.25rem;
    position: relative;
    z-index: 1;
}

.highlight {
    font-weight: 600;
    color: hsl(var(--primary));
}

/* Section */
.section {
    margin: 2rem 0;
}

.section-title {
    font-size: clamp(1.25rem, 3vw, 1.5rem);
    font-weight: 600;
    text-align: center;
    margin-bottom: 1.5rem;
    color: hsl(var(--foreground));
}

/* Packages */
.packages {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.package {
    border: 1px solid hsl(var(--border));
    border-radius: 0.5rem;
    transition: background 0.4s ease-out, border-color 0.4s ease-out, box-shadow 0.4s ease-out;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.package.selected {
    background: hsla(var(--primary), 0.05);
    border-color: hsl(var(--primary));
    box-shadow: 0 4px 6px -1px hsla(var(--primary), 0.1), 0 0 0 1px hsla(var(--primary), 0.2);
    transition: background 0.6s ease-out, border-color 0.6s ease-out, box-shadow 0.6s ease-out;
}

.package-header {
    display: flex;
    align-items: flex-start;
    padding: 1rem;
    gap: 0.75rem;
}

.checkbox-wrapper {
    flex-shrink: 0;
    padding-top: 0.125rem;
}

.checkbox {
    width: 1.25rem;
    height: 1.25rem;
    cursor: pointer;
    accent-color: hsl(var(--primary));
    transition: transform 0.2s ease-out;
}

.checkbox:checked {
    transform: scale(1.05);
}

.package-label {
    flex: 1;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.package-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    outline: none;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.info-btn:focus {
    outline: none;
}

.info-btn:active {
    transform: scale(0.95);
}

.info-icon {
    width: 16px;
    height: 16px;
    color: hsl(var(--primary));
    opacity: 0.7;
    transition: all 0.2s ease;
}

.info-btn:hover .info-icon {
    opacity: 1;
    transform: scale(1.1);
}

.production-note {
    display: block;
    margin-top: 0.25rem;
    font-size: clamp(0.7rem, 2vw, 0.875rem);
    color: hsl(var(--muted-foreground));
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease-out, opacity 0.2s ease-out, margin 0.2s ease-out;
    user-select: none;
    -webkit-user-select: none;
}

.production-note.show {
    max-height: 2rem;
    opacity: 1;
    margin-top: 0.5rem;
    transition: max-height 0.6s ease-out, opacity 0.4s ease-out, margin 0.4s ease-out;
}

@keyframes fade-in {
    0% {
        opacity: 0;
        transform: translateY(-5px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.package-price {
    font-weight: 600;
    font-size: clamp(0.875rem, 2vw, 1rem);
    color: hsl(var(--muted-foreground));
    transition: color 0.4s ease-out;
    min-width: clamp(60px, 15vw, 80px);
    text-align: right;
    user-select: none;
    -webkit-user-select: none;
}

.package.selected .package-price {
    color: hsl(var(--primary));
}

/* Package Options */
.package-option {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.2s ease-out, opacity 0.15s ease-out, padding 0.15s ease-out;
}

.package-option.show {
    max-height: 200px;
    padding: 0 1rem 1rem;
    opacity: 1;
    transition: max-height 0.8s ease-out, opacity 0.6s ease-out, padding 0.6s ease-out;
}

/* Faster animations for instruction package */
#instruction-option:not(.show) {
    transition: max-height 0.15s ease-out, opacity 0.1s ease-out, padding 0.1s ease-out;
}

#instruction-option.show {
    transition: max-height 0.4s ease-out, opacity 0.2s ease-out, padding 0.2s ease-out;
}

.option-content {
    background: hsla(var(--muted), 0.1);
    padding: clamp(0.5rem, 2vw, 0.75rem);
    border-radius: 0.5rem;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.option-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.option-label {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: clamp(0.75rem, 2vw, 0.875rem);
    margin-left: 0.5rem;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.option-label .info-btn {
    margin-left: 0.25rem;
}

.option-price {
    font-weight: 600;
    font-size: clamp(0.875rem, 2vw, 1rem);
    color: hsl(var(--muted-foreground));
    transition: color 0.4s ease-out;
}

#help-setup:checked ~ .option-price {
    color: hsl(var(--primary));
}

/* Slider */
.slider-container {
    background: hsla(var(--muted), 0.1);
    padding: clamp(0.75rem, 2vw, 1rem);
    border-radius: 0.5rem;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.slider-label {
    display: block;
    font-size: clamp(0.75rem, 2vw, 0.875rem);
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.slider {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: hsl(var(--border));
    outline: none;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    -webkit-appearance: none;
}

.slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: clamp(16px, 4vw, 20px);
    height: clamp(16px, 4vw, 20px);
    border-radius: 50%;
    background: hsl(var(--primary));
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 2px 4px hsla(var(--primary), 0.3);
}

.slider::-moz-range-thumb {
    width: clamp(16px, 4vw, 20px);
    height: clamp(16px, 4vw, 20px);
    border-radius: 50%;
    background: hsl(var(--primary));
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 2px 4px hsla(var(--primary), 0.3);
    border: 0;
}

.slider:hover::-webkit-slider-thumb {
    transform: scale(1.1);
    box-shadow: 0 3px 6px hsla(var(--primary), 0.4);
}

.slider:hover::-moz-range-thumb {
    transform: scale(1.1);
    box-shadow: 0 3px 6px hsla(var(--primary), 0.4);
}

/* Action Buttons Section */
.action-buttons-section {
    margin: 2rem 0;
    padding-top: 1.5rem;
    border-top: 1px solid hsl(var(--border));
}

.buttons-container {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.action-button {
    flex: 1;
    min-width: 280px;
    max-width: 380px;
    padding: clamp(1rem, 2.5vw, 1.25rem) clamp(1.25rem, 2.5vw, 1.5rem);
    border: none;
    border-radius: 0.75rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px hsla(0, 0%, 0%, 0.1);
}

.btn-layout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    gap: 1rem;
}

.support-btn {
    background: #0088cc;
}

.support-btn:hover {
    background: #0077b5;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px hsla(200, 100%, 40%, 0.3);
}

.purchase-btn {
    background: hsl(var(--primary));
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.purchase-btn:not(:disabled) {
    animation: activatePurchase 0.8s ease-out;
}

@keyframes activatePurchase {
    0% {
        background: hsl(var(--muted-foreground));
    }
    100% {
        background: hsl(var(--primary));
    }
}

.purchase-btn:hover:not(:disabled) {
    background: hsl(262, 83%, 53%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px hsla(var(--primary), 0.3);
}

.purchase-btn:disabled {
    background: hsl(var(--muted-foreground));
    opacity: 0.6;
    cursor: not-allowed;
}

.purchase-btn:disabled .purchase-price {
    background: rgba(255, 255, 255, 0.1);
}

.btn-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.btn-label {
    font-size: clamp(1.125rem, 2.5vw, 1.25rem);
}

.btn-center-content {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
}

.support-btn .btn-label {
    text-align: center;
    flex: 1;
}

.btn-price-placeholder {
    width: 24px;
    visibility: hidden;
}

.purchase-price {
    font-size: clamp(1.125rem, 2.5vw, 1.25rem);
    font-weight: 700;
    transition: transform 0.3s ease;
    white-space: nowrap;
    background: rgba(255, 255, 255, 0.15);
    padding: 0.125rem 0.5rem;
    border-radius: 0.25rem;
}

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

.contact-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.contact-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: white;
    border: 2px solid hsl(var(--border));
    border-radius: 0.5rem;
    color: hsl(var(--muted-foreground));
    font-size: clamp(0.875rem, 2vw, 1rem);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    user-select: none;
}

.contact-tab svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.contact-tab.active {
    background: hsla(var(--primary), 0.05);
    border-color: hsl(var(--primary));
    color: hsl(var(--primary));
}

.contact-tab:hover:not(.active) {
    background: hsla(var(--muted), 0.1);
}

.contact-forms {
    position: relative;
    min-height: 80px;
}

.contact-form-item {
    display: none;
}

.contact-form-item.active {
    display: block;
}

.contact-form-item.animate {
    animation: fadeIn 0.3s ease;
}

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

.input-group {
    display: flex;
    align-items: stretch;
    background: white;
    border: 2px solid hsl(var(--border));
    border-radius: 0.5rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.input-group:focus-within {
    border-color: hsl(var(--primary));
    box-shadow: 0 0 0 3px hsla(var(--primary), 0.1);
}

.input-prefix {
    display: flex;
    align-items: center;
    padding: 0 0.75rem;
    background: hsla(var(--muted), 0.1);
    border-right: 2px solid hsl(var(--border));
    color: hsl(var(--muted-foreground));
    font-weight: 500;
    font-size: clamp(0.875rem, 2.5vw, 1rem);
}

.contact-input {
    flex: 1;
    padding: clamp(0.625rem, 2vw, 0.75rem) clamp(0.75rem, 2vw, 1rem);
    border: none;
    background: transparent;
    font-size: clamp(0.875rem, 2.5vw, 1rem);
    outline: none;
}

.contact-input.full {
    width: 100%;
}

.contact-input::placeholder {
    color: hsl(var(--muted-foreground));
    opacity: 0.5;
}


.error-message {
    display: none;
    font-size: clamp(0.7rem, 2vw, 0.75rem);
    color: hsl(var(--destructive));
    margin-top: 0.25rem;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.error-message.show {
    display: block;
    opacity: 1;
    animation: fade-in 0.4s ease-out;
}

.contact-hint {
    text-align: center;
    margin-bottom: 0.5rem;
}


.validation-error {
    text-align: center;
    color: hsl(var(--destructive));
    font-size: clamp(0.75rem, 2vw, 0.875rem);
    font-weight: 500;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.validation-error.show {
    max-height: 2rem;
    opacity: 1;
    margin-top: 0.5rem;
    animation: slide-down 0.6s ease-out;
}

@keyframes slide-down {
    0% {
        opacity: 0;
        transform: translateY(-5px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Add pulse animation when price changes */
@keyframes priceUpdate {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 1.25rem;
    padding: 1.75rem;
    max-width: 380px;
    width: 90%;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: modalSlideIn 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

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

.modal-header {
    margin-bottom: 1.25rem;
}

.modal-title {
    text-align: center;
}

.modal-service-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: hsl(var(--primary));
    margin-bottom: 0.5rem;
}

.modal-subtitle {
    font-size: 0.9rem;
    font-weight: 500;
    color: hsl(var(--muted-foreground));
}

.modal-body {
    margin-bottom: 1.25rem;
}

.modal-chat-container {
    background: hsla(var(--muted), 0.3);
    border-radius: 0.75rem;
    padding: 1rem;
    border: 1px solid hsl(var(--border));
}

.modal-chat-message {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem;
    background: white;
    border-radius: 0.5rem;
    margin-bottom: 0.5rem;
    box-shadow: 0 1px 3px hsla(0, 0%, 0%, 0.05);
    transition: transform 0.2s ease;
}

.modal-chat-message:hover {
    transform: translateX(3px);
}

.modal-chat-message:last-child {
    margin-bottom: 0;
}

.modal-chat-number {
    width: 24px;
    height: 24px;
    background: hsl(var(--primary));
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    flex-shrink: 0;
}

.modal-chat-text {
    font-size: 0.875rem;
    line-height: 1.6;
    color: hsl(var(--foreground));
    flex: 1;
}

.modal-note {
    margin-top: 1rem;
    padding: 0.75rem;
    background: hsla(var(--accent), 0.1);
    border-left: 3px solid hsl(var(--accent));
    border-radius: 0.25rem;
    font-size: 0.875rem;
    color: hsl(var(--foreground));
    font-style: italic;
}

.modal-footer {
    padding-top: 0;
}

.modal-close {
    width: 100%;
    padding: 0.625rem 1rem;
    background: linear-gradient(135deg, hsl(var(--primary)) 0%, hsl(var(--accent)) 100%);
    color: white;
    border: none;
    border-radius: 0.625rem;
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.modal-close:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 12px -3px hsla(var(--primary), 0.25);
}

/* Mobile First Responsive Design */
@media (max-width: 475px) {
    .card-content {
        padding: 1rem;
    }

    .header {
        margin-bottom: 1.5rem;
    }

    .title {
        margin-bottom: 1.5rem;
    }

    .title-line-1 {
        font-size: 1.625rem;
        margin-bottom: 0.25rem;
    }

    .title-line-2 {
        font-size: 2.25rem;
    }

    .section {
        margin: 1.5rem 0;
    }

    .section-title {
        font-size: 1.125rem;
        margin-bottom: 1rem;
    }

    .packages {
        gap: 0.75rem;
    }

    .package-header {
        padding: 0.75rem;
        gap: 0.5rem;
    }

    .checkbox {
        width: 1rem;
        height: 1rem;
    }

    .package-label {
        font-size: 0.875rem;
    }

    .package-price {
        font-size: 0.875rem;
        min-width: 60px;
    }

    .package-option.show {
        padding: 0 0.75rem 0.75rem;
    }

    .slider-label {
        font-size: 0.75rem;
    }

    .contact-section {
        padding: 1rem;
        margin: 1rem 0;
    }

    .contact-header {
        margin-bottom: 1.25rem;
    }

    .contact-title {
        font-size: 1.125rem;
    }

    .contact-subtitle {
        font-size: 0.75rem;
    }

    .contact-form {
        gap: 1rem;
    }

    .form-label {
        font-size: 0.8rem;
    }

    .form-input {
        font-size: 16px; /* Prevent zoom on iOS */
        padding: 0.625rem 0.75rem;
    }

    .contact-hint p {
        font-size: 0.7rem;
    }

    .validation-error {
        font-size: 0.75rem;
    }

    .action-buttons-section {
        margin: 1rem 0;
        padding-top: 1rem;
    }

    .buttons-container {
        flex-direction: column;
        align-items: stretch;
    }

    .action-button {
        min-width: unset;
        max-width: unset;
        width: 100%;
    }

    .modal-content {
        margin: 1rem;
        padding: 1.25rem;
    }

    .modal-title {
        font-size: 1rem;
    }

    .modal-text {
        font-size: 0.75rem;
    }
}

@media (min-width: 475px) and (max-width: 640px) {
    .card-content {
        padding: 1.5rem;
    }

    .title-line-1 {
        font-size: 2.25rem;
    }

    .title-line-2 {
        font-size: 3rem;
    }

    .section-title {
        font-size: 1.25rem;
    }

    .package-header {
        padding: 0.875rem;
    }

    .form-input {
        padding: 0.625rem 0.875rem;
        font-size: 0.9rem;
    }

    .purchase-btn {
        padding: 0.875rem 1.25rem;
        font-size: 1rem;
    }
}

@media (min-width: 640px) {
    .card-content {
        padding: 2rem;
    }

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

@media (min-width: 768px) {

    .section-title {
        font-size: 1.5rem;
    }

    .contact-title {
        font-size: 1.5rem;
    }
}

/* High DPI screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .card {
        box-shadow: 0 20px 40px -10px hsla(var(--primary), 0.2);
    }
}

/* Animations for mobile */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}