/**
 * Coast Water Sports - Geo Detection Styles
 * Styles for the country/currency suggestion popup
 */

.geo-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.geo-popup.show {
    opacity: 1;
    visibility: visible;
}

.geo-popup-content {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9) translateY(20px);
    transition: all 0.3s ease;
}

.geo-popup.show .geo-popup-content {
    transform: scale(1) translateY(0);
}

.geo-popup-header {
    display: flex;
    align-items: center;
    padding: 20px 25px 15px;
    border-bottom: 1px solid #e5e5e5;
    position: relative;
}

.geo-popup-flag {
    font-size: 24px;
    margin-right: 12px;
}

.geo-popup-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
    flex: 1;
}

.geo-popup-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.geo-popup-close:hover {
    background: #f5f5f5;
    color: #666;
}

.geo-popup-body {
    padding: 20px 25px;
}

.geo-popup-body p {
    margin: 0 0 20px;
    color: #666;
    line-height: 1.5;
}

.geo-popup-actions {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
}

.geo-btn {
    padding: 12px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    flex: 1;
    text-align: center;
}

.geo-btn-primary {
    background: #007cba;
    color: white;
}

.geo-btn-primary:hover {
    background: #005a87;
    transform: translateY(-1px);
}

.geo-btn-secondary {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #dee2e6;
}

.geo-btn-secondary:hover {
    background: #e9ecef;
    color: #333;
}

.geo-popup-footer {
    text-align: center;
}

.geo-popup-footer small {
    color: #999;
    font-size: 12px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .geo-popup-content {
        width: 95%;
        margin: 20px;
    }
    
    .geo-popup-header {
        padding: 15px 20px 10px;
    }
    
    .geo-popup-header h3 {
        font-size: 16px;
    }
    
    .geo-popup-body {
        padding: 15px 20px;
    }
    
    .geo-popup-actions {
        flex-direction: column;
    }
    
    .geo-btn {
        width: 100%;
    }
}

/* Animation for popup entrance */
@keyframes geoPopupSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.geo-popup.show .geo-popup-content {
    animation: geoPopupSlideIn 0.3s ease;
}

/* Pricing notice styles */
.geo-pricing-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 6px;
    padding: 12px 15px;
    margin: 15px 0;
    font-size: 14px;
    color: #856404;
}

.geo-pricing-notice strong {
    color: #533f03;
}

.geo-pricing-notice a {
    color: #007cba;
    text-decoration: none;
    font-weight: 500;
}

.geo-pricing-notice a:hover {
    text-decoration: underline;
}

/* Country flag icons */
.geo-flag-icon {
    display: inline-block;
    width: 20px;
    height: 15px;
    background-size: cover;
    background-position: center;
    border-radius: 2px;
    margin-right: 8px;
    vertical-align: middle;
}

.geo-flag-icon.flag-us {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="30" fill="%23B22234"/><rect width="60" height="2.3" fill="%23FFFFFF"/><rect y="4.6" width="60" height="2.3" fill="%23FFFFFF"/><rect y="9.2" width="60" height="2.3" fill="%23FFFFFF"/><rect y="13.8" width="60" height="2.3" fill="%23FFFFFF"/><rect y="18.4" width="60" height="2.3" fill="%23FFFFFF"/><rect y="23" width="60" height="2.3" fill="%23FFFFFF"/><rect width="24" height="16.1" fill="%23003F87"/></svg>');
}

.geo-flag-icon.flag-gb {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="30" fill="%23012169"/><g fill="%23FFFFFF"><path d="M0 0v30h60V0zM0 0l60 30M60 0L0 30"/></g><g fill="%23CE1126"><path d="M0 0v30h60V0zM0 0l60 30M60 0L0 30"/></g></svg>');
}

.geo-flag-icon.flag-de {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="10" fill="%23000000"/><rect y="10" width="60" height="10" fill="%23DD0000"/><rect y="20" width="60" height="10" fill="%23FFCE00"/></svg>');
}

.geo-flag-icon.flag-fr {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="20" height="30" fill="%2300257D"/><rect x="20" width="20" height="30" fill="%23FFFFFF"/><rect x="40" width="20" height="30" fill="%23ED2939"/></svg>');
}

.geo-flag-icon.flag-es {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="6" fill="%23C60B1E"/><rect y="6" width="60" height="6" fill="%23FFC400"/><rect y="12" width="60" height="6" fill="%23C60B1E"/><rect y="18" width="60" height="6" fill="%23FFC400"/><rect y="24" width="60" height="6" fill="%23C60B1E"/></svg>');
}

.geo-flag-icon.flag-it {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="20" height="30" fill="%23009250"/><rect x="20" width="20" height="30" fill="%23FFFFFF"/><rect x="40" width="20" height="30" fill="%23CE2B37"/></svg>');
}

.geo-flag-icon.flag-ru {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="10" fill="%23FFFFFF"/><rect y="10" width="60" height="10" fill="%23003DA5"/><rect y="20" width="60" height="10" fill="%23D52B1E"/></svg>');
}

.geo-flag-icon.flag-au {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="30" fill="%2300008B"/><g fill="%23FFFFFF"><path d="M0 0v30h60V0zM0 0l60 30M60 0L0 30"/></g></svg>');
}

/* Tax notice styles */
.tax-notice {
    background: #e8f5e8;
    border: 1px solid #4caf50;
    border-radius: 6px;
    padding: 12px 15px;
    margin: 15px 0;
    font-size: 14px;
    color: #2e7d32;
}

.tax-notice.tax-inclusive {
    background: #e3f2fd;
    border-color: #2196f3;
    color: #1565c0;
}

.tax-notice.tax-exclusive {
    background: #fff3e0;
    border-color: #ff9800;
    color: #e65100;
}

.tax-notice strong {
    color: inherit;
}

/* Enhanced geo pricing notice */
.geo-pricing-notice.enhanced {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
}

.geo-pricing-notice.enhanced .current-pricing {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e9ecef;
}

.geo-pricing-notice.enhanced .suggested-pricing {
    font-size: 14px;
}

.geo-pricing-notice.enhanced .suggested-pricing a {
    color: #007cba;
    text-decoration: none;
    font-weight: 500;
}

.geo-pricing-notice.enhanced .suggested-pricing a:hover {
    text-decoration: underline;
}

/* EU fallback notice */
.eu-fallback-notice {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 6px;
    padding: 15px;
    margin: 15px 0;
    font-size: 14px;
    color: #856404;
}

.eu-fallback-notice strong {
    color: #533f03;
}

.eu-fallback-notice a {
    color: #007cba;
    text-decoration: none;
    font-weight: 500;
}

.eu-fallback-notice a:hover {
    text-decoration: underline;
}

/* Small flag icons */
.geo-flag-icon-small {
    display: inline-block;
    width: 16px;
    height: 12px;
    background-size: cover;
    background-position: center;
    border-radius: 2px;
    margin-right: 6px;
    vertical-align: middle;
}

.geo-flag-icon-small.flag-us {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="30" fill="%23B22234"/><rect width="60" height="2.3" fill="%23FFFFFF"/><rect y="4.6" width="60" height="2.3" fill="%23FFFFFF"/><rect y="9.2" width="60" height="2.3" fill="%23FFFFFF"/><rect y="13.8" width="60" height="2.3" fill="%23FFFFFF"/><rect y="18.4" width="60" height="2.3" fill="%23FFFFFF"/><rect y="23" width="60" height="2.3" fill="%23FFFFFF"/><rect width="24" height="16.1" fill="%23003F87"/></svg>');
}

.geo-flag-icon-small.flag-gb {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="30" fill="%23012169"/><g fill="%23FFFFFF"><path d="M0 0v30h60V0zM0 0l60 30M60 0L0 30"/></g><g fill="%23CE1126"><path d="M0 0v30h60V0zM0 0l60 30M60 0L0 30"/></g></svg>');
}

.geo-flag-icon-small.flag-de {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="10" fill="%23000000"/><rect y="10" width="60" height="10" fill="%23DD0000"/><rect y="20" width="60" height="10" fill="%23FFCE00"/></svg>');
}

.geo-flag-icon-small.flag-fr {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="20" height="30" fill="%2300257D"/><rect x="20" width="20" height="30" fill="%23FFFFFF"/><rect x="40" width="20" height="30" fill="%23ED2939"/></svg>');
}

.geo-flag-icon-small.flag-es {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="6" fill="%23C60B1E"/><rect y="6" width="60" height="6" fill="%23FFC400"/><rect y="12" width="60" height="6" fill="%23C60B1E"/><rect y="18" width="60" height="6" fill="%23FFC400"/><rect y="24" width="60" height="6" fill="%23C60B1E"/></svg>');
}

.geo-flag-icon-small.flag-it {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="20" height="30" fill="%23009250"/><rect x="20" width="20" height="30" fill="%23FFFFFF"/><rect x="40" width="20" height="30" fill="%23CE2B37"/></svg>');
}

.geo-flag-icon-small.flag-ru {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="10" fill="%23FFFFFF"/><rect y="10" width="60" height="10" fill="%23003DA5"/><rect y="20" width="60" height="10" fill="%23D52B1E"/></svg>');
}

.geo-flag-icon-small.flag-au {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 60 30"><rect width="60" height="30" fill="%2300008B"/><g fill="%23FFFFFF"><path d="M0 0v30h60V0zM0 0l60 30M60 0L0 30"/></g></svg>');
}

/* Smart Country Selector Styles */
.smart-country-selector {
    position: relative;
    font-family: Arial, sans-serif;
}

/* Country Suggestion (when user is on wrong domain) */
.country-suggestion {
    background: linear-gradient(135deg, #007cba 0%, #005a87 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 10px 0;
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.3);
}

.suggestion-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.detection-message {
    font-size: 16px;
    font-weight: 500;
}

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

.btn-switch-country {
    background: #ffffff;
    color: #007cba;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.btn-switch-country:hover {
    background: #f8f9fa;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.btn-change-country {
    color: #ffffff;
    text-decoration: none;
    font-size: 14px;
    padding: 8px 16px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    transition: all 0.3s ease;
}

.btn-change-country:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Current Country Display (when user is on correct domain) */
.current-country-display {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    padding: 12px 16px;
    border-radius: 6px;
    margin: 10px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.current-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.current-site {
    font-weight: 600;
    color: #495057;
    font-size: 14px;
}

.current-details {
    font-size: 12px;
    color: #6c757d;
}

/* Country Dropdown Overlay */
.country-dropdown-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9998;
    backdrop-filter: blur(2px);
}

/* Country Dropdown */
.country-dropdown {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    animation: dropdownSlideIn 0.3s ease-out;
}

@keyframes dropdownSlideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.dropdown-header {
    background: #007cba;
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dropdown-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.close-dropdown {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.3s ease;
}

.close-dropdown:hover {
    background: rgba(255, 255, 255, 0.2);
}

.dropdown-content {
    padding: 20px;
    max-height: 60vh;
    overflow-y: auto;
}

.region-group {
    margin-bottom: 25px;
}

.region-group:last-child {
    margin-bottom: 0;
}

.region-group h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    font-weight: 600;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.country-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.country-option {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.country-option:hover {
    border-color: #007cba;
    background: #f8f9ff;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 124, 186, 0.1);
}

.country-option.selected {
    border-color: #007cba;
    background: #e3f2fd;
}

.country-flag {
    font-size: 24px;
    margin-right: 12px;
    width: 32px;
    text-align: center;
}

.country-details {
    flex: 1;
}

.country-name {
    font-weight: 600;
    color: #495057;
    font-size: 14px;
    margin-bottom: 2px;
}

.country-info {
    font-size: 12px;
    color: #6c757d;
}

.selected-indicator {
    color: #007cba;
    font-weight: bold;
    font-size: 16px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .suggestion-content {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .suggestion-actions {
        width: 100%;
        justify-content: flex-start;
    }
    
    .current-country-display {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .country-dropdown {
        width: 95%;
        max-height: 85vh;
    }
    
    .dropdown-content {
        padding: 15px;
    }
    
    .country-option {
        padding: 10px 12px;
    }
    
    .country-flag {
        font-size: 20px;
        margin-right: 10px;
        width: 28px;
    }
}
