/* Frontend styles for Treomax Bilet Visual System */

/* Main Container */
.tbvs-seatmap-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Attendance Counter */
.tbvs-attendance-counter {
    border-radius: 8px;
    padding: 20px;
    margin: 0 auto;
    margin-bottom: 25px;
    border: 1px solid #000;
    animation: slideDown 0.5s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.tbvs-attendance-inner {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #000;
}

.tbvs-attendance-text {
    font-size: 16px;
    line-height: 1.4;
}

.tbvs-attendance-text strong {
    display: inline-block;
    margin-left: 8px;
    color: #2B74FF;
}

/* Dates Section */
.tbvs-dates-section {
    margin-bottom: 30px;
}

.tbvs-dates-section h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 1.2em;
    font-weight: 600;
}

.tbvs-dates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
}

.tbvs-date-item {
    padding: 12px 8px;
    border: 2px solid #ddd;
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #fff;
    min-height: 90px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.tbvs-date-item:hover {
    border-color: #2196f3;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.tbvs-date-item.selected {
    border-color: #4caf50;
    background: #e8f5e8;
    color: #2e7d32;
}

.tbvs-date-item.unavailable {
    background: #f5f5f5;
    color: #999;
    cursor: not-allowed;
    opacity: 0.6;
}

.tbvs-date-item.unavailable:hover {
    transform: none;
    box-shadow: none;
    border-color: #ddd;
}

.tbvs-date-item.non-working {
    background: #ffeaa7;
    border-color: #fdcb6e;
    color: #2d3436;
    cursor: not-allowed;
    opacity: 0.8;
}

.tbvs-date-item.non-working:hover {
    background: #ffeaa7;
    transform: none;
    box-shadow: none;
    border-color: #fdcb6e;
}

.tbvs-date-item.non-working .tbvs-date-availability {
    font-weight: 600;
    color: #e17055;
}

.tbvs-date-day {
    font-size: 0.75em;
    color: #888;
    font-weight: 500;
    text-transform: uppercase;
}

.tbvs-date-display {
    font-weight: 600;
    font-size: 0.9em;
}

.tbvs-date-availability {
    font-size: 0.8em;
    color: #666;
}

.tbvs-date-item.unavailable .tbvs-date-availability {
    color: #999;
}

/* Date Select Styles */
.tbvs-date-select-container {
    margin-bottom: 20px;
}

.tbvs-date-select-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 1em;
}

.tbvs-date-select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: all 0.2s ease;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 12px center;
    background-repeat: no-repeat;
    background-size: 16px;
    padding-right: 40px;
}

.tbvs-date-select:hover {
    border-color: #2196f3;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tbvs-date-select:focus {
    outline: none;
    border-color: #2196f3;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.1);
}

.tbvs-date-select option:disabled {
    color: #999;
    background: #f5f5f5;
}

/* Map Section */
.tbvs-map-section {

    grid-template-columns: 1fr 300px;
    gap: 30px;
    align-items: start;
}
.tbvs-map-section image{
    width: 100%;
}
.tbvs-map-container h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 1.3em;
    font-weight: 600;
}

/* Map Wrapper */
.tbvs-map-wrapper {
    position: relative;
    border: 2px solid #ddd;
    border-radius: 8px;
    background: #f8f8f8;
    min-height: 400px;
    overflow: hidden;
}

#tbvs-seat-map-svg {
    width: 100%;
    height: auto;
    display: block;
    background: #fff;
    cursor: pointer;
}

/* SVG Shapes - Seat Status Colors */
.tbvs-seat {
    cursor: pointer;
    stroke-width: 2;
    transition: all 0.2s ease;
}

.tbvs-seat.available {
    fill: rgba(227, 242, 253, 0.4);
    stroke: rgba(33, 150, 243, 0.4);
}

.tbvs-seat.available:hover {
    fill: rgba(227, 242, 253, 0.6);
    stroke: rgba(33, 150, 243, 0.6);
    stroke-width: 3;
}

.tbvs-seat.partial {
    fill: url(#tbvs-partial-pattern);
    stroke: #ff9800;
}

.tbvs-seat.partial:hover {
    stroke: #f57c00;
    stroke-width: 3;
}

.tbvs-seat.unavailable {
    fill: #ffcdd2;
    stroke: #f44336;
    cursor: not-allowed;
    opacity: 0.7;
}

.tbvs-seat.held {
    fill: url(#tbvs-held-pattern);
    stroke: #ff9800;
    cursor: not-allowed;
}

.tbvs-seat.selected {
    fill: url(#tbvs-selected-gradient);
    stroke: #2e7d32;
    stroke-width: 3;
    filter: url(#tbvs-glow);
}

/* Loading States */
.tbvs-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: #666;
    font-size: 1.1em;
}

.tbvs-loading::before {
    content: "";
    width: 24px;
    height: 24px;
    border: 3px solid #ddd;
    border-top: 3px solid #2196f3;
    border-radius: 50%;
    animation: tbvs-spin 1s linear infinite;
    margin-right: 12px;
}

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

/* Legend */
.tbvs-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 15px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
}

.tbvs-legend-item {
    display: flex;
    align-items: center;
    font-size: 0.9em;
}

.tbvs-legend-color {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    margin-right: 8px;
    border: 2px solid #333;
}

.tbvs-legend-color.tbvs-available {
    background: #e3f2fd;
    border-color: #2196f3;
}

.tbvs-legend-color.tbvs-partial {
    background: #fff3e0;
    border-color: #ff9800;
    background-image: repeating-linear-gradient(45deg, transparent, transparent 2px, #ff9800 2px, #ff9800 4px);
}

.tbvs-legend-color.tbvs-unavailable {
    background: #ffcdd2;
    border-color: #f44336;
}

.tbvs-legend-color.tbvs-selected {
    background: linear-gradient(135deg, #4caf50, #2e7d32);
    border-color: #2e7d32;
}

/* Sidebar */
.tbvs-sidebar {
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    height: fit-content;
    position: sticky;
    top: 20px;
}

.tbvs-sidebar h4 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 1.1em;
    font-weight: 600;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

/* Selected Seats */
.tbvs-selected-seats {
    margin-bottom: 20px;
    min-height: 60px;
}

.tbvs-no-selection {
    color: #999;
    font-style: italic;
    text-align: center;
    padding: 20px 0;
}

.tbvs-selected-seat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    margin-bottom: 10px;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 6px;
}

.tbvs-seat-info {
    flex: 1;
}

.tbvs-seat-name {
    font-weight: 600;
    color: #333;
    margin-bottom: 2px;
}

.tbvs-seat-details {
    font-size: 0.85em;
    color: #666;
}

.tbvs-quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.tbvs-quantity-btn {
    width: 28px;
    height: 28px;
    border: 1px solid #ddd;
    background: #fff;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    transition: all 0.2s ease;
}

.tbvs-quantity-btn:hover {
    background: #f0f0f0;
    border-color: #999;
}

.tbvs-quantity-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.tbvs-quantity-display {
    min-width: 30px;
    text-align: center;
    font-weight: 600;
}

.tbvs-seat-price {
    font-weight: 600;
    color: #2e7d32;
    margin-left: 10px;
}

/* Total Section */
.tbvs-total-section {
    margin-bottom: 20px;
    padding: 15px;
    background: #f0f8f0;
    border: 1px solid #4caf50;
    border-radius: 6px;
}

.tbvs-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.1em;
    font-weight: 600;
    color: #2e7d32;
}

/* Action Buttons */
.tbvs-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tbvs-actions .button {
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    text-decoration: none;
}

.tbvs-clear-selection {
    background: #f5f5f5;
    color: #666;
    border: 1px solid #ddd;
}

.tbvs-clear-selection:hover {
    background: #eeeeee;
    color: #333;
}

.tbvs-add-to-cart {
    background: #4caf50;
    color: #fff;
}

.tbvs-add-to-cart:hover {
    background: #45a049;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(76, 175, 80, 0.3);
}

.tbvs-add-to-cart:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Tooltip */
.tbvs-tooltip {
    position: fixed !important;
    background: rgba(0, 0, 0, 0.9) !important;
    color: #fff !important;
    padding: 12px 15px !important;
    border-radius: 8px !important;
    font-size: 0.9em !important;
    line-height: 1.4 !important;
    max-width: 280px !important;
    z-index: 999999 !important;
    pointer-events: none !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    transition: none !important;
}

.tbvs-tooltip.show {
    opacity: 1;
    transform: translateY(0);
}

.tbvs-tooltip-title {
    font-weight: 600;
    margin-bottom: 6px;
    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 4px;
}

.tbvs-tooltip-info {
    margin-bottom: 8px;
}

.tbvs-tooltip-availability {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.tbvs-tooltip-price {
    font-weight: 600;
    color: #4caf50;
    font-size: 1.1em;
}

.tbvs-tooltip-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: 500;
    text-transform: uppercase;
}

.tbvs-tooltip-status.available {
    background: rgba(76, 175, 80, 0.2);
    color: #4caf50;
}

.tbvs-tooltip-status.partial {
    background: rgba(255, 152, 0, 0.2);
    color: #ff9800;
}

.tbvs-tooltip-status.unavailable {
    background: rgba(244, 67, 54, 0.2);
    color: #f44336;
}

/* Map Controls */
.tbvs-map-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.tbvs-zoom-btn {
    width: 40px;
    height: 40px;
    background: #fff;
    border: 2px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    color: #333;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    user-select: none;
}

.tbvs-zoom-btn:hover {
    background: #f5f5f5;
    border-color: #2196f3;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.tbvs-zoom-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.tbvs-zoom-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* Map Container with Drag */
.tbvs-map-section {
    position: relative;
    overflow: hidden;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #f9f9f9;
}

.tbvs-map-section.draggable {
    cursor: grab;
}

.tbvs-map-section.dragging {
    cursor: grabbing;
}

.tbvs-map-wrapper {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

#tbvs-seat-map-svg {
    width: 100%;
    height: 100%;
    transition: transform 0.2s ease;
    transform-origin: center center;
}

#tbvs-seat-map-svg.no-transition {
    transition: none;
}

/* New Tab Button */
.tbvs-open-new-tab {
    display: inline-block;
    margin-left: 10px;
    padding: 8px 16px;
    background: #2196f3;
    color: #fff;
    text-decoration: none;
    border-radius: 6px;
    font-size: 0.9em;
    transition: all 0.2s ease;
}

.tbvs-open-new-tab:hover {
    background: #1976d2;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(33, 150, 243, 0.3);
    color: #fff;
    text-decoration: none;
}

/* Fullscreen Popup Modal */
.tbvs-fullscreen-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 10000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tbvs-fullscreen-modal.show {
    display: flex;
    opacity: 1;
}

.tbvs-fullscreen-content {
    width: 100%;
    height: 100%;
    position: relative;
    background: #fff;
    display: flex;
    flex-direction: column;
}

.tbvs-fullscreen-header {
    background: #fff;
    padding: 15px 20px;
    border-bottom: 1px solid #ddd;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    z-index: 999;
    flex-shrink: 0;
}

.tbvs-fullscreen-title {
    margin: 0;
    font-size: 1.8em;
    color: #333;
    float: left;
}

.tbvs-fullscreen-date {
    float: right;
    font-size: 1.1em;
    color: #666;
    margin-top: 8px;
    padding: 8px 12px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.tbvs-fullscreen-date strong {
    color: #333;
    font-size: 1em;
    margin-top: 5px;
}

.tbvs-fullscreen-map-container {
    flex: 1;
    display: flex;
    position: relative;
    overflow: hidden;
}

.tbvs-modal-map-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    position: relative;
}

.tbvs-modal-map-wrapper .tbvs-map-section {
    flex: 1;
    margin-right: 0;
}

.tbvs-modal-map-wrapper .tbvs-sidebar {
    width: 300px;
    flex-shrink: 0;
}

.tbvs-fullscreen-map-container .tbvs-seatmap-container {
    width: 100%;
    height: 100%;
    padding: 0;
    margin: 0;
    max-width: none;
}

.tbvs-fullscreen-map-container .tbvs-map-section {
    height: 100%;
    border: none;
    border-radius: 0;
    background: #fff;
    margin: 0;
}

.tbvs-fullscreen-map-container .tbvs-map-wrapper {
    height: 100%;
}

.tbvs-fullscreen-map-container #tbvs-seat-map-svg {
    width: 100%;
    height: 100%;
}

.tbvs-fullscreen-map-container .tbvs-sidebar {
    position: fixed;
    top: 80px;
    right: 20px;
    width: 320px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 999;
}

.tbvs-fullscreen-map-container .tbvs-legend {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: #fff;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 999;
}

.tbvs-close-fullscreen {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #f44336;
    color: #fff;
    border: none;
    padding: 12px 18px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    z-index: 999;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(244, 67, 54, 0.3);
}

.tbvs-close-fullscreen:hover {
    background: #d32f2f;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(244, 67, 54, 0.4);
}

.tbvs-close-fullscreen:active {
    transform: translateY(0);
}

/* Hide dates section in fullscreen */
.tbvs-fullscreen-modal .tbvs-dates-section {
    display: none !important;
}

/* Hide any duplicate containers in modal */
.tbvs-fullscreen-modal .tbvs-seatmap-container {
    display: contents;
}

/* Ensure clean layout in modal */
.tbvs-fullscreen-modal .tbvs-messages {
    display: none;
}

/* Fix tooltip z-index in fullscreen modal - MUST be above modal (999) */
.tbvs-fullscreen-modal .tbvs-tooltip,
.tbvs-tooltip {
    z-index: 10003 !important;
    position: fixed !important;
}

/* Ensure tooltip is always visible in modal */
body .tbvs-tooltip {
    z-index: 10003 !important;
    position: fixed !important;
}

/* Hide selected date indicators in fullscreen */
.tbvs-fullscreen-modal .tbvs-date-item.selected {
    display: none !important;
}

/* Simple Map Styles */
.tbvs-simple-map-container {
    width: 100%;
    margin-top: 20px;
}

.tbvs-simple-map-stats {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 15px 0 20px 0;
    font-size: 14px;
    color: #495057;
    text-align: center;
}

.tbvs-simple-map-stats .tbvs-available-count {
    font-weight: 600;
    color: #28a745;
}

.tbvs-simple-map-stats .tbvs-max-count {
    font-weight: 600;
    color: #6c757d;
}

.tbvs-simple-places-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.tbvs-simple-place {
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    background: #fff;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
}

.tbvs-simple-place:hover {
    border-color: #2196f3;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.tbvs-simple-place.selected {
    border-color: #4caf50;
    background: #f8fff8;
    box-shadow: 0 4px 16px rgba(76, 175, 80, 0.2);
}

.tbvs-simple-place.unavailable {
    border-color: #ccc;
    background: #f5f5f5;
    opacity: 0.6;
    cursor: not-allowed;
}

.tbvs-simple-place.unavailable:hover {
    transform: none;
    border-color: #ccc;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tbvs-quantity-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #4caf50;
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(76, 175, 80, 0.4);
}

.tbvs-simple-place-photo {
    width: 100%;
    height: 180px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 15px;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tbvs-simple-place-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.tbvs-simple-place:hover .tbvs-simple-place-photo img {
    transform: scale(1.05);
}

.tbvs-no-photo {
    color: #999;
    font-size: 14px;
    text-align: center;
    padding: 20px;
    background: #f8f8f8;
    border: 2px dashed #ddd;
    border-radius: 8px;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tbvs-simple-place-info {
    margin-bottom: 15px;
}

.tbvs-simple-place-name {
    font-size: 1.3em;
    font-weight: 600;
    color: #333;
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.tbvs-simple-place-description {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 12px 0;
    min-height: 40px;
}

.tbvs-simple-place-price {
    display: flex;
    align-items: baseline;
    gap: 5px;
    margin-bottom: 8px;
}

.tbvs-price-amount {
    font-size: 1.4em;
    font-weight: 700;
    color: #2196f3;
}

.tbvs-currency {
    font-size: 1em;
    color: #666;
    font-weight: 500;
}

.tbvs-simple-place-status {
    font-size: 13px;
    color: #666;
}

.tbvs-available-count {
    font-weight: 600;
    color: #4caf50;
}

.tbvs-simple-place-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-top: 15px;
}

.tbvs-quantity-btn {
    width: 40px;
    height: 40px;
    border: 2px solid #2196f3;
    background: #fff;
    color: #2196f3;
    border-radius: 50%;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.tbvs-quantity-btn:hover:not(:disabled) {
    background: #2196f3;
    color: #fff;
    transform: scale(1.1);
}

.tbvs-quantity-btn:disabled {
    border-color: #ccc;
    color: #ccc;
    cursor: not-allowed;
    opacity: 0.5;
}

.tbvs-quantity-btn.processing {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
    cursor: wait !important;
}

.tbvs-quantity-btn.processing::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid #2196f3;
    border-top-color: transparent;
    border-radius: 50%;
    animation: tbvs-spin 0.6s linear infinite;
}

@keyframes tbvs-spin {
    to { transform: rotate(360deg); }
}

.tbvs-quantity-display {
    font-size: 1.2em;
    font-weight: 600;
    color: #333;
    min-width: 30px;
    text-align: center;
    padding: 8px 12px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
}

.tbvs-unavailable-text {
    color: #999;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    padding: 10px;
}

.tbvs-no-places {
    text-align: center;
    color: #666;
    font-size: 16px;
    padding: 40px 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 2px dashed #ddd;
}

/* Responsive design for simple map */
@media (max-width: 768px) {
    .tbvs-simple-places-list {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 15px 0;
    }
    
    .tbvs-simple-place {
        padding: 15px;
    }
    
    .tbvs-simple-place-photo {
        height: 150px;
        margin-bottom: 12px;
    }
    
    .tbvs-simple-place-name {
        font-size: 1.2em;
    }
    
    .tbvs-simple-place-controls {
        gap: 10px;
        padding: 12px;
    }
    
    .tbvs-quantity-btn {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
}

.tbvs-fullscreen-modal .tbvs-date-item {
    display: none !important;
}

/* Loading state for fullscreen mode */
body.loading {
    cursor: wait;
    overflow: hidden;
}

body.loading::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

body.loading::after {
    content: "";
    position: fixed;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 4px solid #ddd;
    border-top: 4px solid #2196f3;
    border-radius: 50%;
    animation: tbvs-spin 1s linear infinite;
    z-index: 10000;
}

/* Fix map controls positioning in fullscreen modal */
.tbvs-fullscreen-modal .tbvs-map-controls {
    position: fixed !important;
    top: 100px !important;
    right: 20px !important;
    z-index: 10001 !important;
}

/* Selected dates are now managed via JavaScript */

/* Price breakdown styles */
.tbvs-price-breakdown {
margin-top: 15px;
padding: 15px;
background: #f8f9fa;
border-radius: 5px;
border: 1px solid #e9ecef;
}

.tbvs-base-price-row,
.tbvs-markup-price-row,
.tbvs-total-price-row {
display: flex;
justify-content: space-between;
margin-bottom: 8px;
padding: 5px 0;
}

.tbvs-base-price-row {
    color: #495057;
    font-size: 0.9em;
}

.tbvs-markup-price-row {
    color: #6c757d;
    font-size: 0.9em;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 8px;
    margin-bottom: 10px;
}

.tbvs-total-price-row {
    border-top: 1px solid #e0e0e0;
    padding-top: 5px;
    margin-top: 5px;
    font-weight: bold;
}

/* Simple price display (when markup is hidden) */
.tbvs-price-simple {
    border-top: 1px solid #e0e0e0;
    padding-top: 10px;
    margin-top: 10px;
}

.tbvs-price-simple .tbvs-total-price-row {
    border-top: none;
    padding-top: 0;
    margin-top: 0;
}

/* Simple tooltip price (when markup is hidden) */
.tbvs-tooltip-price {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 13px;
}

/* Informational notes for markup */
.tbvs-tooltip-info-note,
.tbvs-info-note {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    font-style: italic;
    margin-top: 3px;
}

.tbvs-info-note {
    color: #6c757d;
    text-align: right;
    margin-top: 5px;
}

/* WooCommerce checkout informational markup */
.woocommerce-cart-form__cart-item .wc-block-cart-item__total,
.woocommerce-checkout .wc-block-components-order-summary-item__total {
    display: block; /* Ensure fee display is visible */
}

/* Style for informational fee (markup) */
tr.fee:has(th:contains("додається платіжною системою")) th {
    color: #666;
    font-style: italic;
}

tr.fee:has(th:contains("додається платіжною системою")) td {
    color: #666;
    font-style: italic;
}

/* Style for informational fee row added by JS */
.tbvs-informational-fee {
    border-top: 1px solid #e0e0e0;
}

.tbvs-informational-fee .wc-block-components-totals-item__label {
    color: #666;
    font-style: italic;
    font-size: 0.95em;
}

.tbvs-informational-fee .wc-block-components-totals-item__value {
    color: #666;
    font-style: italic;
    font-size: 0.95em;
}

/* Tooltip price breakdown */
.tbvs-tooltip-price-breakdown {
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.tbvs-tooltip-base-price,
.tbvs-tooltip-markup-price,
.tbvs-tooltip-total-price {
    margin: 2px 0;
    font-size: 12px;
}

.tbvs-tooltip-base-price {
    color: rgba(255, 255, 255, 0.8);
}

.tbvs-tooltip-markup-price {
    color: rgba(255, 255, 255, 0.7);
}

.tbvs-tooltip-total-price {
margin-top: 6px;
padding-top: 6px;
border-top: 1px solid rgba(255, 255, 255, 0.3);
color: #fff;
font-weight: bold;
}

/* Enhanced seat details to show base price + markup */
.tbvs-seat-details {
    font-size: 12px;
    color: #666;
    margin-top: 4px;
}

/* Hide regular map when fullscreen mode is enabled */
.tbvs-seatmap-container.fullscreen-enabled .tbvs-map-section {
    display: none;
}

.tbvs-seatmap-container.fullscreen-enabled .tbvs-sidebar {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .tbvs-map-controls {
        top: 5px;
        right: 5px;
    }
    
    .tbvs-zoom-btn {
        width: 35px;
        height: 35px;
        font-size: 16px;
    }
    
    .tbvs-fullscreen-map-container .tbvs-sidebar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        top: auto;
        width: 100%;
        max-height: 50vh;
        border-radius: 12px 12px 0 0;
    }
    
    .tbvs-fullscreen-map-container .tbvs-legend {
        bottom: auto;
        top: 80px;
        left: 10px;
        right: auto;
    }
    
    .tbvs-close-fullscreen {
        top: 10px;
        right: 10px;
        padding: 10px 14px;
        font-size: 12px;
    }
}

.tbvs-tooltip-status.held {
    background: rgba(255, 152, 0, 0.2);
    color: #ff9800;
}

/* Messages */
.tbvs-messages {
    margin-top: 15px;
}

.tbvs-message {
    padding: 12px 15px;
    margin-bottom: 10px;
    border-radius: 6px;
    border-left: 4px solid;
    font-size: 0.9em;
}

.tbvs-message.success {
    background: #d4edda;
    color: #155724;
    border-color: #28a745;
}

.tbvs-message.error {
    background: #f8d7da;
    color: #721c24;
    border-color: #dc3545;
}

.tbvs-message.warning {
    background: #fff3cd;
    color: #856404;
    border-color: #ffc107;
}

.tbvs-message.info {
    background: #d1ecf1;
    color: #0c5460;
    border-color: #17a2b8;
}

/* Responsive Design */
@media (max-width: 768px) {
    .tbvs-seatmap-container {
        padding: 15px;
    }
    
    .tbvs-dates-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
    }
    
    .tbvs-date-item {
        padding: 10px 6px;
        min-height: 70px;
        font-size: 0.9em;
    }
    
    .tbvs-map-section {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .tbvs-sidebar {
        position: static;
        order: -1;
    }
    
    .tbvs-legend {
        gap: 10px;
    }
    
    .tbvs-legend-item {
        font-size: 0.8em;
    }
    
    .tbvs-selected-seat {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .tbvs-quantity-controls {
        align-self: flex-end;
    }
}

@media (max-width: 480px) {
    .tbvs-dates-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tbvs-date-item {
        min-height: 60px;
        font-size: 0.8em;
    }
    
    .tbvs-sidebar {
        padding: 15px;
    }
    
    .tbvs-legend {
        flex-direction: column;
        gap: 8px;
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .tbvs-seat {
        stroke-width: 1.5;
    }
    
    .tbvs-seat:hover,
    .tbvs-seat.selected {
        stroke-width: 2.5;
    }
}

/* Reservation Timer */
.tbvs-reservation-timer {
    position: fixed;
    top: 20px!important;
    bottom: auto!important;
    right: 20px;
    background: #ff5722;
    color: #fff;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    box-shadow: 0 4px 12px rgba(255, 87, 34, 0.3);
    z-index: 9;
    display: none;
    animation: slideInRight 0.3s ease;
    min-width: 200px;
    text-align: center;
}

.tbvs-reservation-timer.show {
    display: block;
}

.tbvs-reservation-timer.warning {
    background: #ff9800;
    animation: pulse 1s infinite;
}

.tbvs-reservation-timer.critical {
    background: #f44336;
    animation: pulse 0.5s infinite;
}

.tbvs-timer-text {
    display: block;
    font-size: 12px;
    margin-bottom: 4px;
    opacity: 0.9;
}

.tbvs-timer-countdown {
    display: block;
    font-size: 18px;
    font-weight: 700;
    font-family: 'Courier New', monospace;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* Mobile responsive timer */
@media (max-width: 768px) {
    .tbvs-reservation-timer {
        top: 10px;
        right: 10px;
        left: 10px;
        right: 10px;
        min-width: auto;
        padding: 10px 15px;
        font-size: 13px;
    }
    
    .tbvs-timer-countdown {
        font-size: 16px;
    }
}

/* Print Styles */
@media print {
    .tbvs-sidebar,
    .tbvs-actions,
    .tbvs-messages,
    .tbvs-reservation-timer {
        display: none;
    }
    
    .tbvs-map-section {
        grid-template-columns: 1fr;
    }
    
    .tbvs-seatmap-container {
        max-width: none;
        padding: 0;
    }
}

/* Load More Dates Button (Mobile) */
.tbvs-load-more-dates-wrapper {
    grid-column: 1 / -1;
    text-align: center;
    margin-top: 10px;
}

.tbvs-load-more-dates-btn {
    display: inline-block;
    padding: 12px 24px;
    background: #84b19a;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tbvs-load-more-dates-btn:hover {
    background: #bfc98a;
}

/* ========================================
   Floating Cart Styles - Slide Panel
   ======================================== */

/* Trigger button container */
.tbvs-floating-cart-trigger {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9998;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.tbvs-floating-cart-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4caf50 0%, #45a049 100%);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px rgba(76, 175, 80, 0.4);
    transition: all 0.3s ease;
    position: relative;
}

.tbvs-floating-cart-toggle:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 25px rgba(76, 175, 80, 0.5);
}

.tbvs-cart-icon {
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tbvs-cart-icon svg {
    width: 26px;
    height: 26px;
}

.tbvs-cart-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #f44336;
    color: #fff;
    min-width: 22px;
    height: 22px;
    padding: 0 5px;
    border-radius: 11px;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(244, 67, 54, 0.4);
}

.tbvs-cart-badge.hidden {
    display: none;
}

/* Mobile cart open button - hidden on desktop */
.tbvs-mobile-cart-open-btn {
    display: none;
}

/* Mini total under button */
.tbvs-cart-mini-total {
    background: #fff;
    padding: 6px 12px;
    border-radius: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
    font-size: 13px;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.tbvs-mini-total-price {
    color: #2e7d32;
}

.tbvs-mini-total-currency {
    color: #666;
    font-size: 12px;
}

/* Overlay */
.tbvs-floating-cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.tbvs-floating-cart-overlay.open {
    opacity: 1;
    visibility: visible;
}

/* Slide Panel */
.tbvs-floating-cart-panel {
    position: fixed;
    top: 0;
    right: -420px;
    width: 400px;
    max-width: 100vw;
    height: 100vh;
    background: #fff;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.2);
    transition: right 0.3s ease;
}

.tbvs-floating-cart-panel.open {
    right: 0;
}

/* Header */
.tbvs-floating-cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #fff;
    border-bottom: 1px solid #e5e5e5;
    flex-shrink: 0;
}

.tbvs-floating-cart-header h4 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.tbvs-floating-cart-close {
    background: none;
    border: none;
    color: #666;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.tbvs-floating-cart-close:hover {
    background: #f5f5f5;
    color: #333;
}

.tbvs-floating-cart-close svg {
    width: 20px;
    height: 20px;
}

/* Body / Items wrapper */
.tbvs-floating-cart-body {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.tbvs-cart-items-wrapper {
    padding: 0;
}

.tbvs-empty-cart-message {
    text-align: center;
    padding: 60px 20px;
    color: #999;
    font-size: 15px;
}

/* Cart Item - WooCommerce style */
.tbvs-cart-item {
    display: flex;
    align-items: flex-start;
    padding: 16px 20px;
    border-bottom: 1px solid #f0f0f0;
    gap: 15px;
    position: relative;
}

.tbvs-cart-item:last-child {
    border-bottom: none;
}

.tbvs-cart-item.is-new {
    background: #f0fff0;
}

.tbvs-cart-item-image {
    width: 64px;
    height: 64px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tbvs-cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tbvs-cart-item-image .tbvs-item-icon {
    font-size: 28px;
}

.tbvs-cart-item-details {
    flex: 1;
    min-width: 0;
}

.tbvs-cart-item-name {
    font-weight: 600;
    font-size: 14px;
    color: #333;
    margin-bottom: 4px;
    line-height: 1.3;
}

.tbvs-cart-item-meta {
    font-size: 12px;
    color: #888;
    margin-bottom: 8px;
}

.tbvs-cart-item-meta span {
    display: inline-block;
    margin-right: 10px;
}

.tbvs-cart-item-price-qty {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.tbvs-cart-item-qty {
    display: flex;
    align-items: center;
    gap: 0;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.tbvs-qty-btn {
    width: 30px;
    height: 30px;
    border: none;
    background: #f8f8f8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 500;
    color: #333;
    transition: all 0.2s ease;
}

.tbvs-qty-btn:hover:not(:disabled) {
    background: #e8e8e8;
}

.tbvs-qty-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.tbvs-qty-value {
    width: 36px;
    text-align: center;
    font-weight: 600;
    font-size: 14px;
    background: #fff;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    height: 30px;
    line-height: 30px;
}

.tbvs-cart-item-total {
    font-weight: 700;
    font-size: 15px;
    color: #2e7d32;
    white-space: nowrap;
}

.tbvs-cart-item-remove {
    position: absolute;
    top: 12px;
    right: 12px;
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    padding: 4px;
    font-size: 18px;
    line-height: 1;
    transition: all 0.2s ease;
}

.tbvs-cart-item-remove:hover {
    color: #dc3232;
}

/* Item type badges */
.tbvs-item-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    margin-right: 6px;
}

.tbvs-item-badge.ticket {
    background: #e3f2fd;
    color: #1565c0;
}

.tbvs-item-badge.new-ticket {
    background: #e8f5e9;
    color: #2e7d32;
}

.tbvs-item-badge.product {
    background: #fff3e0;
    color: #e65100;
}

/* Footer */
.tbvs-floating-cart-footer {
    padding: 20px;
    background: #fafafa;
    border-top: 1px solid #e5e5e5;
    flex-shrink: 0;
}

.tbvs-cart-subtotal {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    font-size: 16px;
}

.tbvs-subtotal-label {
    color: #666;
}

.tbvs-subtotal-value {
    font-weight: 700;
    font-size: 20px;
    color: #2e7d32;
}

.tbvs-cart-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.tbvs-view-cart-btn {
    display: block;
    width: 100%;
    padding: 12px 20px;
    background: #fff;
    color: #333;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tbvs-view-cart-btn:hover {
    background: #f5f5f5;
    border-color: #ccc;
    color: #333;
}

.tbvs-floating-checkout-btn {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #4caf50 0%, #45a049 100%);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tbvs-floating-checkout-btn:hover {
    background: linear-gradient(135deg, #45a049 0%, #3d8b40 100%);
}

.tbvs-floating-checkout-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Mobile Responsive - moved to frontend-mobile-cart.css */

/* Animations */
.tbvs-cart-item.adding {
    animation: cartItemAdded 0.4s ease;
}

@keyframes cartItemAdded {
    0% {
        background-color: #c8e6c9;
    }
    100% {
        background-color: transparent;
    }
}

.tbvs-cart-item.removing {
    animation: cartItemRemoving 0.3s ease forwards;
}

@keyframes cartItemRemoving {
    to {
        opacity: 0;
        transform: translateX(20px);
        height: 0;
        padding: 0;
        margin: 0;
        overflow: hidden;
    }
}

.tbvs-cart-badge.updating {
    animation: badgePulse 0.3s ease;
}

@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

/* Mobile Buy Controls - Hidden on desktop */
.tbvs-mobile-buy-controls {
    display: none;
}

@media (max-width: 768px) {
    .tbvs-mobile-buy-controls {
        display: flex;
        align-items: center;
        justify-content: center;
        margin-top: 10px;
        gap: 8px;
    }
    
    .tbvs-mobile-buy-btn {
        background: #2B74FF;
        color: #fff;
        border: none;
        padding: 10px 24px;
        border-radius: 6px;
        font-size: 14px;
        font-weight: 600;
        cursor: pointer;
        transition: background 0.2s ease;
        width: 100%;
    }
    
    .tbvs-mobile-buy-btn:hover {
        background: #1a5fd1;
    }
    
    .tbvs-mobile-qty-controls {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        background: #f5f5f5;
        border-radius: 6px;
        padding: 6px 12px;
        width: 100%;
    }
    
    .tbvs-mobile-qty-controls .tbvs-qty-btn {
        width: 36px;
        height: 36px;
        border: none;
        background: #2B74FF;
        color: #fff;
        border-radius: 50%;
        font-size: 18px;
        font-weight: bold;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: background 0.2s ease;
    }
    
    .tbvs-mobile-qty-controls .tbvs-qty-btn:hover {
        background: #1a5fd1;
    }
    
    .tbvs-mobile-qty-controls .tbvs-qty-btn:disabled {
        background: #ccc;
        cursor: not-allowed;
    }
    
    .tbvs-mobile-qty-controls .tbvs-qty-value {
        font-size: 18px;
        font-weight: 600;
        min-width: 40px;
        text-align: center;
    }
    
    /* Hide quantity badge on mobile when using mobile controls */
    .tbvs-simple-place .tbvs-quantity-badge {
        display: none;
    }
}

