/* Domain View with Triangle Layout */

.domain-view-container {
    min-height: calc(100vh - 50px - env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
    padding: 20px;
    padding-top: calc(env(safe-area-inset-top) + 20px);
    position: relative;
}

/* Domain Header */
.domain-header {
    position: absolute;
    top: calc(env(safe-area-inset-top) + 20px);
    left: 20px;
    right: 20px;
    z-index: 10;
}

/* Domain Bubble at Top */
.domain-bubble {
    margin-top: 60px;
    margin-bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.domain-bubble-circle {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 2px solid var(--domain-color, #fbbf24);
    background: linear-gradient(135deg, 
        color-mix(in srgb, var(--domain-color, #fbbf24) 20%, transparent), 
        color-mix(in srgb, var(--domain-color, #fbbf24) 5%, transparent)
    );
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 40px color-mix(in srgb, var(--domain-color, #fbbf24) 20%, transparent);
}

.domain-bubble-letter {
    font-size: 48px;
    font-weight: 600;
    color: var(--domain-color);
    font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    letter-spacing: 0;
}

.domain-bubble-name {
    font-size: 24px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    margin: 0 0 8px 0;
}

.domain-bubble-description {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

/* Triangle Layout */
.focus-triangle {
    position: relative;
    width: 300px;
    height: 270px;
    margin: 40px auto;
}

.triangle-connections {
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
}

.focus-triangle-item {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

/* Position items precisely at triangle vertices */
.focus-triangle-item:nth-child(1) {
    top: 45px;
    left: 150px;
    transform: translate(-50%, -50%);
}

.focus-triangle-item:nth-child(2) {
    top: 225px;
    left: 45px;
    transform: translate(-50%, -50%);
}

.focus-triangle-item:nth-child(3) {
    top: 225px;
    left: 255px;
    transform: translate(-50%, -50%);
}

.focus-triangle-circle {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.focus-triangle-name {
    font-size: 16px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    line-height: 1.2;
}

.focus-triangle-item:hover .focus-triangle-circle,
.focus-triangle-item:active .focus-triangle-circle {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.15);
    transform: scale(1.05);
}

/* Mobile adjustments */
@media (max-width: 375px) {
    .domain-bubble-circle {
        width: 100px;
        height: 100px;
    }
    
    .domain-bubble-number {
        font-size: 36px;
    }
    
    .focus-triangle-circle {
        width: 80px;
        height: 80px;
    }
    
    .focus-triangle-name {
        font-size: 14px;
    }
}

/* Animation */
.domain-view-container {
    animation: slideIn 0.4s ease-out;
}

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