/* MOBILE OVERRIDES (1-Column Stack, Flexible Canvas, Collapsible Drawer) */
.header-wrapper {
    padding: 0 10px;
    margin-top: 15px;
}

.editor-container {
    display: flex;
    flex-direction: column;
    padding: 10px;
    gap: 15px;
    width: 100%;
    box-sizing: border-box;
}

.sidebar-card {
    height: auto;
    max-height: none;
    width: 100%;
    box-sizing: border-box;
    order: 2; /* Move controls below canvas */
}

.top-nav-box {
    padding: 10px 8px;
    gap: 6px;
}

.nav-btn {
    flex: 1 1 calc(50% - 6px);
    padding: 8px 10px;
    font-size: 10px;
    min-width: 0;
}

.mobile-toggle-btn {
    display: flex; /* Show collapse button */
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 14px 20px;
    background: #ffffff;
    border: none;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    font-family: inherit;
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-blue);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    outline: none;
}

.mobile-toggle-btn img {
    width: 20px;
    height: 20px;
    object-fit: contain;
}

.collapsible-editor-area.is-collapsed {
    max-height: 0px !important;
    opacity: 0;
    padding-top: 0;
    padding-bottom: 0;
}

.workspace {
    padding: 15px 10px;
    width: 100%;
    box-sizing: border-box;
    order: 1; /* Keep canvas top-most */
}

.card-canvas {
    width: 100%;
    max-width: 100%;
    height: calc(85vw * 1.29);
    max-height: 580px;
}

.zone-sticker { 
    top: 8%; 
    left: 8%; 
    width: 28%; 
    height: 28%; 
}

.zone-flower { 
    top: 24%; 
    left: 27%; 
    width: 45%; 
    height: 45%; 
}

.zone-text { 
    top: 65%; 
    left: 5%; 
    width: 90%; 
    height: auto !important;       /* Prevents bottom height locking */
    bottom: auto !important;      /* Explicitly breaks the bottom anchor */
    box-sizing: border-box;
}

.loaded-text { 
    font-size: 18px; 
    line-height: 1.25;
    padding: 4px;
    height: auto !important;       /* Keeps text height fluid with the box */
}
/* Make textarea height/width locked and tighter on mobile */
#panel textarea.form-control {
    height: 70px;
    max-height: 70px;
    width: 100%;
    max-width: 100%;
    resize: none; /* Prevents manual resizing of width & height */
    padding: 6px 10px;
    box-sizing: border-box;
}

#panel .input-group-inline {
    margin-bottom: 8px; /* Tightens vertical spacing between options */
}