

.country
{
    stroke: #8b8b8b;
}
.container-globe
{
    padding-top: 10px;
}

/* Элегантный хедер */
.header-globe {
    background: white;
    padding: 30px 40px;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}

.header-globe::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #7879f1, #ff77c6, #78dbff);
    background-size: 200% 100%;
    animation: gradientFlow 5s ease infinite;
}

@keyframes gradientFlow {
    0% { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

.brand-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 30px;
}

.brand-name {
    font-family: 'Playfair Display', serif;
    font-size: 36px;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: -1px;
    position: relative;
}

.brand-name::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, #7879f1, #ff77c6);
    border-radius: 2px;
}

.divider-elegant {
    width: 2px;
    height: 40px;
    background: linear-gradient(to bottom, transparent, #cbd5e1, transparent);
}

h1 {
    font-size: 28px;
    font-weight: 600;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 12px;
}

.map-icon-elegant {
    font-size: 32px;
    background: linear-gradient(135deg, #7879f1, #ff77c6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.subtitle {
    color: #64748b;
    font-size: 16px;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.elegant-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #f0f9ff, #e0e7ff);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    color: #4f46e5;
    border: 1px solid #e0e7ff;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Блок годовой статистики */
.yearly-stats-section {
    margin-bottom: 30px;
}

.yearly-stats-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 30px;
    position: relative;
    overflow: hidden;
}

.yearly-stats-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #7879f1, #ff77c6);
    background-size: 200% 100%;
    animation: gradientFlow 5s ease infinite;
}

.yearly-stats-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.yearly-stats-title {
    font-size: 20px;
    font-weight: 600;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 10px;
}

.yearly-stats-title i {
    color: #7879f1;
}

.edit-mode-toggle {
    padding: 8px 16px;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #64748b;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.edit-mode-toggle:hover {
    background: white;
    border-color: #7879f1;
    color: #7879f1;
    transform: translateY(-1px);
}

.edit-mode-toggle.active {
    background: #7879f1;
    color: white;
    border-color: #7879f1;
}

.yearly-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.year-stat-card {
    background: #f8fafc;
    border-radius: 16px;
    padding: 25px;
    position: relative;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.year-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.year-stat-card.expected {
    background: linear-gradient(135deg, #f0fdf4, #dcfce7);
    border-color: #86efac;
    opacity: 0.8;
}

.year-stat-card.expected::before {
    content: 'EXPECTED';
    position: absolute;
    top: 8px;
    right: 12px;
    font-size: 10px;
    font-weight: 600;
    color: #16a34a;
    letter-spacing: 1px;
    opacity: 0.7;
}

.year-stat-card.edit-mode {
    cursor: pointer;
    border-style: dashed;
}

.year-stat-card.edit-mode:hover {
    background: white;
    border-color: #7879f1;
}

.year-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.year-label {
    font-size: 16px;
    font-weight: 600;
    color: #334155;
}

.year-badge {
    font-size: 12px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 12px;
    background: linear-gradient(135deg, #e0e7ff, #c7d2fe);
    color: #4f46e5;
}

.year-stat-card.expected .year-badge {
    background: linear-gradient(135deg, #dcfce7, #bbf7d0);
    color: #16a34a;
}

.year-content {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 15px;
}

.year-material {
    flex: 1;
    text-align: center;
}

.year-material-name {
    font-size: 12px;
    font-weight: 500;
    color: #64748b;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.year-value {
    font-size: 28px;
    font-weight: 700;
    transition: all 0.3s ease;
}

.year-material.armour .year-value {
    color: #d97706;
}

.year-material.expansion .year-value {
    color: #0d9488;
}

.year-material.expected .year-value {
    color: #16a34a;
    opacity: 0.8;
}

.year-change {
    font-size: 12px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.year-change.positive {
    color: #10b981;
}

.year-change.negative {
    color: #ef4444;
}

.year-edit-input {
    width: 100%;
    padding: 6px;
    border: 2px solid #7879f1;
    border-radius: 6px;
    font-size: 24px;
    font-weight: 700;
    text-align: center;
    background: white;
    color: #1e293b;
    outline: none;
}

.year-edit-input:focus {
    box-shadow: 0 0 0 3px rgba(120, 121, 241, 0.1);
}

/* Верхние блоки */
.top-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

/* Блок счетчиков */
.stats-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 30px;
    position: relative;
    overflow: hidden;
}

.stats-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #7879f1, #ff77c6);
    background-size: 200% 100%;
    animation: gradientFlow 5s ease infinite;
}

.stats-title {
    font-size: 20px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.stats-title i {
    color: #7879f1;
}

.total-stat {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e2e8f0;
}

.total-stat .stat-value {
    font-size: 48px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #7879f1, #ff77c6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.total-stat .stat-label {
    color: #64748b;
    font-size: 16px;
    font-weight: 500;
}

.material-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    position: relative;
}

.material-stats::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 50%;
    z-index: 1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.material-stat {
    text-align: center;
    position: relative;
}

.material-stat .stat-value {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.material-stat.expansion .stat-value {
    color: #78dbe2;
}

.material-stat.armour .stat-value {
    color: #ffb841;
}

.material-stat .stat-label {
    font-size: 14px;
    font-weight: 500;
    color: #64748b;
}

/* Анимированные стрелки */
.arrow-container {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    z-index: 2;
}

.arrow {
    position: absolute;
    width: 20px;
    height: 20px;
    opacity: 0;
    animation: arrowMove 2s ease-in-out infinite;
}

.arrow.top-left {
    top: 0;
    left: 0;
    animation-delay: 0s;
}

.arrow.top-right {
    top: 0;
    right: 0;
    animation-delay: 0.5s;
}

.arrow.bottom-left {
    bottom: 0;
    left: 0;
    animation-delay: 1s;
}

.arrow.bottom-right {
    bottom: 0;
    right: 0;
    animation-delay: 1.5s;
}

@keyframes arrowMove {
    0% {
        opacity: 0;
        transform: scale(0.5);
    }
    50% {
        opacity: 1;
        transform: scale(1);
    }
    100% {
        opacity: 0;
        transform: scale(0.5);
    }
}

/* Блок дополнительной информации */
.info-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 30px;
    position: relative;
    overflow: hidden;
}

.info-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #7879f1, #ff77c6);
    background-size: 200% 100%;
    animation: gradientFlow 5s ease infinite;
}

.info-title {
    font-size: 20px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.info-title i {
    color: #7879f1;
}

.info-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.info-item {
    padding: 15px;
    background: #f8fafc;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.info-item:hover {
    background: #f1f5f9;
    transform: translateY(-2px);
}

.info-item-title {
    font-size: 14px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 5px;
}

.info-item-value {
    font-size: 24px;
    font-weight: 700;
    color: #7879f1;
}

/* Новый layout для глобуса и стран */
.globe-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

/* Глобус – контейнер */
.globe-container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    height: 500px;
    position: relative;
}

/* Внутренний контейнер для SVG-глобуса */
#globe-container {
    position: relative;
    width: 100%;
    height: 100%;
}

#globe {
    width: 100%;
    height: 100%;
    display: block;
    cursor: grab;
}

/* Легенда на глобусе - уменьшенная */
.globe-legend {
    position: absolute;
    bottom: 15px;
    left: 15px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(120, 121, 241, 0.2);
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    z-index: 50;
    min-width: 160px;
}

.globe-legend-title {
    font-size: 12px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.globe-legend-title i {
    color: #7879f1;
    font-size: 10px;
}

.globe-legend-items {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.globe-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 6px;
    background: rgba(248, 250, 252, 0.8);
    border-radius: 6px;
    transition: all 0.3s ease;
}

.globe-legend-item:hover {
    background: rgba(241, 245, 249, 0.9);
    transform: translateX(2px);
}

.globe-legend-color {
    width: 16px;
    height: 16px;
    border-radius: 3px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}

.globe-legend-text {
    font-size: 11px;
    font-weight: 500;
    color: #475569;
    line-height: 1.2;
}

/* Кнопки зума для D3-глобуса */
.zoom-controls {
    position: absolute;
    top: 15px;
    right: 15px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    z-index: 100;
}

.zoom-btn {
    width: 32px;
    height: 32px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    color: #64748b;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zoom-btn:hover {
    background: #f8fafc;
    border-color: #7879f1;
    color: #7879f1;
}

.info {
    position: absolute;
    bottom: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 12px;
    color: #64748b;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
    z-index: 60;
}

/* Активные страны */
.countries-panel {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.panel-header {
    padding: 20px 30px;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border-bottom: 1px solid #e2e8f0;
}

.panel-title {
    font-size: 18px;
    font-weight: 600;
    color: #334155;
    display: flex;
    align-items: center;
    gap: 10px;
}

.panel-body {
    padding: 20px 30px;
    flex: 1;
    overflow-y: auto;
    max-height: 420px;
}

.countries-list-inline {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.country-item-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: #f8fafc;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    font-size: 14px;
    color: #334155;
    position: relative;
}

.country-item-inline:hover {
    background: white;
    border-color: #7879f1;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(120, 121, 241, 0.2);
}

.country-item-inline:hover::after {
    content: '📍';
    position: absolute;
    top: -8px;
    right: -8px;
    font-size: 12px;
    animation: bounce 0.5s ease;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

.country-flag {
    width: 24px;
    height: 18px;
    border-radius: 2px;
    object-fit: cover;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.country-name {
    font-weight: 500;
}

.dot-separator {
    width: 4px;
    height: 4px;
    background: #cbd5e1;
    border-radius: 50%;
}

/* Формы и панели */
.forms-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.panel {
    background: white;
    border-radius: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.form-group {
    margin-bottom: 16px;
}

label {
    display: block;
    margin-bottom: 6px;
    color: #475569;
    font-size: 14px;
    font-weight: 500;
}

input, select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: white;
}

input:focus, select:focus {
    outline: none;
    border-color: #7879f1;
    box-shadow: 0 0 0 3px rgba(120, 121, 241, 0.1);
}

.btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #7879f1, #ff77c6);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(120, 121, 241, 0.3);
}

.btn-secondary {
    background: linear-gradient(135deg, #10b981, #06b6d4);
}

.btn-secondary:hover {
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

/* Уведомления */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 16px 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 2000;
    border-left: 4px solid #10b981;
}

.notification.show {
    transform: translateX(0);
}

.notification.error {
    border-left-color: #ef4444;
}

.notification-icon {
    font-size: 20px;
}

.notification.success .notification-icon {
    color: #10b981;
}

.notification.error .notification-icon {
    color: #ef4444;
}

.notification-message {
    color: #334155;
    font-size: 14px;
    font-weight: 500;
}

/* Loading */
.loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.loading-overlay.show {
    opacity: 1;
    pointer-events: all;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #e2e8f0;
    border-top: 3px solid #7879f1;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    margin-top: 12px;
    color: #64748b;
    font-size: 14px;
}

/* Адаптивность */
@media (max-width: 1024px) {
    .top-section {
        grid-template-columns: 1fr;
    }

    .forms-grid {
        grid-template-columns: 1fr;
    }

    .globe-section {
        grid-template-columns: 1fr;
    }

    .yearly-stats-grid {
        grid-template-columns: 1fr;
    }

    .globe-legend {
        bottom: 10px;
        left: 10px;
        min-width: 160px;
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }

    .brand-section {
        flex-direction: column;
        gap: 20px;
    }

    .brand {
        flex-direction: column;
        text-align: center;
    }

    .info-content {
        grid-template-columns: 1fr;
    }

    .globe-legend {
        position: static;
        margin: 15px;
        width: calc(100% - 30px);
    }
}