.welcome-container {
    width: auto;
    height: auto;
    background-image: url('../img/welcome/bg-barcode.png');
    background-repeat: no-repeat;
    background-size: cover;
    background-position: 70% 100%; /* Default to bottom right for mobile */
    overflow-x: hidden;
    position: relative;
}

@media (min-width: 48rem) { /* 768px / 16px = 48rem */
    .welcome-container {
        width: 100%;
        height: 120vh;
        background-position: center; /* Center for desktop */
    }
}

/* White box */
.welcome-box {
    background-color: rgba(255, 255, 255, 0.95);
    padding: 1.25rem;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    margin: 3rem 2rem;
    position: relative;
    width: calc(100% - 3rem);
    max-width: 90%;
}

@media (min-width: 48rem) { /* 768px / 16px = 48rem */
    .welcome-box {
        padding: 2rem;
        margin: 0;
        position: absolute;
        top: 9.5rem;
        left: 5rem;
        max-width: 45%;
    }
}

/* Title and logo */
.welcome-title {
    color: #0092BC;
    font-size: 1.875rem;
    font-weight: 400;
    margin-bottom: 0.5rem;
}

@media (min-width: 48rem) {
    .welcome-title {
        font-size: 2.5rem;
        margin-top: 0.5rem;
    }
}

@media (min-width: 62rem) {
    .welcome-title {
        font-size: 3rem;
    }
}

.welcome-logo {
    height: 2.5rem;
    margin-top: 0.5rem;
    margin-left: -0.25rem;
}

@media (min-width: 48rem) {
    .welcome-logo {
        height: 3.5rem;
        margin-top: 1.5rem;
        margin-left: 0.25rem;
    }
}

.welcome-subtitle {
    color: #474747;
    font-size: 1.25rem;
    font-weight: bold;
    margin-top: 1rem;
}

/* Description text */
.welcome-text {
    color: #474747;
    font-size: 16px;
}

@media (min-width: 62rem) {
    .welcome-text {
        font-size: 20px;
    }
}

.welcome-link {
    color: #183BFF;
    text-decoration: underline;
    font-size: 16px;
}

@media (min-width: 62rem) {
    .welcome-link {
        font-size: 20px;
    }
}

.welcome-link:hover {
    color: #0A2DCC;
}

/* Input fields */
.digit-input {
    width: 3.75rem !important;
    height: 3.75rem !important;
    text-align: center;
    color: #474747;
    font-size: 1.25rem;
    border-radius: 0.5rem !important;
    padding: 0 !important;
    line-height: 1 !important;
}

@media (min-width: 48rem) {
    .digit-input {
        width: 3.25rem !important;
        height: 3.25rem !important;
        font-size: 1.25rem;
    }
}

.digit-input:focus {
    box-shadow: 0 0 0 0.125rem #0092BC !important;
    border-color: #0092BC !important;
}

#barcode-message {
    min-height: 1.5rem;
    font-size: 1rem;
}

@media (min-width: 48rem) {
    #barcode-message {
        font-size: 1.125rem;
    }
}

.popup-title {
    font-size: 1.25rem;  /* 20px */
    font-weight: 700;
    color: #474747;
    line-height: 1.2;
    word-wrap: break-word;
    margin-bottom: 0;
}

@media (min-width: 48rem) {
    .popup-title {
        font-size: 1.5rem;  /* 24px */
    }
}

.batch-help-image {
    width: 100%;
    height: auto;
    aspect-ratio: 311/199; /* Mobile aspect ratio */
    object-fit: cover;
    display: block;
    margin: 0;
    padding: 0;
    line-height: 0;
}

@media (min-width: 48rem) {
    .batch-help-image {
        aspect-ratio: 593/379; /* Desktop aspect ratio */
    }
}

.modal-content {
    padding: 1rem;  /* 16px */
    border-radius: 1rem !important;  /* 16px */
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 2rem;  /* 32px */
}

@media (min-width: 48rem) {
    .modal-content {
        padding: 2rem;  /* 32px */
    }
}

.modal-dialog {
    margin: 0.5rem;
    max-width: calc(100% - 1rem);
}

@media (min-width: 48rem) {
    .modal-dialog {
        margin: 1.75rem auto;
        max-width: 50rem;  /* 800px */
    }
}

.modal-header {
    padding: 0 !important;
    border: none !important;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.25rem;  /* 20px */
}

.modal-body {
    padding: 0 !important;
    border: none !important;
}

.btn-close:focus {
    box-shadow: none !important;
}

.btn-close img {
    width: 1.5rem;  /* 24px */
    height: 1.5rem;  /* 24px */
}

@media (min-width: 48rem) {
    .btn-close img {
        width: 2rem;  /* 32px */
        height: 2rem;  /* 32px */
    }
}

.close-btn {
    background: transparent;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:focus {
    outline: none;
    box-shadow: none;
}

.close-btn img {
    width: 1.5rem;  /* 24px */
    height: 1.5rem;  /* 24px */
}

@media (min-width: 48rem) {
    .close-btn img {
        width: 2rem;  /* 32px */
        height: 2rem;  /* 32px */
    }
}
