/*
  © 2025 Eden Memory. All rights reserved.
  Shared UI Components
*/

/* --- CUSTOM SELECT / DROPDOWN --- */
.custom-select-container {
    position: relative;
    width: 100%;
}

.custom-select-trigger {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 16px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    background: var(--bg-surface);
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary);
    transition: all 0.2s ease;
    font-family: var(--font-main);
    text-align: left;
}

.custom-select-trigger:hover {
    border-color: var(--gray-400);
    background: var(--gray-50);
}

.custom-select-trigger.open {
    border-color: var(--color-black);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.custom-select-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    color: var(--text-primary);
}

.custom-select-icon svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
}

.custom-select-label {
    flex: 1;
    font-weight: 600;
}

.custom-select-arrow {
    transition: transform 0.2s ease;
    opacity: 0.6;
}

.custom-select-trigger.open .custom-select-arrow {
    transform: rotate(180deg);
}

.custom-select-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-surface);
    border: 1px solid var(--color-black);
    border-top: none;
    border-bottom-left-radius: var(--radius-md);
    border-bottom-right-radius: var(--radius-md);
    overflow: hidden;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    box-shadow: var(--shadow-soft);
}

.custom-select-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-select-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px 16px;
    border: none;
    background: var(--bg-surface);
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.15s ease;
    font-family: var(--font-main);
    text-align: left;
}

.custom-select-item:hover {
    background: var(--gray-50);
    color: var(--text-primary);
}

.custom-select-item.active {
    background: var(--gray-100);
    color: var(--color-black);
    font-weight: 600;
}

.custom-select-item svg {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
    stroke: currentColor;
}

/* --- ALERTS --- */
.ui-alert {
    display: flex;
    gap: 16px;
    background: #fffcf0;
    border: 1px solid #f9eeb3;
    padding: 24px;
    border-radius: 20px;
    margin: 20px auto 40px;
    max-width: 600px;
    text-align: left;
}

.ui-alert-icon {
    color: var(--warning-color);
    flex-shrink: 0;
}

.ui-alert-title {
    font-weight: 700;
    font-size: 16px;
    margin-bottom: 6px;
    color: #533f03;
    display: block;
}

.ui-alert-text {
    font-size: 15px;
    color: #7a5a00;
    line-height: 1.5;
}

/* --- CONTACT SELECTOR --- */
.ui-contact-row {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.ui-contact-btn {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    border: 2px solid #e5e5ea;
    background: #fff;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.ui-contact-btn svg {
    width: 24px;
    height: 24px;
    transition: transform 0.2s ease;
}

.ui-contact-btn:hover {
    border-color: #c8c8cc;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.ui-contact-btn:active {
    transform: translateY(0);
}

/* Instagram */
.ui-contact-btn[data-type="instagram"] svg {
    color: #e4405f;
}

.ui-contact-btn[data-type="instagram"].active,
.ui-contact-btn[data-type="instagram"]:hover {
    border-color: #e4405f;
    background: linear-gradient(135deg, rgba(228, 64, 95, 0.08), rgba(245, 96, 64, 0.06));
}

.ui-contact-btn[data-type="instagram"].active {
    box-shadow: 0 4px 16px rgba(228, 64, 95, 0.25);
}

/* Telegram */
.ui-contact-btn[data-type="telegram"] svg {
    color: #0088cc;
}

.ui-contact-btn[data-type="telegram"].active,
.ui-contact-btn[data-type="telegram"]:hover {
    border-color: #0088cc;
    background: rgba(0, 136, 204, 0.06);
}

.ui-contact-btn[data-type="telegram"].active {
    box-shadow: 0 4px 16px rgba(0, 136, 204, 0.25);
}

/* Facebook */
.ui-contact-btn[data-type="facebook"] svg {
    color: #1877f2;
}

.ui-contact-btn[data-type="facebook"].active,
.ui-contact-btn[data-type="facebook"]:hover {
    border-color: #1877f2;
    background: rgba(24, 119, 242, 0.06);
}

.ui-contact-btn[data-type="facebook"].active {
    box-shadow: 0 4px 16px rgba(24, 119, 242, 0.25);
}

/* Email */
.ui-contact-btn[data-type="email"] svg {
    color: #ea4335;
}

.ui-contact-btn[data-type="email"].active,
.ui-contact-btn[data-type="email"]:hover {
    border-color: #ea4335;
    background: rgba(234, 67, 53, 0.06);
}

.ui-contact-btn[data-type="email"].active {
    box-shadow: 0 4px 16px rgba(234, 67, 53, 0.25);
}

.ui-contact-btn.active svg {
    transform: scale(1.1);
}