/*
 * :is(#dc, .dc-…) keeps the ID-level specificity of the former inline #widget-id
 * styles, so these rules keep precedence over Elementor's generated widget CSS.
 */

:is(#dc, .dc-over-ons-cta) {
    --btn-hover: #c99432;
}

:is(#dc, .dc-over-ons-cta) * {
    box-sizing: border-box;
}

/* ==========================================
   SECTION
========================================== */
:is(#dc, .dc-over-ons-cta) .ons-cta {
    position: relative;
    background: var(--bg);
    padding: 120px 40px;
    overflow: hidden;
    text-align: center;
}

/* Background image + overlay */
:is(#dc, .dc-over-ons-cta) .ons-cta__bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, var(--overlay-opacity));
}

/* ==========================================
   DECORATIVE ELEMENTS
========================================== */
:is(#dc, .dc-over-ons-cta) .ons-cta__deco {
    position: absolute;
    pointer-events: none;
    z-index: 2;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__deco--circle-1 {
    width: 400px;
    height: 400px;
    border: 1px solid rgba(227, 168, 59, 0.1);
    border-radius: 50%;
    top: -200px;
    left: -100px;
    animation: ons-cta-rotate 70s linear infinite;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__deco--circle-2 {
    width: 300px;
    height: 300px;
    border: 1px solid rgba(157, 76, 19, 0.12);
    border-radius: 50%;
    bottom: -150px;
    right: -50px;
    animation: ons-cta-rotate 50s linear infinite reverse;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__deco--glow {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(227, 168, 59, 0.07), transparent 60%);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Corner accents */
:is(#dc, .dc-over-ons-cta) .ons-cta__corner {
    position: absolute;
    width: 80px;
    height: 80px;
    pointer-events: none;
    z-index: 3;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__corner--tl {
    top: 40px;
    left: 40px;
    border-top: 2px solid var(--accent);
    border-left: 2px solid var(--accent);
    opacity: 0.2;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__corner--br {
    bottom: 40px;
    right: 40px;
    border-bottom: 2px solid var(--accent);
    border-right: 2px solid var(--accent);
    opacity: 0.2;
}

/* Floating dots */
:is(#dc, .dc-over-ons-cta) .ons-cta__dots {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 2;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__dot {
    position: absolute;
    width: 5px;
    height: 5px;
    background: var(--accent);
    border-radius: 50%;
    opacity: 0.35;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__dot:nth-child(1) { top: 20%; left: 15%; animation: ons-cta-float 6s ease-in-out infinite; }
:is(#dc, .dc-over-ons-cta) .ons-cta__dot:nth-child(2) { top: 30%; right: 10%; animation: ons-cta-float 8s ease-in-out 1s infinite; }
:is(#dc, .dc-over-ons-cta) .ons-cta__dot:nth-child(3) { bottom: 25%; left: 10%; animation: ons-cta-float 7s ease-in-out 0.5s infinite; }
:is(#dc, .dc-over-ons-cta) .ons-cta__dot:nth-child(4) { bottom: 20%; right: 20%; animation: ons-cta-float 9s ease-in-out 2s infinite; }
:is(#dc, .dc-over-ons-cta) .ons-cta__dot:nth-child(5) { top: 55%; left: 5%; animation: ons-cta-float 5s ease-in-out 1.5s infinite; }
:is(#dc, .dc-over-ons-cta) .ons-cta__dot:nth-child(6) { top: 10%; right: 30%; animation: ons-cta-float 7s ease-in-out 3s infinite; }

/* ==========================================
   CONTENT
========================================== */
:is(#dc, .dc-over-ons-cta) .ons-cta__inner {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    z-index: 5;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--accent);
    font-family: 'Nothing You Could Do', cursive;
    font-size: 18px;
    font-weight: 400;
    margin-bottom: 20px;
    opacity: 0;
    animation: ons-cta-fadeInUp 0.8s ease 0.1s forwards;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__eyebrow::before,
:is(#dc, .dc-over-ons-cta) .ons-cta__eyebrow::after {
    content: '';
    width: 30px;
    height: 1px;
    background: var(--accent);
    opacity: 0.5;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: clamp(30px, 4.5vw, 52px);
    font-weight: 700;
    color: var(--text);
    margin: 0 0 20px 0;
    line-height: 1.2;
    opacity: 0;
    animation: ons-cta-fadeInUp 0.8s ease 0.2s forwards;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__description {
    font-family: 'DM Sans', sans-serif;
    font-size: 18px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.75;
    margin: 0 0 40px 0;
    opacity: 0;
    animation: ons-cta-fadeInUp 0.8s ease 0.3s forwards;
}

/* ==========================================
   BUTTON
========================================== */
:is(#dc, .dc-over-ons-cta) .ons-cta__btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 40px;
    font-family: 'DM Sans', sans-serif;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: var(--btn-bg);
    color: var(--btn-text);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: ons-cta-fadeInUp 0.8s ease 0.4s forwards;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__btn:hover {
    background: var(--btn-hover);
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(227, 168, 59, 0.4);
}

:is(#dc, .dc-over-ons-cta) .ons-cta__btn:hover::before {
    left: 100%;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__btn svg {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
}

:is(#dc, .dc-over-ons-cta) .ons-cta__btn:hover svg {
    transform: translateX(4px);
}

/* ==========================================
   ANIMATIONS
========================================== */
@keyframes ons-cta-fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes ons-cta-rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes ons-cta-float {
    0%, 100% { transform: translateY(0) translateX(0); opacity: 0.35; }
    50% { transform: translateY(-15px) translateX(8px); opacity: 0.7; }
}

/* ==========================================
   RESPONSIVE
========================================== */
@media (max-width: 768px) {
    :is(#dc, .dc-over-ons-cta) .ons-cta {
        padding: 80px 20px;
    }

    :is(#dc, .dc-over-ons-cta) .ons-cta__corner--tl {
        top: 20px;
        left: 20px;
        width: 50px;
        height: 50px;
    }

    :is(#dc, .dc-over-ons-cta) .ons-cta__corner--br {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }

    :is(#dc, .dc-over-ons-cta) .ons-cta__btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
}
