/* Sticky CTA Button Admin Styles */

/* Basic Icon Replacements for Font Awesome in Admin */
.wp-sticky-cta-button-admin i[class*="fa-"] {
    font-style: normal;
    font-weight: normal;
    display: inline-block;
    text-decoration: inherit;
    width: auto;
    height: auto;
    line-height: normal;
    vertical-align: baseline;
}

/* Icon mappings using Unicode for Admin */
.wp-sticky-cta-button-admin .fa-rocket:before { content: "🚀"; }
.wp-sticky-cta-button-admin .fa-download:before { content: "⬇"; }
.wp-sticky-cta-button-admin .fa-phone:before { content: "📞"; }
.wp-sticky-cta-button-admin .fa-envelope:before { content: "✉"; }
.wp-sticky-cta-button-admin .fa-shopping-cart:before { content: "🛒"; }
.wp-sticky-cta-button-admin .fa-play:before { content: "▶"; }
.wp-sticky-cta-button-admin .fa-star:before { content: "⭐"; }
.wp-sticky-cta-button-admin .fa-heart:before { content: "❤"; }
.wp-sticky-cta-button-admin .fa-thumbs-up:before { content: "👍"; }
.wp-sticky-cta-button-admin .fa-fire:before { content: "🔥"; }
.wp-sticky-cta-button-admin .fa-bolt:before { content: "⚡"; }
.wp-sticky-cta-button-admin .fa-gift:before { content: "🎁"; }
.wp-sticky-cta-button-admin .fa-bullhorn:before { content: "📢"; }
.wp-sticky-cta-button-admin .fa-comment:before { content: "💬"; }
.wp-sticky-cta-button-admin .fa-user:before { content: "👤"; }
.wp-sticky-cta-button-admin .fa-cog:before { content: "⚙"; }

/* Back to top icons for Admin */
.wp-sticky-cta-button-admin .fa-chevron-up:before { content: "▲"; }
.wp-sticky-cta-button-admin .fa-arrow-up:before { content: "↑"; }
.wp-sticky-cta-button-admin .fa-angle-up:before { content: "˄"; }
.wp-sticky-cta-button-admin .fa-caret-up:before { content: "▲"; }
.wp-sticky-cta-button-admin .fa-angle-double-up:before { content: "⌃"; }
.wp-sticky-cta-button-admin .fa-long-arrow-alt-up:before { content: "⇧"; }
.wp-sticky-cta-button-admin .fa-sort-up:before { content: "▲"; }
.wp-sticky-cta-button-admin .fa-level-up-alt:before { content: "↗"; }

.wp-sticky-cta-button-admin {
    max-width: 1200px;
}

.wp-sticky-cta-button-admin h1 {
    color: #17525b;
    font-size: 28px;
    margin-bottom: 30px;
}

/* Postbox Styling */
.wp-sticky-cta-button-admin .postbox {
    margin-bottom: 20px;
    border: 1px solid #c3c4c7;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.wp-sticky-cta-button-admin .postbox h2.hndle {
    background: #17525b;
    color: white;
    padding: 15px 20px;
    margin: 0;
    border-radius: 7px 7px 0 0;
    font-size: 16px;
    font-weight: 600;
    cursor: default;
}

.wp-sticky-cta-button-admin .postbox .inside {
    padding: 20px;
}

/* Toggle Switch */
.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 34px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #17525b;
}

input:checked + .slider:before {
    transform: translateX(26px);
}

/* Icon Selector */
.icon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 10px;
    margin-top: 10px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 8px;
    border: 1px solid #ddd;
}

.icon-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px 10px;
    background: white;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.icon-option:hover {
    border-color: #17525b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.icon-option.selected {
    border-color: #17525b;
    background: #17525b;
    color: white;
}

.icon-option i {
    font-size: 24px;
    margin-bottom: 8px;
    color: #17525b;
    line-height: 1;
}

.icon-option.selected i {
    color: white;
}

/* Ensure icons display properly in admin */
.icon-option i[class*="fa-"] {
    font-size: 28px;
    line-height: 1;
}

.icon-option span {
    font-size: 12px;
    font-weight: 500;
    line-height: 1.2;
}

/* Position Selector */
.position-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 10px;
}

.position-option {
    cursor: pointer;
    display: block;
}

.position-option input[type="radio"] {
    display: none;
}

.position-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    background: white;
    border: 2px solid #ddd;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.position-option:hover .position-visual {
    border-color: #17525b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.position-option.selected .position-visual {
    border-color: #17525b;
    background: #f0f8ff;
}

.screen-representation {
    width: 80px;
    height: 60px;
    background: #f5f5f5;
    border: 2px solid #ccc;
    border-radius: 4px;
    position: relative;
    margin-bottom: 10px;
}

.button-dot {
    width: 8px;
    height: 8px;
    background: #17525b;
    border-radius: 50%;
    position: absolute;
}

.position-visual.top-left .button-dot {
    top: 8px;
    left: 8px;
}

.position-visual.top-center .button-dot {
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
}

.position-visual.top-right .button-dot {
    top: 8px;
    right: 8px;
}

.position-visual.center-left .button-dot {
    top: 50%;
    left: 8px;
    transform: translateY(-50%);
}

.position-visual.center-right .button-dot {
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
}

.position-visual.bottom-left .button-dot {
    bottom: 8px;
    left: 8px;
}

.position-visual.bottom-center .button-dot {
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
}

.position-visual.bottom-right .button-dot {
    bottom: 8px;
    right: 8px;
}

.position-visual span {
    font-size: 13px;
    font-weight: 500;
    color: #333;
}

/* Submit Button */
.wp-sticky-cta-button-admin .button-hero {
    background: #17525b !important;
    border-color: #17525b !important;
    color: white !important;
    font-size: 16px !important;
    padding: 12px 30px !important;
    border-radius: 6px !important;
    margin-top: 20px;
}

.wp-sticky-cta-button-admin .button-hero:hover {
    background: #0f3d44 !important;
    border-color: #0f3d44 !important;
}
