:root {
    --primary: #f59e0b; /* Amber 500 */
    --primary-hover: #d97706; /* Amber 600 */
    --surface: rgba(255, 255, 255, 0.85);
    --surface-dark: rgba(30, 30, 30, 0.85);
    --text: #1f2937;
    --text-muted: #6b7280;
    --glass-blur: blur(12px);
    --border: rgba(255, 255, 255, 0.2);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

.hidden {
    display: none !important;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text);
    overflow: hidden; /* Hide scrollbars, map is full screen */
}

/* Map Container */
#map {
    width: 100vw;
    height: 100vh;
}

/* Header */
.top-bar {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border);
    border-radius: 100px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05), 0 4px 10px rgba(0,0,0,0.05);
}

.logo-container {
    display: flex;
    flex-direction: column;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 400;
    font-size: 1.8rem;
    color: var(--primary-hover);
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.logo strong {
    font-weight: 700;
    color: var(--text);
}

.logo-subtitle {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-left: 32px;
    margin-top: -2px;
}

.actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.language-switcher {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 10px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--text);
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.language-switcher select {
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 700;
    outline: none;
    cursor: pointer;
}

.account-language-select,
.actions > .language-select {
    min-height: 40px;
    max-width: 180px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--text);
    padding: 8px 10px;
    font: inherit;
    font-weight: 700;
    outline: none;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08);
}

.bot-field {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.consent-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.7);
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.35;
    margin-bottom: 14px;
    cursor: pointer;
    user-select: none;
}

.consent-check.required {
    border-color: rgba(245, 158, 11, 0.45);
    background: #fffbeb;
    color: #3f2f12;
}

.consent-check a {
    color: var(--primary-hover);
    font-weight: 700;
}

.consent-check input {
    width: 24px;
    height: 24px;
    min-width: 24px;
    margin-top: 1px;
    accent-color: var(--primary);
    cursor: pointer;
}

.location-picker {
    display: grid;
    gap: 12px;
}

.location-picker .location-actions,
.location-picker .location-picker-map,
.location-picker .account-note {
    grid-column: 1 / -1;
}

.location-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    width: 100%;
}

.location-picker-map {
    width: 100%;
    min-height: 280px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border);
    background: #e5e7eb;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.coordinate-field {
    display: none;
}

.location-picker .account-note {
    margin: 0;
    font-size: 0.86rem;
}

@media (max-width: 640px) {
    .location-actions {
        grid-template-columns: 1fr;
    }

    .location-picker-map {
        min-height: 240px;
    }

}

.account-shell {
    max-width: 1200px;
    margin: 24px auto 60px;
    padding: 0 20px;
}

.account-panel {
    padding: 24px;
    border-radius: 20px;
}

.account-panel h1,
.account-panel h2,
.account-hero h1 {
    margin: 0 0 10px;
    letter-spacing: 0;
}

.field-body {
    min-height: 100vh;
    margin: 0;
    background: #f8fafc;
    color: #111827;
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.field-app {
    width: min(100%, 720px);
    margin: 0 auto;
    padding: 18px 14px 96px;
}

.field-language-switcher {
    position: sticky;
    top: 10px;
    z-index: 30;
    width: fit-content;
    margin: 0 0 12px auto;
    background: rgba(255, 255, 255, 0.96);
    border-color: #e5e7eb;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.08);
}

.field-language-switcher select {
    max-width: 190px;
}

.field-login-card,
.field-card,
.field-header,
.field-stat-grid article {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.field-login-card {
    margin-top: 44px;
    padding: 24px;
}

.field-kicker {
    margin: 0 0 8px;
    color: #b45309;
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.field-login-card h1,
.field-header h1,
.field-panel h2,
.field-card h3 {
    margin: 0;
    letter-spacing: 0;
    color: #111827;
}

.field-login-card p,
.field-panel p,
.field-card p,
.field-empty,
.field-note {
    color: #4b5563;
    line-height: 1.45;
}

.field-error {
    color: #b91c1c;
    font-weight: 700;
}

.field-secondary-link {
    display: inline-block;
    margin-top: 16px;
    color: #92400e;
    font-weight: 800;
    text-decoration: none;
}

.field-header {
    position: sticky;
    top: 0;
    z-index: 20;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    margin-bottom: 16px;
}

.field-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.field-install-btn {
    border: 0;
    border-radius: 999px;
    background: #111827;
    color: #fbbf24;
    padding: 11px 12px;
    font-size: 0.82rem;
    font-weight: 900;
}

.field-install-help {
    margin: 12px 0 18px;
}

.field-install-card {
    box-shadow: none;
}

.field-install-card strong {
    color: #111827;
}

.field-install-card ol {
    margin: 10px 0 0;
    padding-left: 20px;
    color: #374151;
    line-height: 1.5;
}

.field-icon-btn {
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    background: #f59e0b;
    color: #111827;
    font-size: 1.3rem;
    font-weight: 900;
}

.field-panel {
    display: block;
}

.field-stat-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 14px 0;
}

.field-stat-grid article {
    padding: 14px;
}

.field-stat-grid span {
    display: block;
    color: #6b7280;
    font-size: 0.82rem;
    font-weight: 700;
}

.field-stat-grid strong {
    display: block;
    margin-top: 8px;
    color: #111827;
    font-size: 1.8rem;
}

.field-quick-actions,
.field-note-actions,
.field-order-actions,
.field-card-row {
    display: flex;
    gap: 10px;
}

.field-quick-actions {
    margin: 16px 0 22px;
}

.field-quick-actions .btn,
.field-note-actions .btn,
.field-order-actions .btn {
    flex: 1;
}

.field-manual-note {
    margin-bottom: 18px;
}

.field-order-actions {
    margin-top: 12px;
}

.field-list {
    display: grid;
    gap: 12px;
}

.field-card {
    padding: 16px;
}

.field-card-row {
    justify-content: space-between;
    align-items: flex-start;
}

.field-card-row strong {
    display: block;
    color: #111827;
}

.field-card-row span {
    color: #92400e;
    font-size: 0.86rem;
    font-weight: 800;
}

.field-form {
    display: grid;
    gap: 12px;
}

.field-form label {
    display: grid;
    gap: 6px;
    color: #374151;
    font-size: 0.9rem;
    font-weight: 800;
}

.field-form input,
.field-form textarea,
.field-form select,
.field-order-status,
.field-note-text,
.field-note-task {
    width: 100%;
    box-sizing: border-box;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    background: #ffffff;
    color: #111827;
    padding: 12px;
    font: inherit;
}

.field-form textarea,
.field-note-text {
    resize: vertical;
}

.field-section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.field-apiary-card {
    margin-top: 12px;
}

.field-bulk-form {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 8px;
    margin: 14px 0;
}

.field-bulk-form input {
    min-width: 0;
}

.field-hive-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.field-hive-chip {
    border: 1px solid #d1d5db;
    border-radius: 999px;
    background: #f9fafb;
    color: #111827;
    padding: 9px 12px;
    font-weight: 800;
}

.field-hive-chip.status-strong {
    background: #dcfce7;
    border-color: #86efac;
}

.field-hive-chip.status-weak,
.field-hive-chip.status-watch {
    background: #fef3c7;
    border-color: #fbbf24;
}

.field-hive-chip.status-problem {
    background: #fee2e2;
    border-color: #fca5a5;
}

.field-hive-chip.status-archived {
    opacity: 0.6;
}

.field-hive-editor {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid #e5e7eb;
}

.field-note-card {
    display: grid;
    gap: 10px;
}

.field-tabs {
    position: fixed;
    left: 50%;
    bottom: 0;
    z-index: 1000;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    width: min(100%, 720px);
    transform: translateX(-50%);
    padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
    background: rgba(15, 23, 42, 0.96);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.field-tabs button {
    border: 0;
    border-radius: 12px;
    background: transparent;
    color: #e5e7eb;
    padding: 10px 4px;
    font-size: 0.78rem;
    font-weight: 800;
}

.field-tabs button.active {
    background: #f59e0b;
    color: #111827;
}

@media (max-width: 520px) {
    .field-bulk-form {
        grid-template-columns: 1fr 1fr;
    }

    .field-bulk-form .btn {
        grid-column: 1 / -1;
    }

    .field-card-row {
        flex-direction: column;
    }
}

.account-kicker {
    color: var(--primary);
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.78rem;
    margin: 0 0 8px;
}

.account-muted,
.account-empty,
.account-note {
    color: var(--text-muted);
    line-height: 1.5;
}

.account-form {
    max-width: 460px;
    margin-top: 24px;
}

.account-hero {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 28px;
    border-radius: 24px;
    margin-bottom: 20px;
}

.account-status {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    color: white;
    font-weight: 700;
}

.account-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 18px;
}

.account-stat-card {
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.account-stat-card span {
    display: block;
    color: var(--text-muted);
    font-size: 0.84rem;
    margin-bottom: 8px;
}

.account-stat-card strong {
    display: block;
    color: var(--text);
    font-size: 1.45rem;
    line-height: 1;
}

.account-readiness {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr) auto;
    align-items: center;
    gap: 18px;
    padding: 18px;
    border-radius: 20px;
    border: 1px solid #d1d5db;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
    margin-bottom: 18px;
}

.readiness-main {
    display: flex;
    align-items: center;
    gap: 16px;
    min-width: 0;
}

.readiness-score {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    flex-shrink: 0;
    background: #111827;
    color: #fbbf24;
    font-size: 1.25rem;
    font-weight: 900;
    border: 3px solid rgba(245, 158, 11, 0.45);
}

.readiness-main h2 {
    margin: 0 0 6px;
    color: #111827;
    font-size: 1.25rem;
}

.readiness-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.readiness-check {
    border-radius: 999px;
    padding: 7px 10px;
    font-size: 0.82rem;
    font-weight: 800;
}

.readiness-check.done {
    background: #dcfce7;
    color: #166534;
}

.readiness-check.missing {
    background: #fef3c7;
    color: #92400e;
}

.readiness-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.readiness-actions .btn {
    white-space: nowrap;
    text-align: center;
    text-decoration: none;
}

.account-next-steps {
    padding: 18px;
    border-radius: 20px;
    border: 1px solid #d1d5db;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
    margin-bottom: 18px;
}

.next-step-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.next-step-card {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    padding: 14px;
    border-radius: 16px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
}

.next-step-card strong {
    display: block;
    color: #111827;
    margin-bottom: 4px;
}

.next-step-card p {
    margin: 0;
    color: #4b5563;
    font-size: 0.9rem;
}

.next-step-card .btn {
    flex-shrink: 0;
    white-space: nowrap;
}

.account-tabs {
    display: flex;
    gap: 8px;
    padding: 8px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.75);
    margin-bottom: 18px;
    overflow-x: auto;
}

.account-tab {
    border: none;
    border-radius: 12px;
    background: transparent;
    color: var(--text-muted);
    padding: 10px 14px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
}

.account-tab.active {
    background: #111827;
    color: #fbbf24;
}

.account-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
    gap: 18px;
}

.account-profile-panel {
    grid-column: 1 / -1;
}

.account-section-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.account-section-head.compact {
    align-items: center;
    margin: 6px 0 12px;
}

.account-section-head h3 {
    margin: 0 0 6px;
    font-size: 1.05rem;
}

.account-edit-form {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.account-form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.account-products-editor {
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.55);
    margin-bottom: 16px;
}

.gps-editor {
    margin-bottom: 20px;
}

.gps-editor .account-note {
    margin: 0;
    font-size: 0.86rem;
}

.account-pill {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.14);
    color: var(--primary-hover);
    font-size: 0.82rem;
    font-weight: 800;
    white-space: nowrap;
}

.account-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
}

.account-list-item {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 14px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.76);
}

.account-list-item p {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.account-list-item span {
    color: var(--primary);
    font-weight: 800;
    white-space: nowrap;
}

.account-order-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.order-contact-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.order-contact-actions .btn {
    min-height: 36px;
    padding: 8px 12px;
    text-decoration: none;
}

.order-contact-actions .btn.disabled {
    pointer-events: none;
    opacity: 0.45;
}

.order-status-select {
    min-height: 38px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: white;
    padding: 8px 10px;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
}

.order-status-badge {
    display: inline-flex;
    align-items: center;
    margin-left: 8px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 0.72rem;
    vertical-align: middle;
    background: #e5e7eb;
    color: #374151;
}

.status-new {
    background: rgba(245, 158, 11, 0.16);
    color: #92400e;
}

.status-confirmed {
    background: rgba(59, 130, 246, 0.14);
    color: #1d4ed8;
}

.status-delivered {
    background: rgba(34, 197, 94, 0.14);
    color: #15803d;
}

.status-cancelled {
    background: rgba(239, 68, 68, 0.12);
    color: #b91c1c;
}

/* Buttons */
.btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: none;
    border-radius: 100px;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 48px; /* Tinta optima de atingere */
    justify-content: center;
}

.btn-sm {
    padding: 6px 14px;
    min-height: 38px;
    font-size: 0.85rem;
}

.btn-primary {
    background-color: var(--primary);
    color: white;
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.4);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.5);
}

.btn-secondary {
    background-color: white;
    color: var(--text);
    border: 1px solid #e5e7eb;
}

.btn-secondary:hover {
    background-color: #f9fafb;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.w-full {
    width: 100%;
    justify-content: center;
}

/* Modals */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.modal-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.modal-content.glass {
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    padding: 30px;
    border-radius: 24px;
    width: 100%;
    max-width: 450px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: translateY(0);
    transition: transform 0.3s ease;
}

.modal-overlay.hidden .modal-content {
    transform: translateY(20px);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-shrink: 0;
}

.modal-body {
    overflow-y: auto;
    padding-right: 10px;
    flex: 1;
}

/* Scrollbar styles for the modal body */
.modal-body::-webkit-scrollbar {
    width: 6px;
}
.modal-body::-webkit-scrollbar-track {
    background: transparent;
}
.modal-body::-webkit-scrollbar-thumb {
    background-color: var(--primary);
    border-radius: 10px;
}

.btn-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.2s;
}

.btn-close:hover {
    color: #ef4444;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 8px;
    color: var(--text);
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    min-height: 48px; /* Tinta touch nativa */
    background: rgba(255, 255, 255, 0.9);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.2);
}

.form-helper {
    margin: 7px 0 0;
    color: var(--text-muted);
    font-size: 0.82rem;
    line-height: 1.35;
}

.portal-inventory-editor {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 10px;
}

.portal-product-row {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(110px, 0.7fr) minmax(86px, 0.45fr) minmax(120px, 0.65fr);
    gap: 12px;
    padding: 14px;
    border: 1px solid rgba(148, 163, 184, 0.32);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.08);
}

.product-card-head,
.portal-product-row .image-field,
.product-availability {
    grid-column: 1 / -1;
}

.product-card-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.24);
}

.product-card-head strong {
    display: block;
    color: var(--text);
    font-size: 1rem;
}

.product-card-label {
    display: block;
    margin-bottom: 2px;
    color: var(--text-muted);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.product-remove-btn {
    min-height: 36px;
    padding: 8px 12px;
    border: 1px solid rgba(239, 68, 68, 0.28);
    border-radius: 10px;
    background: #fff1f2;
    color: #b91c1c;
    font-weight: 800;
    cursor: pointer;
}

.product-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.product-field span {
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 800;
}

.product-field input,
.product-field select {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    background: #ffffff;
    color: var(--text);
    font: inherit;
}

.product-availability {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: #f8fafc;
    color: var(--text);
    font-weight: 700;
}

.product-availability input {
    width: 22px;
    height: 22px;
    accent-color: var(--primary);
}

.account-products-empty {
    display: grid;
    gap: 6px;
    padding: 18px;
    border: 1px dashed rgba(148, 163, 184, 0.7);
    border-radius: 14px;
    background: rgba(248, 250, 252, 0.78);
    color: var(--text-muted);
    text-align: center;
}

.account-products-empty strong {
    color: var(--text);
}

#portal-inventory-list .portal-product-row {
    grid-template-columns: 1fr 90px 70px;
    background: rgba(15, 23, 42, 0.65);
    border-color: #334155;
}

#portal-inventory-list .remove-field {
    grid-column: 1 / -1;
    min-height: 38px;
}

.modal-body p {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* Rating Stars */
.stars {
    display: flex;
    gap: 8px;
    font-size: 32px;
    justify-content: center;
    margin-bottom: 20px;
    color: #d1d5db;
    cursor: pointer;
}

.star {
    transition: color 0.2s, transform 0.1s;
}

.star:hover, .star.hovered {
    color: #fbbf24;
    transform: scale(1.1);
}

.star.selected {
    color: var(--primary);
}

/* Leaflet Popup Styling Override */
.leaflet-popup-pane {
    z-index: 30000 !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    pointer-events: none;
}

.leaflet-popup-pane .leaflet-popup {
    pointer-events: auto;
    max-width: calc(100vw - 24px);
}

.leaflet-popup-pane .leaflet-popup.floating-map-popup {
    position: fixed !important;
    transform: none !important;
    bottom: auto !important;
    margin: 0 !important;
}

body.map-popup-open .top-bar,
body.map-popup-open .search-overlay,
body.map-popup-open .results-panel,
body.map-popup-open .bottom-footer,
body.map-popup-open .gdpr-banner {
    z-index: 900 !important;
}

.leaflet-popup-content-wrapper {
    border-radius: 16px !important;
    padding: 10px !important;
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(8px) !important;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15) !important;
}

.leaflet-popup-content {
    margin: 5px 10px !important;
    font-family: 'Inter', sans-serif !important;
}

.popup-custom h3 {
    margin: 0 0 5px 0;
    color: var(--primary-hover);
    font-size: 1.1rem;
}

.popup-custom .rating {
    color: var(--primary);
    font-weight: bold;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.popup-custom p {
    margin: 4px 0;
    font-size: 0.9rem;
    color: var(--text);
}

.popup-custom .products {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin: 10px 0;
    line-height: 1.4;
    background: #f3f4f6;
    padding: 8px;
    border-radius: 8px;
}

.popup-custom button {
    margin-top: 10px;
    width: 100%;
}

.popup-free {
    min-width: 220px;
}

.popup-free h3 {
    margin-bottom: 8px;
}

/* Marker Cluster Overrides */
.marker-cluster-small, .marker-cluster-medium, .marker-cluster-large {
    background-color: rgba(245, 158, 11, 0.6) !important; 
}
.marker-cluster-small div, .marker-cluster-medium div, .marker-cluster-large div {
    background-color: rgba(217, 119, 6, 0.8) !important;
    color: white !important;
    font-family: 'Inter', sans-serif;
    font-weight: bold;
}

@keyframes spin {
    100% { transform: rotate(360deg); }
}

/* Shop Premium Specific Styles */
.shop-body {
    overflow-y: auto; /* Allow scrolling on shop page */
    background: #f9fafb;
    background-image: radial-gradient(circle at top right, rgba(245, 158, 11, 0.1), transparent 400px);
}

.shop-container {
    max-width: 1200px;
    margin: 100px auto 40px; /* Space for fixed header */
    padding: 0 20px;
}

.shop-header.glass-dark {
    background: #111827;
    border: 1px solid #374151;
    color: white;
    border-radius: 24px;
    padding: 40px;
    text-align: left;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
}

.premium-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(245, 158, 11, 0.2);
    color: var(--primary);
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.85rem;
    font-weight: 700;
    border: 1px solid var(--primary);
}

.shop-kicker {
    color: var(--primary);
    font-weight: 700;
    margin-bottom: 8px;
    text-transform: uppercase;
    font-size: 0.8rem;
}

.shop-header h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: #fbbf24;
}

.shop-meta {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 25px;
    color: #d1d5db;
}

.shop-summary {
    max-width: 680px;
    color: #e5e7eb;
    line-height: 1.6;
    margin-bottom: 22px;
}

.public-profile-shell {
    max-width: 1200px;
    margin: 80px auto 50px;
    padding: 0 20px;
}

.public-profile-hero {
    display: block;
    background: #0f172a;
    border: 1px solid rgba(251, 191, 36, 0.22);
    padding: 34px;
    border-radius: 24px;
    margin-bottom: 24px;
    box-shadow: 0 22px 45px rgba(15, 23, 42, 0.28);
}

.public-profile-hero h1 {
    color: #fbbf24;
    font-size: 2.4rem;
    margin: 0 0 14px;
    letter-spacing: 0;
}

.profile-trust-row,
.profile-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.profile-trust-row span {
    padding: 8px 12px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(251, 191, 36, 0.35);
    font-weight: 700;
    font-size: 0.9rem;
}

.profile-signal-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 20px;
}

.profile-signal-grid article {
    padding: 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(251, 191, 36, 0.25);
}

.profile-signal-grid span,
.profile-signal-grid small {
    display: block;
    color: #d1d5db;
    font-size: 0.78rem;
}

.profile-signal-grid strong {
    display: block;
    color: #ffffff;
    font-size: 1rem;
    margin: 5px 0 3px;
}

.profile-actions .btn {
    text-decoration: none;
}

.profile-whatsapp {
    background: #25D366;
    color: white;
}

.public-profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 0.8fr);
    gap: 18px;
}

.public-profile-grid .account-panel.glass {
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid #d1d5db;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.12);
}

.public-profile-grid h2 {
    color: #111827;
}

.public-profile-grid .account-muted,
.profile-info-list p,
.profile-product-mini p {
    color: #374151;
}

.profile-info-list strong,
.profile-product-mini strong {
    color: #111827;
}

.public-profile-wide {
    grid-column: 1 / -1;
}

.profile-product-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.profile-product-mini {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 14px;
    background: #ffffff;
}

.profile-product-basic {
    background: #fff7ed;
    border-color: #fed7aa;
}

.profile-product-mini img {
    width: 58px;
    height: 58px;
    border-radius: 12px;
    object-fit: cover;
}

.profile-product-order {
    margin-left: auto;
    color: #111827;
    background: #fbbf24;
    padding: 8px 10px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
}

.profile-product-mini p,
.profile-info-list p {
    margin: 4px 0 0;
    color: #374151;
}

.profile-mini-map {
    height: 260px;
    margin-top: 18px;
    border-radius: 18px;
    overflow: hidden;
    background: #e5e7eb;
    display: grid;
    place-items: center;
    color: var(--text-muted);
}

.profile-mini-map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

.profile-mobile-actions {
    display: none;
}

.profile-error {
    text-align: center;
    margin: 100px auto;
    max-width: 520px;
}

.shop-call-btn {
    display: inline-flex;
    padding: 12px 30px;
    font-size: 1.1rem;
}

.shop-whatsapp-btn {
    display: inline-flex;
    padding: 12px 30px;
    margin-left: 10px;
    font-size: 1.1rem;
}

.shop-section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.shop-products .shop-section-title h2 {
    margin-bottom: 0;
}

.shop-section-title span {
    color: var(--text-muted);
    font-weight: 600;
}

.shop-products h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--text);
}

.shop-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.product-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid #e5e7eb;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.product-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid #e5e7eb;
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    margin-bottom: 10px;
    font-size: 1.2rem;
    color: var(--text);
}

.product-price {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.product-price strong {
    color: var(--primary-hover);
    font-size: 1.25rem;
}

/* Cart UI */
.floating-cart {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #111827;
    color: #fbbf24;
    border: none;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    cursor: pointer;
    z-index: 1000;
    transition: transform 0.2s, box-shadow 0.2s;
}

.floating-cart.hidden {
    display: none;
}

.floating-cart:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 30px rgba(0,0,0,0.4);
}

#cart-count {
    position: absolute;
    top: 5px;
    right: 5px;
    background: #ef4444;
    color: white;
    font-size: 12px;
    font-weight: bold;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e5e7eb;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-weight: 500;
    margin-bottom: 5px;
}

.cart-item-price {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-btn {
    background: #f3f4f6;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.cart-btn:hover {
    background: #e5e7eb;
}

.cart-total {
    font-size: 1.4rem;
    text-align: right;
    margin-top: 15px;
}

/* GDPR Banner */
.gdpr-banner {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    z-index: 9999;
    background: #111827;
    border: 1px solid #374151;
    color: white;
    padding: 20px;
    border-radius: 20px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    transition: opacity 0.3s ease;
}

.gdpr-content {
    flex: 1 1 300px;
}

.gdpr-content p {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #e5e7eb;
}

.gdpr-content strong {
    color: var(--primary);
}

.gdpr-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.gdpr-actions .btn-secondary {
    color: var(--text);
    background: rgba(255, 255, 255, 0.92);
}

.gdpr-modal {
    max-width: 640px;
}

.privacy-choice {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.74);
    margin-bottom: 14px;
}

.privacy-choice h3 {
    margin-bottom: 6px;
    color: var(--text);
}

.privacy-choice p,
.privacy-note {
    color: var(--text-muted);
    line-height: 1.5;
}

.choice-state {
    flex-shrink: 0;
    padding: 6px 10px;
    border-radius: 999px;
    background: #d1fae5;
    color: #065f46;
    font-size: 0.8rem;
    font-weight: 700;
}

.choice-state.optional {
    background: #fef3c7;
    color: #92400e;
}

.gdpr-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 10px;
}

/* Search UI */
.search-overlay {
    position: absolute;
    top: 90px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    padding: 10px 20px;
    border-radius: 100px;
    border: 1px solid var(--border);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.search-inputs {
    display: flex;
    gap: 15px;
    align-items: center;
}

.input-group {
    display: flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 8px 16px;
    border-radius: 100px;
    border: 1px solid #e5e7eb;
    min-height: 48px;
}

.input-group input {
    border: none;
    outline: none;
    font-family: inherit;
    font-size: 0.95rem;
    width: 200px;
    background: transparent;
}

.input-group svg {
    color: var(--text-muted);
}

.local-products-rail {
    position: absolute;
    top: 158px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 999;
    width: min(920px, calc(100vw - 40px));
    padding: 10px;
    border-radius: 22px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.14);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.local-products-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 4px 8px;
    color: #111827;
    font-size: 0.86rem;
    font-weight: 800;
}

.local-products-head button {
    width: 26px;
    height: 26px;
    border: 0;
    border-radius: 999px;
    background: rgba(17, 24, 39, 0.08);
    color: #111827;
    font-size: 1.2rem;
    line-height: 1;
    cursor: pointer;
}

.local-products-list {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: thin;
}

.local-product-card {
    flex: 0 0 176px;
    min-height: 96px;
    display: grid;
    grid-template-columns: 62px 1fr;
    gap: 10px;
    align-items: center;
    padding: 8px;
    border: 1px solid #f3f4f6;
    border-radius: 16px;
    background: #ffffff;
    color: #111827;
    text-decoration: none;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.local-product-card img {
    width: 62px;
    height: 76px;
    object-fit: cover;
    border-radius: 12px;
    background: #fef3c7;
}

.local-product-info {
    min-width: 0;
}

.local-product-info strong {
    display: block;
    font-size: 0.86rem;
    line-height: 1.15;
    color: #111827;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.local-product-info span {
    display: block;
    margin-top: 4px;
    font-size: 0.72rem;
    line-height: 1.2;
    color: var(--text-muted);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.local-product-price {
    margin-top: 6px;
    font-size: 0.76rem;
    font-weight: 800;
    color: var(--primary-hover);
}

.local-product-badge {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin-top: 5px;
    padding: 2px 6px;
    border-radius: 999px;
    background: #111827;
    color: #fbbf24 !important;
    font-size: 0.65rem !important;
    font-weight: 800;
}

/* Results Panel */
.results-panel {
    position: absolute;
    top: 160px;
    left: 20px;
    z-index: 1000;
    width: 350px;
    max-height: calc(100vh - 180px);
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border-radius: 24px;
    border: 1px solid var(--border);
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
    display: flex;
    flex-direction: column;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.results-panel.hidden {
    opacity: 0;
    pointer-events: none;
    transform: translateX(-20px);
}

.results-header {
    padding: 20px;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.results-header h3 {
    font-size: 1.1rem;
    color: var(--text);
    margin: 0;
}

.results-list {
    overflow-y: auto;
    padding: 10px;
    flex: 1;
}

.result-item {
    padding: 15px;
    background: white;
    border-radius: 16px;
    margin-bottom: 10px;
    border: 1px solid #f3f4f6;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: pointer;
}

.result-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.result-item h4 {
    margin: 0 0 5px 0;
    color: var(--primary-hover);
    font-size: 1.05rem;
}

.result-distance {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    font-weight: 500;
}

.result-info {
    font-size: 0.9rem;
    color: var(--text);
    margin-bottom: 4px;
}


/* === MOBILE LAYOUT === */
@media (max-width: 768px) {
    /* Search bar merge la TOP pe mobile, sub header */
    .search-overlay {
        top: 80px;
        bottom: auto;
        left: 10px;
        right: 10px;
        transform: none;
        border-radius: 20px;
        padding: 10px 15px;
    }
    .local-products-rail {
        top: 188px;
        left: 10px;
        right: 10px;
        width: auto;
        transform: none;
        padding: 9px;
        border-radius: 20px;
    }
    .local-products-head {
        font-size: 0.8rem;
        padding-bottom: 7px;
    }
    .local-product-card {
        flex-basis: 160px;
        grid-template-columns: 56px 1fr;
        min-height: 88px;
        gap: 8px;
    }
    .local-product-card img {
        width: 56px;
        height: 68px;
    }
    .search-inputs {
        flex-direction: column;
        gap: 8px;
    }
    .input-group {
        width: 100%;
    }
    .input-group input {
        width: 100%;
    }
    /* Formulare mai adecvate pentru mobil - ascundem zoom */
    .leaflet-control-zoom {
        display: none !important;
    }

    /* Panoul de rezultate "Bottom Sheet" */
    .results-panel {
        top: auto;
        bottom: 55px; /* Deasupra footerului compact */
        left: 10px;
        right: 10px;
        width: auto;
        max-height: 55vh; /* Ocupa cel mult jumatate de ecran de jos, eliberand harta sus */
        border-radius: 24px;
        box-shadow: 0 -8px 30px rgba(0,0,0,0.15);
        background: var(--surface);
        z-index: 1001; 
    }
    
    /* Modale Full pe Mobile */
    .modal-content.glass {
        margin: 15px;
        padding: 24px;
        max-width: 100%;
        max-height: calc(100vh - 30px);
        border-radius: 24px;
    }

    /* Magazin intr-o coloana */
    .shop-container {
        margin-top: 32px;
        padding: 0 14px;
    }
    .shop-header.glass-dark {
        padding: 22px;
        border-radius: 20px;
    }
    .shop-header.glass-dark .premium-badge {
        position: static;
        display: inline-flex;
        width: fit-content;
        margin-bottom: 14px;
    }
    .shop-kicker {
        margin: 0 0 8px;
        line-height: 1.25;
    }
    .shop-header h1 {
        font-size: 1.9rem;
        line-height: 1.12;
        margin-bottom: 12px;
    }
    .shop-meta {
        gap: 8px;
        margin-bottom: 16px;
    }
    .shop-meta span {
        width: 100%;
    }
    .shop-call-btn,
    .shop-whatsapp-btn {
        width: 100%;
        justify-content: center;
        margin-left: 0;
        margin-top: 8px;
    }
    .shop-grid {
        grid-template-columns: 1fr;
    }
    .public-profile-hero,
    .public-profile-grid,
    .profile-product-list {
        grid-template-columns: 1fr;
    }
    .profile-signal-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .profile-actions {
        display: none;
    }
    .profile-product-mini {
        align-items: flex-start;
    }
    .profile-product-order {
        align-self: center;
    }
    .profile-mobile-actions {
        position: sticky;
        bottom: 12px;
        z-index: 40;
        display: flex;
        gap: 8px;
        padding: 10px;
        margin-top: 16px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.96);
        border: 1px solid #e5e7eb;
        box-shadow: 0 16px 32px rgba(15, 23, 42, 0.18);
    }
    .profile-mobile-actions .btn {
        flex: 1;
        padding: 10px 8px;
        text-align: center;
        text-decoration: none;
    }
    .account-hero,
    .account-section-head,
    .account-list-item {
        flex-direction: column;
        align-items: flex-start;
    }
    .account-status {
        align-items: flex-start;
    }
    .account-readiness {
        grid-template-columns: 1fr;
    }
    .next-step-list {
        grid-template-columns: 1fr;
    }
    .next-step-card {
        align-items: stretch;
        flex-direction: column;
    }
    .readiness-actions {
        flex-direction: row;
        flex-wrap: wrap;
    }
    .account-form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .portal-product-row {
        grid-template-columns: 1fr;
        padding: 12px;
    }
    .product-card-head {
        align-items: flex-start;
    }
    .product-remove-btn {
        flex: 0 0 auto;
    }
    .account-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .account-grid {
        grid-template-columns: 1fr;
    }
    .account-order-actions {
        align-items: flex-start;
    }
    .order-contact-actions {
        justify-content: flex-start;
        width: 100%;
    }
    .order-contact-actions .btn {
        flex: 1;
        text-align: center;
    }
    /* Footer-ul devine compact pe mobile, nu îl ascundem de tot */
    .bottom-footer {
        bottom: 10px;
        padding: 8px 16px;
        gap: 15px;
        font-size: 0.8rem;
        z-index: 999;
    }
    #footer-rights {
        display: none; /* Ascundem textul de copyright pentru a salva spațiu */
    }
}

@media (max-width: 600px) {
    .hide-on-mobile {
        display: none !important;
    }
    /* Top bar devine mai compact pe telefon */
    .top-bar {
        top: 10px;
        left: 10px;
        right: 10px;
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 6px;
        padding: 8px 14px;
        border-radius: 14px;
        align-items: flex-start;
        min-height: 72px;
    }
    .logo-container {
        min-width: 0;
        flex: 1;
    }
    .logo {
        font-size: 1.2rem;
        gap: 5px;
    }
    .logo svg { width: 18px; height: 18px; }
    .logo-container .logo-subtitle.hide-on-mobile {
        display: block !important;
        margin: 1px 0 0 24px;
        max-width: 118px;
        font-size: 0.66rem;
        line-height: 1.12;
        color: #374151;
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
    }
    .actions {
        gap: 6px;
        flex-shrink: 0;
    }
    .language-switcher {
        padding: 7px 8px;
        gap: 3px;
    }
    .language-switcher select {
        max-width: 44px;
        font-size: 0.78rem;
    }
    .actions .btn {
        padding: 8px 12px;
        font-size: 0.82rem;
    }
    /* Butonul "Găsește-mă" - doar iconița pe mobile */
    #btn-locate #locate-text { display: none; }
    #btn-locate {
        padding: 8px 10px;
        min-width: 38px;
        justify-content: center;
    }
    /* Butonul "Intră în Cont" - se compactează padding-ul pe mobile */
    #btn-login {
        font-size: 0.75rem;
        padding: 8px 10px;
        white-space: nowrap;
    }

    /* Search bar se ajusteaza sub headerul compact */
    .search-overlay {
        top: 94px;
        padding: 7px 8px;
        border-radius: 16px;
    }
    .local-products-rail {
        top: 188px;
    }
    .search-inputs {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 6px;
        align-items: stretch;
    }
    .search-inputs .input-group {
        min-height: 38px;
        padding: 6px 10px;
        gap: 6px;
        border-radius: 14px;
    }
    .search-inputs .input-group svg {
        width: 16px;
        height: 16px;
        flex: 0 0 auto;
    }
    .search-inputs .input-group input {
        font-size: 0.82rem;
    }
    #btn-search {
        grid-column: 2;
        grid-row: 1 / span 2;
        min-width: 56px;
        padding: 0 10px;
        border-radius: 14px;
        font-size: 0.82rem;
    }
    /* Panoul de rezultate respecta bottom sheet pe 600px */
    .results-panel {
        bottom: 50px;
        max-height: 50vh;
    }
}

/* Floating Footer overlay */
.bottom-footer {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    display: flex;
    gap: 20px;
    align-items: center;
    padding: 10px 24px;
    background: var(--surface);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--border);
    border-radius: 100px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    font-size: 0.85rem;
    white-space: nowrap;
}

.bottom-footer a {
    color: var(--primary-hover);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.bottom-footer a:hover {
    color: var(--primary);
    text-decoration: underline;
}

.bottom-footer span {
    color: var(--text-muted);
}

@media (max-width: 768px) {
    /* Footer-ul pe shop page ramane vizibil si se adapteaza */
    .shop-body .bottom-footer {
        display: flex !important;
        flex-direction: column;
        bottom: 10px;
        gap: 5px;
        border-radius: 15px;
        padding: 10px 15px;
    }
}
