* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    max-width: 100%;
    overflow-x: hidden;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.navbar {
    padding-block: 15px;
}

.header {
    display: flex;
    justify-content: space-between;
    padding-block: 20px;
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.header a {
    color: black;
    text-decoration: none;
    font-size: 25px;
    font-weight: bold;
}

.banner-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* Language dropdown */
.header-lang {
    position: absolute;
    right: 60px;
    top: 18px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .35);
}

.header-lang select {
    appearance: none;
    background: #fff;
    color: #111;
    border: 1px solid #ffffffaa;
    border-radius: 999px;
    padding: 6px 12px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}

.form-area {
    padding-block: 50px;
    background: #f8f9fa;
}

.content-container {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    padding: 30px;
    min-height: 400px;
    max-width: 82%;
    margin: 20px auto;
}

.option-btn {
    transition: all 0.3s ease;
    margin: 5px;
    cursor: pointer;
    position: relative;
    border: none;
    border-radius: 8px;
}

.option-btn.active {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    background-color: #2BA72B !important;
    color: white !important;
}

.option-btn.incomplete {
    background-color: #BFFFBF !important;
    color: black !important;
}

.option-btn.complete {
    background-color: #2BA72B !important;
    color: white !important;
}

.content-section {
    display: none;
    animation: fadeIn 0.5s ease;
}

.content-section.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.icon {
    font-size: 24px;
    margin-bottom: 10px;
}

.option-title {
    font-weight: 600;
    margin-bottom: 5px;
}

.contact-section {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    margin: 2rem auto;
    max-width: 1000px;
}

.section-header {
    padding: 1.5rem 2rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e9ecef;
}

.section-header h2 {
    margin: 0;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: none !important;
}

.form-container {
    padding: 0 2rem 2rem;
}

.form-section {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.form-section:last-of-type {
    border-bottom: none;
}

.section-title {
    font-weight: 600;
    margin-bottom: 1.2rem;
    padding-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #2c3e50;
    border-bottom: 2px solid #2BA72B;
}

.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 0.5rem;
}

.form-control,
.form-select {
    border-radius: 6px;
    padding: 12px 15px;
    transition: all 0.3s;
    background-color: #ffffff;
    border: 2px solid #e9ecef;
    font-size: 16px;
    /* Better for mobile */
}

.form-control:focus,
.form-select:focus {
    background-color: #fff;
    border-color: #2BA72B;
    box-shadow: 0 0 0 0.2rem rgba(43, 167, 43, 0.25);
    outline: none;
}

.form-hint {
    font-size: 0.875rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 0.75rem;
}

.form-check {
    margin-bottom: 0.5rem;
    padding-left: 2.5rem;
}

.form-check-input {
    margin-left: -2.5rem;
    width: 1.2rem;
    height: 1.2rem;
    margin-top: 0.2rem;
    background-color: #f8f9fa;
    border: 2px solid #dee2e6;
}

.form-check-input:checked {
    background-color: #2BA72B;
    border-color: #2BA72B;
}

.form-check-label {
    cursor: pointer;
    padding-left: 0.5rem;
    user-select: none;
}

.dimensions-input {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.dimensions-input .form-control {
    flex: 1;
    min-width: 150px;
}

.btn-primary {
    background-color: #2BA72B;
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.3s;
    color: white;
    font-size: 16px;
}

.btn-primary:hover {
    background-color: #248f24;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-secondary {
    background-color: #6c757d;
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.3s;
    color: white;
}

.btn-secondary:hover {
    background-color: #5a6268;
    transform: translateY(-2px);
}

.btn-success {
    background-color: #28a745;
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.3s;
    color: white;
}

.btn-success:hover {
    background-color: #218838;
    transform: translateY(-2px);
}

.btnbar {
    display: flex;
    justify-content: space-between;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e9ecef;
}

.hidden {
    display: none !important;
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Progress bar */
.progress {
    height: 8px;
    max-width: 82%;
    margin: 40px auto 0;
    background-color: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    background-color: #2BA72B;
    transition: width 0.3s ease;
}

/* Enhanced validation styles */
.form-label.required::after {
    content: " *";
    color: #dc3545;
}

.validation-error {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: none;
}

.validation-error.show {
    display: block;
}

.is-invalid {
    border-color: #dc3545 !important;
    background-color: #fff8f8 !important;
}

.field-error {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

/* Step validation state */
.tab-item.error {
    background-color: #f8d7da !important;
    color: #721c24 !important;
}

/* Global error message */
.global-validation-message {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1060;
    min-width: 300px;
    animation: slideInRight 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Error summary for review step */
.error-summary {
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.error-summary h4 {
    color: #721c24;
    margin-bottom: 10px;
}

.error-summary ul {
    margin: 0;
    padding-left: 20px;
}

.error-summary li {
    margin-bottom: 5px;
    cursor: pointer;
}

.error-summary li:hover {
    text-decoration: underline;
    color: #dc3545;
}

/* Toggle buttons */
.toggle {
    display: flex;
    border-radius: 6px;
    overflow: hidden;
    border: 2px solid #e9ecef;
    background: #f8f9fa;
}

.toggle-btn {
    flex: 1;
    padding: 12px;
    border: none;
    background-color: #f8f9fa;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
}

.toggle-btn.active {
    background-color: #2BA72B;
    color: white;
}

.toggle-btn:hover:not(.active) {
    background-color: #e9ecef;
}

/* Pill buttons */
.pill,
.pill-approval {
    border: 2px solid #dee2e6;
    padding: 12px 20px;
    border-radius: 25px;
    cursor: pointer;
    background: #f8f9fa;
    transition: all 0.3s;
    user-select: none;
    text-align: center;
}

.pill-approval {
    padding: 8px 16px;
    border-radius: 20px;
}

.pill:hover,
.pill-approval:hover {
    border-color: #2BA72B;
    background-color: #e8f5e8;
}

.pill:focus,
.pill-approval:focus {
    outline: none;
    border-color: #000;
}

/* File input styling */
.form-control[type="file"] {
    padding: 8px;
    background: white;
}

/* Multi-select styling */
.form-control[multiple] {
    height: auto;
    min-height: 150px;
    padding: 10px;
}

/* Review section */
.review-summary {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.review-summary h4 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.review-item {
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e9ecef;
}

.review-item:last-child {
    border-bottom: none;
}

/* Remove green underline from all headings */
h1,
h2,
h3,
h4,
h5,
h6 {
    border-bottom: none !important;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
    .content-container {
        max-width: 90%;
        padding: 25px;
    }

    .progress {
        max-width: 90%;
    }
}

@media (max-width: 768px) {
    .header-lang {
        position: static;
        justify-content: flex-end;
        margin-top: 10px;
        color: #000;
        text-shadow: none;
    }

    .content-container {
        max-width: 95%;
        padding: 20px;
        margin: 10px auto;
    }

    .progress {
        max-width: 95%;
        margin: 20px auto 0;
    }

    .form-container {
        padding: 0 1rem 1.5rem;
    }

    .section-header {
        padding: 1.25rem 1.5rem;
    }

    .checkbox-grid {
        grid-template-columns: 1fr;
    }

    .dimensions-input {
        flex-direction: column;
        gap: 0.75rem;
    }

    .dimensions-input .form-control {
        min-width: 100%;
    }

    .btnbar {
        flex-direction: column-reverse;
        gap: 10px;
    }

    .btnbar .btn {
        min-width: 100%;
        text-align: center;
    }

    .toggle {
        flex-direction: column;
    }

    .pill,
    .pill-approval {
        padding: 10px 15px;
        font-size: 14px;
    }

    .option-btn {
        margin: 3px;
        padding: 15px 10px !important;
    }

    .option-title {
        font-size: 14px;
    }
}

@media (max-width: 576px) {
    .header {
        flex-direction: column;
        text-align: center;
        padding: 15px;
    }

    .header a {
        font-size: 20px;
    }

    .form-area {
        padding-block: 30px;
    }

    .content-container {
        padding: 15px;
    }

    .section-header h2 {
        font-size: 1.5rem;
    }

    .section-title {
        font-size: 1.2rem;
    }

    .form-control,
    .form-select {
        padding: 10px 12px;
        font-size: 16px;
        /* Prevents zoom on iOS */
    }

    .row.g-3 {
        margin: 0 -8px;
    }

    .row.g-3>[class*="col-"] {
        padding: 0 8px;
    }
}

/* Print styles */
@media print {

    .header-lang,
    .btnbar,
    .progress {
        display: none !important;
    }

    .content-container {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .btn-primary {
        border: 2px solid currentColor;
    }

    .toggle {
        border: 2px solid currentColor;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .option-btn,
    .btn-primary,
    .btn-secondary,
    .btn-success {
        transition: none;
    }
}

/* Fix for duplicate headings */
.content-section .section-header+.form-container .form-section:first-child .section-title {
    display: none !important;
}

/* Green border for current step button */
.option-btn.active {
    border: 3px solid #2BA72B !important;
}

/* Ensure proper scrolling */
.form-area {
    scroll-margin-top: 20px;
}

/* Remove units from review display */
.review-summary .review-item br+strong:contains("Units") {
    display: none;
}

/* Landing Page Styles */
.landing-page {
    min-height: 100vh;
    background: #f8f9fa;
}

.landing-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: bold;
    color: #2BA72B;
}

.landing-hero {
    background-image: url(images/KIT\ HOME\ CONFIGURATOR\ header.jpg);
    background-repeat: no-repeat;
    background-position: center;
    background-size: 90% 70%;
    min-height: 100vh;
    position: relative;
    display: flex;
    flex-direction: column;
}

.landing-header {
    background: transparent;
    padding: 15px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.hero-content {
    margin-top: auto;
    margin-bottom: 70px;
    /* This positions buttons 50px from bottom */
    text-align: center;
    padding: 0 20px;
    width: 100%;
}

.btn-start-about {
    padding: 15px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    background: white;
    border: none;
    transition: all 0.3s ease;
    color: black;
    cursor: pointer;
    display: inline-block;
}

.btn-start-about:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(43, 167, 43, 0.3);
    background: #f8f9fa;
    color: black;
    /* Slight background change on hover */
}

.btn-start {
    padding: 15px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    background: #2BA72B;
    border: none;
    transition: all 0.3s ease;
    color: white;
    /* Added text color */
    cursor: pointer;
    display: inline-block;
    /* Ensure proper display */
}

.btn-start:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(43, 167, 43, 0.3);
    background: #248f24;
    /* Darker green on hover */
}

/* Ensure container takes full height */
.landing-hero .container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    flex-grow: 1;
}

/* Form Header */
.form-header {
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 15px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    color: #2BA72B;
}

/* Tab Styles */
.form-tabs {
    margin: 30px 0;
}

.tab-nav {
    display: flex;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 5px;
    flex-wrap: wrap;
    justify-content: center;
    min-width: 100%;
}

.tab-item {
    width: 180px;

    text-align: center;
    padding: 12px 15px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s ease;
    margin: 2px;
}

.tab-item.active {
    background: #2BA72B;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(43, 167, 43, 0.3);
}

.tab-item.complete {
    background: #2BA72B;
    color: white;
}

.tab-item.incomplete {
    background: #BFFFBF;
    color: #333;
}

.tab-title {
    font-weight: 600;
    font-size: 14px;
}

/* Field Completion States */
.form-control.field-complete {
    border-color: #2BA72B;
    background-color: #f8fff8;
}

.form-control.field-incomplete {
    border-color: #dc3545;
    background-color: #fff8f8;
}

.form-control.field-untouched {
    border-color: #dee2e6;
    background-color: #ffffff;
}

/* About Overlay */
.about-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.about-content {
    background: white;
    padding: 30px;
    border-radius: 10px;
    max-width: 500px;
    width: 90%;
    position: relative;
}

.btn-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Responsive Design */
@media (max-width: 768px) {
    .landing-hero {
        background-size: 200% 100%;
        background-position: center;
    }

    .hero-content {
        margin-bottom: 30px;
    }

    .btn-start-about,
    .btn-start {
        padding: 12px 30px;
        font-size: 1.1rem;
        display: block;
        /* Stack buttons on mobile */
        width: 100%;

        margin: 10px auto;
        /* Center and space stacked buttons */
    }

    .tab-item {
        max-width: 120px;
        margin: 1px 0;
    }

    .landing-logo span {
        display: none;
    }
}

/* Validation Message */
.validation-message {
    font-size: 0.875rem;
    color: #dc3545;
    margin-top: 0.25rem;
    display: none;
}

.validation-message.show {
    display: block;
}

/* Make all fields look normal by default */
.form-control {
    border-color: #dee2e6;
    background-color: #ffffff;
}

/* Only show green border for completed fields */
.form-control.field-complete {
    border-color: #2BA72B !important;
    border-width: 2px;
}

/* Make untouched fields look completely normal */
.form-control.field-untouched {
    border-color: #dee2e6 !important;
    background-color: #ffffff !important;
}

/* Red borders only applied during validation by is-invalid class */
.form-control.is-invalid {
    border-color: #dc3545 !important;
    background-color: #fff8f8 !important;
}

.bi-arrow-repeat.spin {
    animation: spin 1s linear infinite;
    display: inline-block;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Small mobile optimization */
@media (max-width: 480px) {
    .tab-item {
        min-width: 100px;
        max-width: 140px;
        padding: 8px 10px;
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 5px;
    }

    .tab-title {
        font-size: 12px;
    }
}

/* Enhanced responsive design */
@media (max-width: 768px) {
    .content-container {
        max-width: 100%;
        padding: 15px 10px;
        margin: 10px auto;
    }

    .form-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        /* Smooth scrolling on iOS */
    }

    .tab-nav {
        display: flex;
        flex-wrap: nowrap;
        width: max-content;
        /* Allow natural width based on content */
        min-width: 100%;
        /* Ensure it takes at least full width */
        padding: 5px 10px;
        gap: 5px;
        /* Space between tabs */
    }

    .tab-item {
        flex: 0 0 auto;
        /* Don't grow or shrink, base on content */
        min-width: 120px;
        /* Minimum tab width */
        max-width: 180px;
        /* Maximum tab width */
        padding: 10px 12px;
        display: flex;
        justify-content: center;
        align-items: center;
        gap: 5px;
    }

    .tab-title {
        font-size: 13px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Hide scrollbar but keep functionality */
    .form-tabs::-webkit-scrollbar {
        height: 4px;
    }

    .form-tabs::-webkit-scrollbar-track {
        background: #f1f1f1;
        border-radius: 10px;
    }

    .form-tabs::-webkit-scrollbar-thumb {
        background: #c1c1c1;
        border-radius: 10px;
    }

    .form-tabs::-webkit-scrollbar-thumb:hover {
        background: #a8a8a8;
    }
}

/* Hover effects */
.tab-item:hover:not(.active) {
    background: #e9ecef;
    transform: translateY(-1px);
}

/* Active state enhancements */
.tab-item.active {
    box-shadow: 0 2px 8px rgba(43, 167, 43, 0.3);
}


.form-tabs .tab-item {
    min-width: 120px;
    flex-shrink: 1;
}


.btnbar .btn {
    max-width: 100%;
    margin: 2px 0;
}

@media (max-width: 576px) {

    .hero-content .btn-start {
        display: block;
        width: 100%;
        margin: 10px 0 !important;
    }

    .checkbox-grid {
        grid-template-columns: 1fr;
    }

    .dimensions-input {
        flex-direction: column;
    }
}

/* File upload feedback */
.file-upload-feedback {
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

.file-upload-feedback.show {
    display: block !important;
}

/* Loading states */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Improved modal responsiveness */
.modal-dialog {
    max-width: 95%;
    margin: 1.75rem auto;
}

@media (max-width: 576px) {
    .modal-dialog {
        margin: 0.5rem;
    }
}

/* Enhanced form validation */
.is-invalid {
    border-color: #dc3545 !important;
    background-color: #fff8f8;
}

.validation-error.show {
    display: block;
}

/* Success states */
.is-valid {
    border-color: #198754 !important;
    background-color: #f8fff8;
}

/* Resubmission styling */
.resubmission-badge {
    background-color: #ffc107;
    color: #000;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: bold;
}

/* Optimize images */
img {
    max-width: 100%;
    height: auto;
}

/* Reduce animations for performance */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Print styles */
@media print {

    .btnbar,
    .form-tabs,
    .landing-page {
        display: none !important;
    }

    .main-body {
        display: block !important;
    }
}

/* Enhanced Success Modal */
#successModal .modal-dialog {
    max-width: 500px;
    margin: 1.75rem auto;
}

#successModal .modal-content {
    border-radius: 15px;
    border: none;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

#successModal .modal-header {
    background: linear-gradient(135deg, #2BA72B, #248f24);
    border-bottom: none;
    padding: 25px 30px;
    position: relative;
}

#successModal .modal-title {
    font-size: 24px;
    font-weight: 700;
    color: white;
    text-align: center;
    width: 100%;
}

#successModal .btn-close {
    position: absolute;
    right: 20px;
    top: 20px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    opacity: 1;
    padding: 8px;
}

#successModal .btn-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

#successModal .modal-body {
    padding: 40px 30px;
    text-align: center;
}

#successModal .modal-body i {
    font-size: 4rem;
    color: #2BA72B;
    margin-bottom: 20px;
    display: block;
}

#successModal .modal-body h4 {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 20px;
    font-size: 22px;
}

#successModal .modal-body p {
    color: #666;
    line-height: 1.6;
    font-size: 16px;
    margin-bottom: 0;
}

#successModal .modal-footer {
    border-top: 1px solid #e9ecef;
    padding: 25px 30px;
    display: flex;
    gap: 10px;
    justify-content: center;
}

#successModal .modal-footer .btn {
    padding: 12px 30px;
    border-radius: 8px;
    font-weight: 600;
    min-width: 140px;
}

#successModal .modal-footer .btn-secondary {
    background: #6c757d;
    border: none;
}

#successModal .modal-footer .btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
}

#successModal .modal-footer .btn-primary {
    background: #2BA72B;
    border: none;
}

#successModal .modal-footer .btn-primary:hover {
    background: #248f24;
    transform: translateY(-2px);
}

/* Responsive modal */
@media (max-width: 576px) {
    #successModal .modal-dialog {
        margin: 10px;
        max-width: calc(100% - 20px);
    }

    #successModal .modal-body {
        padding: 30px 20px;
    }

    #successModal .modal-footer {
        padding: 20px;
        flex-direction: column;
    }

    #successModal .modal-footer .btn {
        width: 100%;
    }
}

/* Global validation message */
.global-validation-message {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1060;
    min-width: 300px;
    animation: slideInRight 0.3s ease;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Immediate mandatory field highlighting */
.content-section.active .is-invalid {
    border-color: #dc3545 !important;
    background-color: #fff8f8 !important;
}

/* Units conversion styling */
.units-converted {
    font-size: 0.875rem;
    color: #6c757d;
    margin-top: 0.25rem;
}

/* Enhanced field states for mandatory fields */
.form-control.field-untouched {
    border-color: #dee2e6 !important;
    background-color: #ffffff !important;
}

.form-control.field-complete , .form-select.field-complete {
    border-color: #2BA72B !important;
    border-width: 2px;
    background-color: #f8fff8 !important;
}

.form-control.field-incomplete {
    border-color: #dc3545 !important;
    background-color: #fff8f8 !important;
}

.form-control.field-focus {
    border-color: #2BA72B !important;
    box-shadow: 0 0 0 0.2rem rgba(43, 167, 43, 0.25);
}

/* Hide validation errors by default, show only when field is invalid and focused */
.validation-error {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: none;
}

.validation-error.show {
    display: block;
}


/* Make Contact tab green by default */
.tab-item.active[data-target="home"] {
    background: #2BA72B !important;
    color: white !important;
}

/* Enhanced field styling */
.form-control {
    border: 2px solid #dee2e6;
    transition: all 0.3s ease;
}

/* Red borders for mandatory fields */
.form-control:required {
    border-color: #dc3545 !important;
}

/* Green borders for completed fields */
.form-control.field-complete {
    border-color: #2BA72B !important;
    background-color: #f8fff8 !important;
}

/* Make sure all fields turn green when filled */
.form-control:not(:required):not(:placeholder-shown) {
    border-color: #2BA72B !important;
    background-color: #f8fff8 !important;
}


/* Enhanced validation styling */
.validation-error {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: none;
}

.validation-error.show {
    display: block;
}

/* Required field label styling */
.form-label.required::after {
    content: " *";
    color: #dc3545;
}

/* Keep the rest of your existing CSS as is */