@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@300;400;500;600;700&family=Playfair+Display:wght@500;600;700&display=swap');

.gd-designer {
    --gd-ink: #1f2a3a;
    --gd-muted: #7a8798;
    --gd-accent: #6aa4e8;
    --gd-accent-strong: #2f6ecf;
    --gd-warm: #f4b24a;
    --gd-surface: #ffffff;
    --gd-surface-soft: #f6f8fb;
    --gd-panel: #eef4ff;
    --gd-border: rgba(31, 42, 58, 0.14);
    --gd-border-strong: rgba(31, 42, 58, 0.2);
    --gd-shadow: 0 18px 36px rgba(22, 30, 46, 0.12);
    --gd-radius: 22px;
    --gd-radius-16: 16px;
    --gd-radius-20: 20px;
    --gd-space-8: 8px;
    --gd-space-12: 12px;
    --gd-space-16: 16px;
    --gd-space-20: 20px;
    --gd-space-24: 24px;
    --gd-shadow-soft: 0 12px 24px rgba(22, 30, 46, 0.12);
    --gd-font-body: "Manrope", "Trebuchet MS", "Lucida Sans Unicode", sans-serif;
    --gd-font-display: "Playfair Display", "Palatino Linotype", serif;

    --gd-max-height: 90vh;

    font-family: var(--gd-font-body);
    color: var(--gd-ink);
    background: #ffffff;
    border: 1px solid var(--gd-border);
    border-radius: 28px;
    padding: 20px;
    box-shadow: 0 14px 28px rgba(22, 30, 46, 0.08);
    position: relative;
    overflow: hidden;
    max-height: var(--gd-max-height);
}

.gd-designer::before {
    display: none;
}

.gd-shell {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
    position: relative;
    z-index: 1;
    align-items: start;
}

.gd-sidebar {
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0;
    display: grid;
    gap: var(--gd-space-16);
    box-shadow: none;
    position: absolute;
    top: calc(-1 * var(--gd-space-20));
    left: calc(-1 * var(--gd-space-20));
    z-index: 4;
    max-height: var(--gd-max-height);
    overflow: visible;
}

.gd-sidebar-header {
    display: grid;
    gap: 6px;
}

.gd-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.8rem;
}

.gd-brand-mark {
    width: 28px;
    height: 28px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--gd-accent), var(--gd-warm));
    box-shadow: 0 6px 14px rgba(63, 120, 195, 0.3);
}

.gd-brand-name {
    font-family: var(--gd-font-display);
    font-size: 1rem;
    letter-spacing: 0.03em;
}

.gd-sidebar-subtitle {
    margin: 0;
    color: var(--gd-muted);
    font-size: 0.9rem;
}

.gd-sidebar-body {
    display: grid;
    grid-template-columns: 240px minmax(320px, 400px);
    gap: var(--gd-space-12);
    align-items: start;
    min-height: 0;
}

.gd-sidebar-nav {
    display: grid;
    gap: 0;
    align-content: start;
    position: static;
    width: 100%;
    background: transparent;
    border: none;
    border-radius: 0;
    overflow: visible;
    box-shadow: none;
}

.gd-mode-button {
    border: 0;
    border-right: 1px solid var(--gd-border-strong);
    border-bottom: 1px solid var(--gd-border-strong);
    background: rgba(106, 164, 232, 0.08);
    border-radius: 0;
    padding: 18px 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-size: 0.78rem;
    min-height: 110px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 10px;
    text-align: center;
    color: var(--gd-ink);
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
    width: 100%;
    position: relative;
}

.gd-mode-button:hover {
    transform: translateY(-1px);
    background: rgba(106, 164, 232, 0.12);
    box-shadow: 0 10px 18px rgba(22, 30, 46, 0.12);
}

.gd-mode-button.is-active {
    background: rgba(47, 110, 207, 0.12);
    box-shadow: none;
}

.gd-mode-button.is-active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--gd-accent-strong);
}

.gd-mode-button:first-child.is-active::before {
    border-top-left-radius: 18px;
}

.gd-mode-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.gd-mode-button:first-child {
    border-top-left-radius: 18px;
}

.gd-mode-icon {
    color: var(--gd-accent-strong);
    display: grid;
    place-items: center;
}

.gd-mode-icon svg {
    width: 34px;
    height: 34px;
    stroke: currentColor;
    stroke-width: 1.8;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.gd-mode-label {
    line-height: 1;
}

.gd-mode-button:focus-visible,
.gd-upload-dropzone:focus-visible,
.gd-upload-image:focus-visible,
.gd-create-text:focus-visible,
.gd-layer-select:focus-visible,
.gd-layer-control:focus-visible,
.gd-layer-action:focus-visible,
.gd-sidebar-toggle:focus-visible {
    outline: 2px solid rgba(47, 110, 207, 0.7);
    outline-offset: 2px;
}

.gd-sidebar-panels {
    display: grid;
    gap: var(--gd-space-16);
    overflow-y: auto;
    max-height: calc(var(--gd-max-height) - 32px);
    padding-right: 6px;
}

.gd-sidebar-toggle {
    border: 1px solid var(--gd-border-strong);
    border-radius: 12px;
    background: #ffffff;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--gd-ink);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    padding: 0;
    line-height: 0;
}

.gd-panel-header {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: var(--gd-space-8);
    padding-bottom: var(--gd-space-8);
    border-bottom: 1px solid rgba(31, 42, 58, 0.08);
}

.gd-panel-header .gd-panel-title {
    margin: 0;
}

.gd-panel-header .gd-sidebar-toggle {
    justify-self: end;
}

.gd-panel-header .gd-filter {
    grid-column: 1 / -1;
}

.gd-sidebar-toggle:hover {
    border-color: rgba(47, 110, 207, 0.4);
    box-shadow: 0 8px 16px rgba(22, 30, 46, 0.12);
    transform: translateY(-1px);
}

.gd-sidebar-toggle svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.2s ease;
}

.gd-designer.is-sidebar-collapsed .gd-sidebar-body {
    grid-template-columns: 240px 50px;
}

.gd-designer.is-sidebar-collapsed .gd-sidebar-panels {
    overflow: visible;
    padding-right: 0;
}

.gd-designer.is-sidebar-collapsed .gd-sidebar-panels .gd-panel {
    display: none;
}

.gd-designer.is-sidebar-collapsed .gd-sidebar-toggle svg {
    transform: rotate(180deg);
}

.gd-sidebar-panels::-webkit-scrollbar {
    width: 6px;
}

.gd-sidebar-panels::-webkit-scrollbar-thumb {
    background: rgba(31, 42, 58, 0.2);
    border-radius: 999px;
}

.gd-sidebar-panels::-webkit-scrollbar-track {
    background: transparent;
}

.gd-panel {
    background: var(--gd-surface);
    border: 1px solid var(--gd-border);
    border-radius: var(--gd-radius-20);
    padding: var(--gd-space-16);
    display: grid;
    gap: var(--gd-space-12);
    box-shadow: none;
}

.gd-panel-title {
    font-weight: 700;
    color: var(--gd-ink);
}

.gd-panel-section {
    display: grid;
    gap: var(--gd-space-12);
    padding-top: var(--gd-space-12);
    border-top: 1px solid rgba(31, 42, 58, 0.08);
}

.gd-panel-subtitle {
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gd-muted);
    font-weight: 600;
}

.gd-panel-hint {
    margin: 0;
    font-size: 0.85rem;
    color: var(--gd-muted);
}

.gd-upload-dropzone {
    border: 1px dashed rgba(47, 110, 207, 0.3);
    border-radius: var(--gd-radius-16);
    background: var(--gd-surface-soft);
    padding: var(--gd-space-16);
    text-align: center;
    display: grid;
    gap: var(--gd-space-8);
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.gd-upload-dropzone.is-dragover {
    border-color: rgba(47, 110, 207, 0.7);
    box-shadow: 0 12px 20px rgba(22, 30, 46, 0.12);
    transform: translateY(-1px);
}

.gd-upload-title {
    font-weight: 700;
    color: var(--gd-ink);
}

.gd-upload-hint {
    margin: 0;
    font-size: 0.82rem;
    color: var(--gd-muted);
}

.gd-upload-image {
    border: none;
    background: #ffffff;
    border-radius: var(--gd-radius-16);
    padding: 10px 12px;
    font-weight: 700;
    cursor: pointer;
    color: var(--gd-ink);
    box-shadow: inset 0 0 0 1px rgba(47, 110, 207, 0.2);
    width: 100%;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.gd-upload-image:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(22, 30, 46, 0.12);
}

.gd-text-create {
    display: grid;
    gap: var(--gd-space-12);
    padding: var(--gd-space-12);
    border-radius: var(--gd-radius-16);
    background: var(--gd-surface-soft);
    border: 1px solid rgba(31, 42, 58, 0.12);
}

.gd-create-text {
    border: none;
    background: #ffffff;
    border-radius: var(--gd-radius-16);
    padding: 10px 12px;
    font-weight: 700;
    cursor: pointer;
    color: var(--gd-ink);
    box-shadow: inset 0 0 0 1px rgba(47, 110, 207, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.gd-create-text:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(22, 30, 46, 0.12);
}

.gd-panel-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.gd-layer-remove {
    border: 1px solid rgba(47, 110, 207, 0.25);
    background: #ffffff;
    border-radius: 10px;
    padding: 6px 8px;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--gd-ink);
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.gd-layer-remove:hover {
    border-color: rgba(47, 110, 207, 0.45);
    box-shadow: 0 6px 12px rgba(22, 30, 46, 0.12);
}

.gd-empty-selection {
    font-size: 0.85rem;
    color: var(--gd-muted);
    padding: var(--gd-space-8) 0 2px;
}

.gd-control {
    display: grid;
    gap: 6px;
    font-size: 0.88rem;
    color: var(--gd-muted);
}

.gd-control span {
    font-weight: 600;
    color: var(--gd-ink);
}

.gd-control textarea,
.gd-control select,
.gd-control input[type="range"],
.gd-control input[type="color"] {
    width: 100%;
}

.gd-control textarea,
.gd-control select {
    border: 1px solid rgba(31, 42, 58, 0.18);
    border-radius: 14px;
    padding: 10px 12px;
    background: #ffffff;
    font-family: var(--gd-font-body);
}

.gd-control input[type="range"] {
    accent-color: var(--gd-accent-strong);
}

.gd-control input[type="color"] {
    border: none;
    height: 36px;
    background: transparent;
}

.gd-control .gd-replace-image {
    border: none;
    background: var(--gd-surface);
    border-radius: 10px;
    padding: 8px 10px;
    cursor: pointer;
    font-weight: 600;
    box-shadow: inset 0 0 0 1px rgba(63, 120, 195, 0.2);
}

.gd-panel-layers {
    min-height: 120px;
}

.gd-layer-dock {
    position: absolute;
    left: 16px;
    bottom: 16px;
    width: 280px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(31, 42, 58, 0.16);
    border-radius: 16px;
    padding: 12px;
    display: grid;
    gap: 10px;
    box-shadow: 0 14px 28px rgba(22, 30, 46, 0.16);
    backdrop-filter: blur(6px);
    z-index: 3;
}

.gd-layer-actions {
    position: absolute;
    display: none;
    justify-content: center;
    gap: 10px;
    transform: translateX(-50%);
    z-index: 3;
}

.gd-layer-actions.is-visible {
    display: flex;
}

.gd-layer-action {
    width: 36px;
    height: 36px;
    border: 1px solid rgba(31, 42, 58, 0.16);
    border-radius: 999px;
    background: #ffffff;
    display: grid;
    place-items: center;
    cursor: pointer;
    color: var(--gd-ink);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    padding: 0;
}

.gd-layer-action:hover {
    border-color: rgba(47, 110, 207, 0.4);
    box-shadow: 0 8px 16px rgba(22, 30, 46, 0.1);
    transform: translateY(-1px);
}

.gd-layer-action:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.gd-layer-action svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 1.8;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.gd-layer-action-delete {
    color: #a35b5b;
}

.gd-layer-dock-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.gd-layer-dock-title {
    font-weight: 700;
    color: var(--gd-ink);
}

.gd-layer-dock-note {
    font-size: 0.75rem;
    color: var(--gd-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.gd-layer-list {
    display: grid;
    gap: 8px;
    max-height: 220px;
    overflow-y: auto;
    padding-right: 4px;
}

.gd-layer-list::-webkit-scrollbar {
    width: 6px;
}

.gd-layer-list::-webkit-scrollbar-thumb {
    background: rgba(31, 42, 58, 0.18);
    border-radius: 999px;
}

.gd-layer-list::-webkit-scrollbar-track {
    background: transparent;
}

.gd-layer-empty {
    font-size: 0.85rem;
    color: var(--gd-muted);
    padding: 6px 4px;
}

.gd-layer-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gd-layer-select {
    flex: 1;
    border: 1px solid rgba(31, 42, 58, 0.16);
    background: #ffffff;
    border-radius: 12px;
    padding: 8px 10px;
    text-align: left;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    color: var(--gd-ink);
}

.gd-layer-select:hover {
    border-color: rgba(47, 110, 207, 0.4);
    box-shadow: 0 8px 16px rgba(22, 30, 46, 0.1);
    transform: translateY(-1px);
}

.gd-layer-item.is-active .gd-layer-select {
    border-color: var(--gd-accent-strong);
    box-shadow: 0 8px 16px rgba(47, 110, 207, 0.18);
    background: rgba(47, 110, 207, 0.08);
}

.gd-layer-controls {
    display: flex;
    gap: 6px;
}

.gd-layer-control {
    width: 32px;
    height: 32px;
    border: 1px solid rgba(31, 42, 58, 0.16);
    border-radius: 10px;
    background: #ffffff;
    display: grid;
    place-items: center;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
    color: var(--gd-ink);
    padding: 0;
}

.gd-layer-control:hover {
    border-color: rgba(47, 110, 207, 0.4);
    box-shadow: 0 8px 16px rgba(22, 30, 46, 0.1);
    transform: translateY(-1px);
}

.gd-layer-control:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.gd-layer-control svg {
    width: 16px;
    height: 16px;
    stroke: currentColor;
    stroke-width: 1.8;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.gd-layer-delete {
    color: #a35b5b;
}

.gd-cart-form {
    margin: 0;
}

.gd-checkout-bar {
    margin-top: 0;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-end;
    gap: 10px;
    position: absolute;
    right: 16px;
    bottom: 16px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(31, 42, 58, 0.16);
    border-radius: 16px;
    padding: 10px;
    box-shadow: 0 14px 28px rgba(22, 30, 46, 0.18);
    backdrop-filter: blur(6px);
}

.gd-price {
    background: rgba(47, 110, 207, 0.12);
    border: 1px solid rgba(47, 110, 207, 0.24);
    border-radius: 16px;
    padding: 10px 12px;
    min-width: 140px;
}

.gd-price span {
    display: block;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gd-muted);
}

.gd-price strong {
    font-family: var(--gd-font-display);
    font-size: 1.3rem;
}

.gd-add-to-cart {
    border: none;
    background: linear-gradient(135deg, var(--gd-accent-strong), #6aa4e8);
    color: #ffffff;
    padding: 10px 12px;
    border-radius: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    min-width: 180px;
}

.gd-add-to-cart:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 20px rgba(47, 110, 207, 0.3);
}

.gd-add-to-cart:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.gd-cart-hint {
    margin: 0;
    font-size: 0.85rem;
    color: var(--gd-muted);
}

.gd-stage {
    display: grid;
    gap: var(--gd-space-24);
    position: relative;
}

.gd-preview-wrap {
    position: relative;
    display: grid;
    justify-items: center;
    align-items: center;
    padding-top: 0;
}

.gd-stage-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--gd-space-16);
}

.gd-stage-head h3 {
    font-family: var(--gd-font-display);
    font-size: 1.6rem;
    margin: 0 0 6px;
}

.gd-stage-head p {
    margin: 0;
    color: var(--gd-muted);
}

.gd-filter {
    display: grid;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--gd-muted);
}

.gd-filter select {
    border: 1px solid rgba(63, 120, 195, 0.3);
    border-radius: 12px;
    padding: 8px 10px;
    background: #ffffff;
    min-width: 0;
    width: 100%;
}

.gd-preview {
    background: transparent;
    border-radius: 0;
    padding: 0;
    border: none;
    box-shadow: none;
    display: flex;
    justify-content: center;
    max-width: 760px;
    margin: 0 auto;
}

.gd-preview-frame {
    position: relative;
    border-radius: 18px;
    padding: 0;
    background: #ffffff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 760px;
    aspect-ratio: 1 / 1;
    height: auto;
    box-sizing: border-box;
}

.gd-glass-image {
    display: block;
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
}

.gd-area {
    position: absolute;
    box-sizing: border-box;
}

.gd-area-outline {
    position: absolute;
    inset: 0;
    border: 2px dashed rgba(47, 110, 207, 0.5);
    border-radius: 12px;
    pointer-events: none;
}

.gd-layer-stack {
    position: absolute;
    inset: 0;
}

.gd-layer {
    position: absolute;
    border: 1px solid transparent;
    border-radius: 10px;
    pointer-events: auto;
    cursor: move;
    overflow: visible;
    touch-action: none;
    user-select: none;
}

.gd-layer.is-active {
    border-color: rgba(63, 120, 195, 0.8);
    box-shadow: 0 0 0 1px rgba(63, 120, 195, 0.4);
}

.gd-layer-content {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4px;
    box-sizing: border-box;
    overflow: hidden;
    border-radius: inherit;
}

.gd-layer-text {
    white-space: pre-wrap;
    line-height: 1.15;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 0 1px rgba(45, 52, 60, 0.35);
    -webkit-text-stroke: 0.3px rgba(45, 52, 60, 0.35);
}

.gd-layer-text.is-editing {
    cursor: text;
}

.gd-layer-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    filter: grayscale(100%);
}

.gd-layer .ui-resizable-handle {
    width: 10px;
    height: 10px;
    background: #ffffff;
    border: 1px solid rgba(63, 120, 195, 0.8);
    border-radius: 50%;
}

.gd-resize-handle {
    width: 12px;
    height: 12px;
    background: #ffffff;
    border: 2px solid rgba(63, 120, 195, 0.85);
    border-radius: 50%;
    position: absolute;
    box-shadow: 0 3px 10px rgba(30, 47, 72, 0.18);
    opacity: 0;
    pointer-events: none;
    touch-action: none;
}

.gd-layer.is-active .gd-resize-handle {
    opacity: 1;
    pointer-events: auto;
}

.gd-resize-n {
    top: -7px;
    left: 50%;
    margin-left: -7px;
    cursor: n-resize;
}

.gd-resize-s {
    bottom: -7px;
    left: 50%;
    margin-left: -7px;
    cursor: s-resize;
}

.gd-resize-e {
    right: -7px;
    top: 50%;
    margin-top: -7px;
    cursor: e-resize;
}

.gd-resize-w {
    left: -7px;
    top: 50%;
    margin-top: -7px;
    cursor: w-resize;
}

.gd-resize-ne {
    right: -7px;
    top: -7px;
    cursor: ne-resize;
}

.gd-resize-nw {
    left: -7px;
    top: -7px;
    cursor: nw-resize;
}

.gd-resize-se {
    right: -7px;
    bottom: -7px;
    cursor: se-resize;
}

.gd-resize-sw {
    left: -7px;
    bottom: -7px;
    cursor: sw-resize;
}

.gd-glass-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: var(--gd-space-12);
    overflow-y: auto;
    max-height: 440px;
}

.gd-glass-card {
    border: 1px solid rgba(31, 42, 58, 0.14);
    border-radius: var(--gd-radius-16);
    background: #ffffff;
    padding: 10px 12px;
    display: grid;
    grid-template-columns: 52px 1fr;
    align-items: center;
    gap: 10px;
    min-width: 0;
    text-align: left;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
    animation: gd-rise 0.4s ease both;
}

.gd-glass-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 18px rgba(22, 30, 46, 0.14);
    border-color: rgba(47, 110, 207, 0.4);
}

.gd-glass-card.is-active {
    border-color: rgba(47, 110, 207, 0.7);
    background: rgba(47, 110, 207, 0.1);
    box-shadow: 0 14px 24px rgba(22, 30, 46, 0.18);
}

.gd-panel-glasses .gd-glass-list {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    max-height: 360px;
}

.gd-panel-glasses .gd-glass-card {
    min-width: 0;
    width: 100%;
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    padding: 12px 10px;
}

.gd-panel-glasses .gd-glass-thumb {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    border-radius: 12px;
}

.gd-panel-glasses .gd-glass-meta {
    justify-items: center;
}

.gd-glass-thumb {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    border: 1px solid rgba(31, 42, 58, 0.14);
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.gd-glass-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.gd-glass-meta {
    display: grid;
    gap: 4px;
}

.gd-glass-name {
    font-weight: 700;
    color: var(--gd-ink);
}

.gd-glass-card-price {
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--gd-muted);
}

.gd-upload-input {
    display: none;
}

.is-hidden {
    display: none !important;
}

@keyframes gd-rise {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 1100px) {
    .gd-preview {
        max-width: 600px;
    }

    .gd-preview-frame {
        max-width: 600px;
    }
}

@media (max-width: 900px) {
    .gd-shell {
        grid-template-columns: 1fr;
        gap: var(--gd-space-16);
    }

    .gd-sidebar {
        position: static;
        max-height: none;
        overflow: visible;
    }

    .gd-sidebar-body {
        grid-template-columns: 1fr;
    }

    .gd-sidebar-nav {
        width: 100%;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .gd-mode-button {
        min-height: 72px;
        border-bottom: 1px solid var(--gd-border-strong);
        border-right: 1px solid var(--gd-border-strong);
    }

    .gd-mode-button:last-child {
        border-right: none;
    }

    .gd-sidebar-panels {
        max-height: none;
        padding-right: 0;
    }

    .gd-stage-head {
        flex-direction: column;
    }

    .gd-layer-dock {
        position: static;
        width: 100%;
        box-shadow: none;
    }
}

@media (max-width: 720px) {
    .gd-designer {
        max-height: none;
    }

    .gd-mode-button {
        min-height: 64px;
        font-size: 0.75rem;
    }

    .gd-mode-icon svg {
        width: 24px;
        height: 24px;
    }

    .gd-preview {
        padding: 0;
        max-width: 420px;
    }

    .gd-preview-frame {
        padding: 0;
        max-width: 420px;
    }

    .gd-mode-button {
        min-height: 52px;
    }

    .gd-glass-card {
        grid-template-columns: 50px 1fr;
    }

    .gd-glass-thumb {
        width: 50px;
        height: 50px;
    }

    .gd-checkout-bar {
        flex-direction: column;
        align-items: stretch;
        right: 8px;
        bottom: 8px;
    }

    .gd-add-to-cart {
        width: 100%;
        min-width: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    .gd-designer * {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
