/* Ultra-Compact Global Styles for a Modern, Minimal UI */
body {
    background-color: #f2f2f2;
    background-image: url('page_bg.jpg');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center;
    font-family: Verdana, Arial, sans-serif;
    margin: 0;
    padding: 20px 0;
    color: #000;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
    box-sizing: border-box;
}

/* New styles for the left sidebar wrapper */
#left-sidebar-wrapper {
    position: fixed;
    top: 20px;
    left: 20px;
    width: 500px;
    background: rgba(190, 255, 253, 0.5);
    border: 1px solid #999;
    padding: 20px;
    z-index: 998;
    box-sizing: border-box;
    border-radius: 0px; /* To match main wrapper's removed border-radius */
    box-shadow: none; /* To match main wrapper's removed box-shadow */
}

#right-sidebar-wrapper {
    position: fixed;
    top: 110px;
    right: 20px;
    width: 500px;
    background: rgba(255, 254, 190, 0.5);
    border: 1px solid #999;
    padding: 20px;
    z-index: 998;
    box-sizing: border-box;
    border-radius: 0px;
    box-shadow: none;
}

#wrapper {
    width: 800px;
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    border: 1px solid #999;
    border-radius: 0px;
    box-shadow: none;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
}

h1 {
    font-size: 20px;
    text-align: center;
    color: #2a5dad;
    margin-bottom: 10px;
    font-weight: 600;
}

h1 span {
    color: #2a5dad;
}

h3 {
    font-size: 16px;
    margin-top: 20px;
    border-bottom: 2px solid #2a5dad;
    padding-bottom: 4px;
    color: #2a5dad;
    width: 100%;
    text-align: left;
    font-weight: 600;
}

.description {
    font-size: 13px;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.4;
    color: #6c757d;
}

.description hr {
    border: none;
    border-top: 1px solid #dee2e6;
    margin: 8px 0;
}

.description span b {
    color: #2a5dad;
}

.form-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 350px;
    margin-bottom: 10px;
}

input, textarea, select {
    font-family: Verdana, Arial, sans-serif;
    font-size: 12px;
    padding: 8px 10px;
    width: 100%;
    border: 1px solid #ced4da;
    border-radius: 4px;
    box-sizing: border-box;
    margin-bottom: 8px;
    background-color: #ffffff;
}

textarea {
    height: 80px;
    resize: vertical;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: #2a5dad;
}

button {
    font-family: Verdana, Arial, sans-serif;
    font-size: 12px;
    padding: 8px 15px;
    background: #2a5dad;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    margin-top: 4px;
}

button:hover {
    background: #1e3f7f;
}

#error {
    font-family: Verdana, Arial, sans-serif;
    font-size: 10px;
    color: #dc3545;
    margin-top: 8px;
    text-align: center;
    padding: 5px;
    background-color: #fff3cd;
    border: 1px solid #ffeeba;
    border-radius: 4px;
    width: 100%;
    max-width: 350px;
    box-sizing: border-box;
}

.footer {
    font-size: 12px;
    text-align: center;
    margin-top: 20px;
    background-color: black;
    color: white;
    padding: 0.5px;
    width: 100%;
    margin-left: 0;
    margin-right: 0;
    border-bottom-left-radius: 0px;
    border-bottom-right-radius: 0px;
}

.footer span {
    color: yellow;
}

.footer a {
    color: #fff;
    text-decoration: underline;
}

.footer a:hover {
    text-decoration: underline;
    color: #ccc;
}

#logo {
    display: block;
    margin: 0 auto 10px auto;
    max-width: 700px;
    height: auto;
}

/* Tile Grid for index.html */
.tile-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: space-between;
    width: 100%;
    margin-top: 10px;
}

.tile {
    flex: 1 1 31%;
    background: #dcdcdc;
    border: 1px solid #999;
    border-radius: 0px;
    padding: 20px;
    text-align: center;
    font-size: 14px;
    cursor: pointer;
    box-sizing: border-box;
    color: black;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 80px;
    font-weight: 500;
}

.tile:hover {
    background-color: #f0f0f0;
    border-color: #666;
}

.tile img {
    display: block;
    margin: 0 auto;
    max-width: none;
    height: auto;
    margin-bottom: 6px;
    border-radius: 2px;
}

/* Specific style for image-enhancer tile warning text */
.tile[onclick*="image-enhancer"] b {
    color: #dc3545;
}

/* Top-right floating elements */
.store-info-container {
    position: fixed;
    top: 8px;
    right: 8px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    z-index: 1000;
}

#store-info {
    background-color: #ffffff;
    color: #2a5dad;
    border: 1px solid #2a5dad;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}

.logout-button {
    background-color: #dc3545;
    color: #fff;
    border: none;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
}

.logout-button:hover {
    background-color: #c82333;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    #left-sidebar-wrapper {
        position: relative;
        top: auto;
        left: auto;
        width: 100%;
        margin-bottom: 20px;
    }
    #wrapper {
        width: 100%;
        padding: 12px;
        margin-left: 0;
    }
    body {
        padding-left: 0;
    }
    h1 {
        font-size: 18px;
    }
    h3 {
        font-size: 14px;
    }
    .footer {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
        padding: 0.5px;
    }
    .tile-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
        gap: 6px;
    }
    .tile {
        padding: 8px;
        font-size: 11px;
        min-height: 80px;
    }
}

@media (min-width: 1201px) {
    #wrapper {
        max-width: 900px;
        padding: 20px;
    }
    h1 {
        font-size: 22px;
    }
    h3 {
        font-size: 18px;
    }
    .description {
        font-size: 13px;
    }
    input, textarea, select {
        font-size: 13px;
        padding: 10px 12px;
    }
    button {
        font-size: 13px;
        padding: 10px 20px;
    }
    .tile {
        padding: 15px;
        font-size: 13px;
        min-height: 100px;
    }
    .footer {
        width: 100%;
        margin-left: 0;
        margin-right: 0;
        font-size: 11px;
    }
    #logo {
        max-width: 760px;
    }
}

@media (max-width: 768px) {
    body {
        padding: 5px 0;
    }
    #wrapper {
        padding: 10px;
        border-radius: 4px;
    }
    h1 {
        font-size: 16px;
        margin-bottom: 6px;
    }
    h3 {
        font-size: 13px;
        margin-top: 12px;
        padding-bottom: 4px;
    }
    .description {
        font-size: 11px;
        margin-bottom: 10px;
    }
    input, textarea, select {
        padding: 6px 8px;
        font-size: 11px;
        margin-bottom: 6px;
        border-radius: 3px;
    }
    button {
        padding: 6px 12px;
        font-size: 11px;
        border-radius: 3px;
    }
    #error {
        font-size: 10px;
        margin-top: 6px;
        padding: 4px;
    }
    .footer {
        padding: 0.5px;
        width: 100%;
        margin-left: 0;
        margin-right: 0;
        font-size: 10px;
    }
    #logo {
        max-width: 400px;
        margin-bottom: 8px;
    }
    .store-info-container {
        top: 5px;
        right: 5px;
        gap: 4px;
    }
    #store-info, .logout-button {
        padding: 4px 6px;
        font-size: 9px;
        border-radius: 3px;
    }
    .tile-grid {
        grid-template-columns: 1fr;
        gap: 6px;
    }
    .tile {
        min-height: 60px;
        padding: 8px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 3px 0;
    }
    #wrapper {
        padding: 8px;
        border-radius: 3px;
    }
    h1 {
        font-size: 14px;
    }
    h3 {
        font-size: 12px;
    }
    .description {
        font-size: 10px;
    }
    input, textarea, select {
        font-size: 10px;
        margin-bottom: 5px;
        padding: 5px 6px;
    }
    button {
        font-size: 10px;
        padding: 5px 10px;
    }
    .footer {
        font-size: 9px;
        padding: 0.5px;
        width: 100%;
        margin-left: 0;
        margin-right: 0;
    }
    #logo {
        max-width: 200px;
        margin-bottom: 8px;
    }
    .store-info-container {
        top: 3px;
        right: 3px;
        gap: 3px;
    }
    #store-info, .logout-button {
        padding: 3px 5px;
        font-size: 8px;
    }
    .tile {
        min-height: 50px;
        padding: 6px;
    }

/* Additional layout improvements */
.card-box {
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid #ccc;
    padding: 16px 20px;
    margin: 10px 0 20px 0;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    width: 100%;
    text-align: left;
    animation: fadeIn 0.5s ease;
}

/* Section coloring */
.section-lightblue {
    background-color: #e6f0fb;
}
.section-lightyellow {
    background-color: #fffbe5;
}
.section-lightgreen {
    background-color: #e9fbe9;
}
.section-lightpink {
    background-color: #fdeef4;
}
.section {
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

/* Modal polish */
.modal-content {
    background: #fff;
    border-radius: 6px;
    padding: 20px;
    animation: fadeInUp 0.3s ease;
    border: 2px solid #2a5dad;
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
.close-modal {
    font-size: 20px;
    font-weight: bold;
    float: right;
    color: #2a5dad;
    cursor: pointer;
}
}