/* Feature Widgets - Interactive components replacing static images */

/* ===== Slide System ===== */
.feature-carousel .feature-slide {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    transition: opacity 0.8s ease;
    width: 100%;
    max-width: 480px;
    pointer-events: none;
}

.feature-carousel .feature-slide.active {
    position: relative;
    left: auto;
    transform: none;
    opacity: 1;
    pointer-events: auto;
}

/* ===== Carousel Dots ===== */
.w-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.w-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.2);
    cursor: pointer;
    padding: 0;
    transition: all 0.3s ease;
}

.w-dot:hover {
    background: rgba(255, 255, 255, 0.4);
}

.w-dot.active {
    background: var(--accent-primary, #4de0ff);
    box-shadow: 0 0 8px rgba(77, 224, 255, 0.4);
}

/* ===== Base Card ===== */
.w-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 20px;
    color: #f5f7fb;
    font-family: 'Inter', -apple-system, sans-serif;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.w-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}

.w-card-sm {
    padding: 16px;
    border-radius: 12px;
}

/* ===== Common Elements ===== */
.w-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.w-badge-blue {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
}

.w-badge-teal {
    background: rgba(45, 212, 191, 0.15);
    color: #2dd4bf;
}

.w-badge-green {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
}

.w-badge-red {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.w-badge-eco {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border-radius: 20px;
    padding: 4px 12px;
    font-size: 0.7rem;
}

.w-label {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(255, 255, 255, 0.5);
}

.w-value-lg {
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
}

.w-value-md {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
}

.w-value-sm {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

.w-text-cyan {
    color: #4de0ff;
}

.w-text-green {
    color: #34d399;
}

.w-text-red {
    color: #f87171;
}

.w-text-muted {
    color: rgba(255, 255, 255, 0.5);
}

.w-icon {
    font-style: normal;
    font-size: 0.85rem;
}

/* ===== SVG Chart Base ===== */
.w-chart-svg {
    width: 100%;
    height: auto;
    display: block;
}

.w-chart-path {
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.w-chart-area {
    opacity: 0.15;
}

.w-chart-path-animated {
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;
    transition: stroke-dashoffset 2s ease;
}

.w-widget-visible .w-chart-path-animated {
    stroke-dashoffset: 0;
}

.w-chart-grid-line {
    stroke: rgba(255, 255, 255, 0.06);
    stroke-width: 1;
}

.w-chart-label {
    fill: rgba(255, 255, 255, 0.35);
    font-size: 10px;
    font-family: 'Inter', sans-serif;
}

.w-chart-dot {
    transition: r 0.3s ease, opacity 0.3s ease;
}

.w-chart-dot:hover {
    r: 5;
    opacity: 1;
}

/* ===== Widget: Telemetry Dashboard ===== */
.w-telemetry {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 480px;
}

.w-telemetry-main {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.w-telemetry-main:hover {
    border-color: rgba(77, 224, 255, 0.15);
}

.w-telemetry-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.w-telemetry-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.w-telemetry-stats {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.w-battery-pct {
    font-size: 4rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.03em;
}

.w-battery-pct span {
    font-size: 1.5rem;
    font-weight: 600;
}

.w-battery-range {
    text-align: right;
}

.w-battery-range .w-label {
    display: block;
    margin-bottom: 4px;
}

.w-battery-range-value {
    font-size: 2.2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.w-battery-range-value span {
    font-size: 1rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
}

.w-battery-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    overflow: hidden;
    border-radius: 0 0 15px 15px;
}

.w-battery-wave svg {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%;
    height: 100%;
    animation: w-wave 4s ease-in-out infinite;
}

@keyframes w-wave {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(-25%);
    }
}

.w-telemetry-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.w-telemetry-card-sm {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 16px;
    cursor: pointer;
    transition: border-color 0.3s ease, transform 0.3s ease;
}

.w-telemetry-card-sm:hover {
    border-color: rgba(77, 224, 255, 0.15);
    transform: translateY(-2px);
}

.w-telemetry-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.w-temp-value {
    font-size: 1.8rem;
    font-weight: 700;
}

.w-temp-value span {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
}

.w-mini-chart {
    margin-top: 8px;
    height: 30px;
}

/* ===== Widget: Location / Controls ===== */
.w-location {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 480px;
}

.w-control-tabs {
    display: flex;
    justify-content: center;
    gap: 20px;
    padding: 12px 0;
}

.w-control-tab {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    position: relative;
}

.w-control-tab svg {
    width: 20px;
    height: 20px;
    fill: rgba(255, 255, 255, 0.5);
    transition: fill 0.3s ease;
}

.w-control-tab:hover svg {
    fill: rgba(255, 255, 255, 0.8);
}

.w-control-tab.active svg {
    fill: #f87171;
}

.w-control-tab .w-indicator {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #f87171;
}

.w-control-tab.w-tab-active .w-indicator {
    background: #34d399;
    box-shadow: 0 0 6px rgba(52, 211, 153, 0.5);
}

.w-location-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px;
    cursor: pointer;
    transition: border-color 0.3s ease, transform 0.2s ease;
    position: relative;
    overflow: hidden;
}

.w-location-card:hover {
    border-color: rgba(77, 224, 255, 0.15);
    transform: translateY(-1px);
}

.w-location-card-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 8px;
}

.w-location-card h4 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0 0 6px;
}

.w-location-link {
    color: #4de0ff;
    font-size: 0.8rem;
    text-decoration: none;
    cursor: pointer;
}

.w-location-link:hover {
    text-decoration: underline;
}

.w-location-meta {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
}

.w-location-map-preview {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 80px;
    height: 60px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

/* ===== Widget: Charging Sessions ===== */
.w-charging-sessions {
    max-width: 480px;
}

.w-sessions-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    margin-bottom: 12px;
}

.w-sessions-header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.w-sessions-date-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
}

.w-sessions-date {
    font-size: 1.15rem;
    font-weight: 600;
}

.w-sessions-totals {
    display: flex;
    gap: 16px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
}

.w-sessions-totals .w-energy {
    color: #facc15;
}

.w-sessions-totals .w-cost {
    color: rgba(255, 255, 255, 0.5);
}

.w-session-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px;
    margin-bottom: 12px;
    display: grid;
    grid-template-columns: 48px 1fr auto;
    gap: 14px;
    align-items: center;
    cursor: pointer;
    transition: border-color 0.3s ease, transform 0.2s ease;
}

.w-session-card:hover {
    border-color: rgba(77, 224, 255, 0.15);
    transform: translateY(-1px);
}

.w-session-battery {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-size: 0.75rem;
    font-weight: 600;
}

.w-session-battery-bar {
    width: 3px;
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    position: relative;
}

.w-session-battery-bar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: 2px;
    background: currentColor;
}

.w-session-battery .w-from {
    color: rgba(255, 255, 255, 0.5);
}

.w-session-battery .w-to {
    color: #34d399;
}

.w-session-info h4 {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 6px;
}

.w-session-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

.w-charge-type {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
}

.w-charge-type-ac {
    background: rgba(52, 211, 153, 0.2);
    color: #34d399;
}

.w-charge-type-sc {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.w-session-energy {
    text-align: right;
}

.w-session-energy .w-kwh {
    font-size: 1.05rem;
    font-weight: 700;
    color: #facc15;
}

.w-session-energy .w-eur {
    font-size: 0.8rem;
    color: #34d399;
    display: block;
    margin-top: 2px;
}

/* ===== Widget: Charging Curve ===== */
.w-charging-curve {
    max-width: 480px;
}

.w-chart-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 20px;
}

.w-chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.w-chart-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: 600;
}

/* ===== Widget: Fuel Savings ===== */
.w-fuel-savings {
    max-width: 480px;
}

.w-savings-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
}

.w-savings-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 20px;
}

.w-savings-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: 600;
}

.w-savings-subtitle {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 2px;
}

.w-savings-amount {
    font-size: 3rem;
    font-weight: 700;
    color: #34d399;
    line-height: 1;
    margin-bottom: 4px;
}

.w-savings-amount span {
    font-size: 1.5rem;
}

.w-savings-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 20px;
}

.w-savings-bar-row {
    display: grid;
    grid-template-columns: 80px 1fr 50px;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 0.85rem;
}

.w-savings-bar-label {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.7);
}

.w-savings-bar {
    height: 24px;
    border-radius: 6px;
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.05);
}

.w-savings-bar-fill {
    height: 100%;
    border-radius: 6px;
    transition: width 1.5s ease;
    width: 0;
}

.w-widget-visible .w-savings-bar-fill {
    width: var(--fill-width);
}

.w-savings-bar-fill-green {
    background: linear-gradient(90deg, #059669, #34d399);
}

.w-savings-bar-fill-red {
    background: linear-gradient(90deg, #dc2626, #f87171);
}

.w-savings-bar-value {
    text-align: right;
    font-weight: 600;
}

.w-savings-footer {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
}

/* ===== Widget: Route Map ===== */
.w-route-map {
    max-width: 480px;
}

.w-map-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.w-map-card:hover {
    border-color: rgba(77, 224, 255, 0.15);
}

.w-map-area {
    height: 220px;
    position: relative;
    overflow: hidden;
    background: #0a0e17;
}

.w-map-area svg {
    width: 100%;
    height: 100%;
}

.w-map-expand {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 6px 12px;
    color: #f5f7fb;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: background 0.3s ease;
}

.w-map-expand:hover {
    background: rgba(255, 255, 255, 0.18);
}

.w-map-route-path {
    fill: none;
    stroke: #4de0ff;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 800;
    stroke-dashoffset: 800;
    transition: stroke-dashoffset 3s ease;
    filter: drop-shadow(0 0 4px rgba(77, 224, 255, 0.5));
}

.w-widget-visible .w-map-route-path {
    stroke-dashoffset: 0;
}

.w-map-region {
    fill: none;
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 0.5;
}

.w-map-stats {
    display: flex;
    justify-content: space-around;
    padding: 14px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.w-map-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 500;
}

.w-map-stat i {
    font-style: normal;
    opacity: 0.5;
}

/* ===== Widget: Driving Score ===== */
.w-driving-score {
    max-width: 480px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.w-drive-stats-bar {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    padding: 14px 8px;
}

.w-drive-stat {
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.w-drive-stat:last-child {
    border-right: none;
}

.w-drive-stat i {
    font-style: normal;
    font-size: 0.8rem;
    display: block;
    margin-bottom: 4px;
}

.w-drive-stat-value {
    font-size: 1rem;
    font-weight: 700;
}

.w-drive-stat-unit {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.4);
}

.w-score-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
}

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

.w-score-title {
    font-size: 1.1rem;
    font-weight: 700;
}

.w-score-body {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 20px;
    align-items: center;
}

.w-score-ring {
    position: relative;
    width: 120px;
    height: 120px;
}

.w-score-ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.w-score-ring-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.08);
    stroke-width: 8;
}

.w-score-ring-fill {
    fill: none;
    stroke: #2dd4bf;
    stroke-width: 8;
    stroke-linecap: round;
    stroke-dasharray: 283;
    stroke-dashoffset: 283;
    transition: stroke-dashoffset 2s ease;
}

.w-widget-visible .w-score-ring-fill {
    stroke-dashoffset: var(--score-offset);
}

.w-score-number {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2.2rem;
    font-weight: 700;
}

.w-score-bars {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.w-score-bar-row {
    display: grid;
    grid-template-columns: 90px 1fr 30px;
    align-items: center;
    gap: 10px;
    font-size: 0.8rem;
}

.w-score-bar-label {
    color: rgba(255, 255, 255, 0.7);
}

.w-score-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 4px;
    overflow: hidden;
}

.w-score-bar-fill {
    height: 100%;
    border-radius: 4px;
    background: #2dd4bf;
    transition: width 1.5s ease;
    width: 0;
}

.w-widget-visible .w-score-bar-fill {
    width: var(--bar-width);
}

.w-score-bar-value {
    font-weight: 600;
    text-align: right;
}

/* ===== Widget: Battery Chart / Speed Chart / Efficiency ===== */
.w-drive-chart {
    max-width: 480px;
}

.w-drive-chart-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 20px;
}

.w-drive-chart-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 4px;
}

.w-drive-chart-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    font-weight: 600;
}

.w-drive-chart-subtitle {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
}

.w-drive-chart-stat {
    text-align: right;
}

.w-drive-chart-stat-value {
    font-size: 1.4rem;
    font-weight: 700;
}

.w-drive-chart-stat-label {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.4);
}

.w-chart-legend {
    display: flex;
    gap: 16px;
    margin-top: 12px;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.w-chart-legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.w-chart-legend-line {
    width: 16px;
    height: 2px;
    border-radius: 1px;
}

.w-chart-legend-dash {
    width: 16px;
    height: 0;
    border-top: 2px dashed;
}

/* ===== Widget: Range Over Time ===== */
.w-range-time {
    max-width: 480px;
}

/* ===== Widget: Health Gauge ===== */
.w-health-gauge {
    max-width: 480px;
}

.w-gauge-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
    text-align: center;
}

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

.w-gauge-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.w-gauge-svg {
    width: 200px;
    height: 160px;
    margin: 0 auto;
}

.w-gauge-bg {
    fill: none;
    stroke: rgba(255, 255, 255, 0.06);
    stroke-width: 14;
    stroke-linecap: round;
}

.w-gauge-fill {
    fill: none;
    stroke: #2dd4bf;
    stroke-width: 14;
    stroke-linecap: round;
    stroke-dasharray: 220;
    stroke-dashoffset: 220;
    transition: stroke-dashoffset 2.5s ease;
    filter: drop-shadow(0 0 6px rgba(45, 212, 191, 0.4));
}

.w-widget-visible .w-gauge-fill {
    stroke-dashoffset: var(--gauge-offset);
}

.w-gauge-value {
    font-size: 3.2rem;
    font-weight: 700;
    line-height: 1;
    margin-top: -20px;
}

.w-gauge-unit {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
}

/* ===== Widget: Estimated Range ===== */
.w-estimated-range {
    max-width: 480px;
}

.w-range-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 24px;
}

.w-range-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 24px;
    color: rgba(255, 255, 255, 0.6);
}

.w-range-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.w-range-row:last-child {
    border-bottom: none;
}

.w-range-row-label {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.7);
}

.w-range-row-value {
    font-size: 1.8rem;
    font-weight: 700;
}

.w-range-row-value span {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.5);
}

/* ===== Widget: Controls ===== */
.w-controls {
    max-width: 480px;
}

.w-controls-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 12px;
}

.w-control-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #f5f7fb;
}

.w-control-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
}

.w-control-btn.w-active {
    background: rgba(77, 224, 255, 0.08);
    border-color: rgba(77, 224, 255, 0.2);
}

.w-control-btn.w-active svg {
    fill: #4de0ff;
}

.w-control-btn svg {
    width: 24px;
    height: 24px;
    fill: rgba(255, 255, 255, 0.6);
    transition: fill 0.3s ease;
}

.w-control-btn-label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: rgba(255, 255, 255, 0.5);
}

.w-control-btn.w-active .w-control-btn-label {
    color: #4de0ff;
}

/* ===== Widget: Trigger Selector ===== */
.w-triggers {
    max-width: 480px;
}

.w-trigger-progress {
    height: 4px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 2px;
    margin-bottom: 24px;
    overflow: hidden;
}

.w-trigger-progress-fill {
    height: 100%;
    width: 33%;
    background: #f59e0b;
    border-radius: 2px;
    transition: width 0.5s ease;
}

.w-trigger-heading {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.w-trigger-sub {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 20px;
}

.w-trigger-option {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px 18px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.w-trigger-option:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(255, 255, 255, 0.12);
}

.w-trigger-option.w-selected {
    background: rgba(245, 158, 11, 0.06);
    border-color: rgba(245, 158, 11, 0.2);
}

.w-trigger-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    flex-shrink: 0;
}

.w-trigger-text {
    flex: 1;
}

.w-trigger-text h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0 0 2px;
}

.w-trigger-text p {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.4);
    margin: 0;
}

.w-trigger-check {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.w-selected .w-trigger-check {
    background: #f59e0b;
    border-color: #f59e0b;
}

.w-selected .w-trigger-check::after {
    content: '';
    width: 8px;
    height: 5px;
    border-left: 2px solid #000;
    border-bottom: 2px solid #000;
    transform: rotate(-45deg) translateY(-1px);
}

/* ===== Widget: Customize Automation ===== */
.w-customize {
    max-width: 480px;
}

.w-customize-section {
    margin-bottom: 20px;
}

.w-customize-label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 10px;
}

.w-customize-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 14px 18px;
    color: #f5f7fb;
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.w-customize-input:focus {
    border-color: rgba(77, 224, 255, 0.3);
}

.w-icon-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.w-icon-option {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
}

.w-icon-option:hover {
    background: rgba(255, 255, 255, 0.12);
}

.w-icon-option.w-selected {
    background: #f59e0b;
    border-color: #f59e0b;
}

.w-color-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.w-color-option {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 3px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.w-color-option:hover {
    transform: scale(1.15);
}

.w-color-option.w-selected {
    border-color: rgba(255, 255, 255, 0.8);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

/* ===== Animations ===== */
@keyframes w-count-up {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes w-pulse-glow {
    0%, 100% {
        box-shadow: 0 0 4px rgba(77, 224, 255, 0.2);
    }
    50% {
        box-shadow: 0 0 12px rgba(77, 224, 255, 0.4);
    }
}

.w-live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #34d399;
    display: inline-block;
    animation: w-live-pulse 2s ease-in-out infinite;
}

@keyframes w-live-pulse {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.4);
    }
    50% {
        opacity: 0.7;
        box-shadow: 0 0 0 4px rgba(52, 211, 153, 0);
    }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .w-score-body {
        grid-template-columns: 100px 1fr;
        gap: 14px;
    }

    .w-score-ring {
        width: 100px;
        height: 100px;
    }

    .w-score-number {
        font-size: 1.8rem;
    }

    .w-drive-stats-bar {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .w-drive-stat {
        border-right: none;
        padding: 6px 0;
    }

    .w-session-card {
        grid-template-columns: 40px 1fr auto;
        gap: 10px;
        padding: 14px;
    }

    .w-map-stats {
        flex-wrap: wrap;
        gap: 8px;
        justify-content: center;
    }

    .w-battery-pct {
        font-size: 3rem;
    }

    .w-battery-range-value {
        font-size: 1.8rem;
    }

    .w-controls-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .w-gauge-svg {
        width: 160px;
        height: 130px;
    }

    .w-gauge-value {
        font-size: 2.6rem;
    }
}

@media (max-width: 480px) {
    .w-sessions-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .w-savings-amount {
        font-size: 2.4rem;
    }

    .w-savings-bar-row {
        grid-template-columns: 70px 1fr 45px;
    }

    .w-score-bar-row {
        grid-template-columns: 75px 1fr 25px;
    }
}
