.ir-widget-container {
    position: relative;
    width: 37.5rem;
    /* 600px */
    height: 37.5rem;
    /* 600px */
    margin: 0 auto;
    /* border: 1px dashed #ccc; Debug frame */
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: visible;
}

.ir-center-wrapper {
    position: absolute;
    width: 12.5rem;
    /* 200px */
    height: 12.5rem;
    /* 200px */
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ir-gear-container {
    position: absolute;
    width: 100%;
    height: 100%;
    /* Transition handled by JS or CSS? JS handles transform updates directly */
}

.ir-gear-svg {
    width: 12.5rem;
    /* 200px */
    height: 12.5rem;
    /* 200px */
    display: block;
}

.ir-center-image {
    position: absolute;
    width: 7.5rem;
    /* 120px */
    height: 7.5rem;
    /* 120px */
    border-radius: 50%;
    overflow: hidden;
    background: #000;
    border: 0.25rem solid var(--ir-primary, #4aa3ce);
    /* 4px */
    z-index: 2;
}

.ir-center-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.ir-orbital-wrapper {
    position: absolute;
    width: 0;
    height: 0;
    top: 50%;
    left: 50%;
}

.ir-orbital-item {
    position: absolute;
    width: 5rem;
    /* 80px */
    height: 5rem;
    /* 80px */
    /* Start centered, JS moves them */
    top: -2.5rem;
    /* -40px */
    left: -2.5rem;
    /* -40px */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.ir-item-icon {
    width: 3.125rem;
    /* 50px */
    height: 3.125rem;
    /* 50px */
    object-fit: contain;
    background: #222;
    border: 0.125rem solid var(--ir-primary, #4aa3ce);
    /* 2px */
    border-radius: 0.625rem;
    /* 10px */
    padding: 0.3125rem;
    /* 5px */
    box-shadow: 0 0 0.625rem rgba(var(--ir-primary-rgb), 0.5);
    /* 10px */
    /* We can't easy vary alpha with hex-in-var, keeping as is or ignoring for now */
}

.ir-item-title {
    font-size: 0.75rem;
    /* 12px */
    color: #fff;
    margin: 0.3125rem 0 0;
    /* 5px */
    width: 7.5rem;
    /* 120px */
    /* Allow wider text below */
    text-shadow: 0 0 0.3125rem #000;
    /* 5px */
}

.ir-item-clickable {
    cursor: pointer;
}

.ir-item-clickable:hover .ir-item-icon {
    transform: scale(1.1);
    transition: transform 0.2s ease;
}

.ir-hidden {
    opacity: 0 !important;
}

/* Dashicons Support */
.ir-item-icon.ir-dashicon {
    display: inline-block;
    width: 2rem;
    /* 32px */
    height: 2rem;
    /* 32px */
    line-height: 2rem;
    /* 32px */
    text-align: center;
    font-size: 2rem;
    /* 32px */
    color: var(--ir-primary, #4aa3ce);
}

/* Modal Styles */
.ir-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(0.5rem);
    /* 8px */
    -webkit-backdrop-filter: blur(0.5rem);
    /* 8px */
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.ir-modal-overlay.ir-hidden {
    opacity: 0;
    pointer-events: none;
    display: none;
    /* fallback for browsers that don't support pointer-events correctly with transition */
}

.ir-modal-container {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(1rem);
    /* 16px */
    -webkit-backdrop-filter: blur(1rem);
    /* 16px */
    border: 0.0625rem solid rgba(255, 255, 255, 0.2);
    /* 1px */
    border-radius: 1.5rem;
    /* 24px */
    padding: 3.75rem 2.5rem 2.5rem;
    /* 60px 40px 40px */
    /* Top padding for close button */
    width: 70vw;
    height: 70vh;
    max-width: none;
    position: relative;
    box-shadow: 0 1.5625rem 3.125rem -0.75rem rgba(0, 0, 0, 0.5);
    /* 25px 50px -12px */
    color: #fff;
    animation: irModalScale 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    overflow: hidden;
}

@keyframes irModalScale {
    from {
        transform: scale(0.8);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.ir-modal-close {
    position: absolute;
    top: 1.25rem;
    /* 20px */
    right: 1.25rem;
    /* 20px */
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 2rem;
    /* 32px */
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.ir-modal-close:hover {
    color: #fff;
}

.ir-modal-content {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    text-align: left;
    width: 100%;
    height: 100%;
}

.ir-modal-media {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 0;
    padding-right: 1.875rem;
    /* 30px */
    border-right: 0.0625rem solid rgba(255, 255, 255, 0.1);
    /* 1px */
}

.ir-modal-media img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 0.9375rem;
    /* 15px */
    box-shadow: 0 0 1.25rem rgba(var(--ir-primary-rgb), 0.4);
    /* 20px */
}

.ir-modal-media .dashicons {
    font-size: 9.375rem;
    /* 150px */
    width: 9.375rem;
    /* 150px */
    height: 9.375rem;
    /* 150px */
    color: var(--ir-primary, #4aa3ce);
    text-shadow: 0 0 0.9375rem rgba(var(--ir-primary-rgb), 0.5);
    /* 15px */
}

.ir-modal-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding-left: 1.875rem;
    /* 30px */
    overflow: hidden;
}

.ir-modal-text h2 {
    font-size: 1.75rem;
    /* 28px */
    margin: 0 0 0.625rem;
    /* 10px */
    /* Reduced margin */
    font-weight: 700;
    color: var(--ir-primary, #4aa3ce);
    line-height: 1.2;
    align-self: flex-start;
    /* Ensure top alignment */
}

.ir-modal-desc {
    font-size: 0.4rem;
    /* 13px */
    /* Decreased from 14px */
    line-height: 1.6;
    color: var(--ir-fill, rgba(255, 255, 255, 0.8));
    overflow-y: auto;
    flex-grow: 1;
    padding-right: 0.9375rem;
    /* 15px */
}

/* Custom Scrollbar */
.ir-modal-desc::-webkit-scrollbar {
    width: 0.375rem;
    /* 6px */
}

.ir-modal-desc::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 0.1875rem;
    /* 3px */
}

.ir-modal-desc::-webkit-scrollbar-thumb {
    background: var(--ir-primary, rgba(255, 255, 255, 0.2));
    border-radius: 0.1875rem;
    /* 3px */
}