/*
 * Manimahesh Yatra — widgets.css
 * Complete styles for ALL sidebar widget classes.
 * Class names match exactly what sidebar.php and WP_Widget classes output.
 * No mm- prefix on the core widget inner classes.
 */

/* ─────────────────────────────────────────────────────────────────────
   SIDEBAR SHELL  (already in style.css but reinforced here)
───────────────────────────────────────────────────────────────────── */
.mm-sidebar {
    background: #f0fdf9;
    border-left: 1px solid #e2f5f0;
}
.sidebar-inner {
    position: sticky;
    top: 94px;
    max-height: calc(100vh - 110px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #14b8a6 #e2f5f0;
    padding: 0 4px 40px 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.sidebar-inner::-webkit-scrollbar        { width: 4px; }
.sidebar-inner::-webkit-scrollbar-track  { background: #e2f5f0; border-radius: 2px; }
.sidebar-inner::-webkit-scrollbar-thumb  { background: #14b8a6; border-radius: 2px; }

/* ─────────────────────────────────────────────────────────────────────
   WIDGET CARD BASE  .sidebar-widget
───────────────────────────────────────────────────────────────────── */
.sidebar-widget {
    background: #ffffff;
    border-radius: 16px;
    padding: 20px 18px;
    box-shadow: 0 2px 16px rgba(20,184,166,.08);
    border: 1px solid #e8f5f2;
    transition: box-shadow .25s;
}
.sidebar-widget:hover {
    box-shadow: 0 4px 24px rgba(20,184,166,.13);
}

/* Widget title */
.sidebar-widget .widget-title,
.sidebar-widget h4.widget-title {
    font-size: .85rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0fdfa;
    display: flex;
    align-items: center;
    gap: 7px;
    letter-spacing: .01em;
    line-height: 1.3;
}
.sidebar-widget .widget-title i {
    color: #14b8a6;
    font-size: .8rem;
}

/* ─────────────────────────────────────────────────────────────────────
   1. SEARCH WIDGET  .widget-search
───────────────────────────────────────────────────────────────────── */
.widget-search-form {
    display: flex;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    transition: border-color .2s, box-shadow .2s;
}
.widget-search-form:focus-within {
    border-color: #14b8a6;
    box-shadow: 0 0 0 3px rgba(20,184,166,.12);
}
.widget-search-form input {
    flex: 1;
    border: none;
    padding: 10px 13px;
    font-family: inherit;
    font-size: .875rem;
    color: #1e293b;
    outline: none;
    background: transparent;
    min-width: 0;
}
.widget-search-form input::placeholder { color: #94a3b8; }
.widget-search-form button {
    background: #14b8a6;
    border: none;
    padding: 10px 14px;
    color: #fff;
    cursor: pointer;
    font-size: .88rem;
    transition: background .2s;
    flex-shrink: 0;
}
.widget-search-form button:hover { background: #0f766e; }

/* ─────────────────────────────────────────────────────────────────────
   2. QUICK BOOKING WIDGET  .widget-booking
───────────────────────────────────────────────────────────────────── */
.widget-booking {
    background: linear-gradient(140deg, #0f766e 0%, #14b8a6 100%) !important;
    border: none !important;
    box-shadow: 0 6px 28px rgba(20,184,166,.28) !important;
}
.widget-booking:hover {
    box-shadow: 0 10px 36px rgba(20,184,166,.36) !important;
}

.booking-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(255,255,255,.18);
    color: #fff;
    font-size: .68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    padding: 4px 12px;
    border-radius: 50px;
    margin-bottom: 10px;
}
.widget-title-white {
    font-size: 1rem;
    font-weight: 800;
    color: #fff;
    margin: 0 0 4px;
    line-height: 1.2;
}
.booking-sub {
    font-size: .78rem;
    color: rgba(255,255,255,.72);
    margin: 0 0 16px;
}
.booking-field {
    margin-bottom: 12px;
}
.booking-field label {
    display: block;
    font-size: .68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: rgba(255,255,255,.68);
    margin-bottom: 5px;
}
.booking-field select,
.booking-field input[type="date"] {
    width: 100%;
    background: rgba(255,255,255,.14);
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 8px;
    padding: 9px 11px;
    color: #fff;
    font-family: inherit;
    font-size: .86rem;
    outline: none;
    transition: border-color .2s, background .2s;
    -webkit-appearance: none;
    appearance: none;
    box-sizing: border-box;
}
.booking-field select:focus,
.booking-field input[type="date"]:focus {
    border-color: rgba(255,255,255,.7);
    background: rgba(255,255,255,.2);
}
.booking-field select option { color: #1e293b; background: #fff; }

/* Pilgrim counter */
.counter-row {
    display: inline-flex;
    align-items: center;
    background: rgba(255,255,255,.14);
    border: 1px solid rgba(255,255,255,.28);
    border-radius: 8px;
    overflow: hidden;
    user-select: none;
}
.counter-btn {
    background: rgba(255,255,255,.12);
    border: none;
    color: #fff;
    font-size: 1.1rem;
    width: 34px;
    height: 34px;
    cursor: pointer;
    transition: background .15s;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.counter-btn:hover { background: rgba(255,255,255,.28); }
.counter-val {
    min-width: 38px;
    text-align: center;
    font-size: .92rem;
    font-weight: 700;
    color: #fff;
    padding: 0 6px;
}

.booking-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin-top: 10px;
    padding: 12px 16px;
    background: #fff;
    color: #0f766e;
    border: none;
    border-radius: 10px;
    font-family: inherit;
    font-size: .88rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: background .2s, transform .18s, box-shadow .18s;
    box-shadow: 0 4px 14px rgba(0,0,0,.12);
}
.booking-cta:hover {
    background: #f0fdfa;
    color: #0f766e;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,.16);
}

/* ─────────────────────────────────────────────────────────────────────
   3. POPULAR PACKAGES WIDGET  .widget-popular
───────────────────────────────────────────────────────────────────── */
.popular-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.popular-item a {
    display: flex;
    gap: 11px;
    align-items: center;
    text-decoration: none;
    padding: 7px 6px;
    border-radius: 10px;
    transition: background .18s;
}
.popular-item a:hover { background: #f0fdfa; }
.popular-item img {
    width: 60px;
    height: 52px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    border: 1px solid #e2f5f0;
    display: block;
}
.popular-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
}
.popular-title {
    font-size: .82rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.popular-meta {
    font-size: .72rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 3px;
}
.popular-meta i { color: #14b8a6; font-size: .68rem; margin-right: 1px; }
.popular-price {
    font-size: .8rem;
    font-weight: 700;
    color: #14b8a6;
    display: block;
}

/* ─────────────────────────────────────────────────────────────────────
   4. YATRA DATES WIDGET  .widget-dates
───────────────────────────────────────────────────────────────────── */
.dates-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.date-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #e8f5f2;
    transition: border-color .2s, background .2s;
}
.date-item:hover {
    border-color: #14b8a6;
    background: #f0fdfa;
}
.date-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
    transition: transform .2s;
}
.date-item:hover .date-dot { transform: scale(1.35); }
.date-info { flex: 1; min-width: 0; }
.date-val {
    display: block;
    font-size: .82rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.2;
}
.date-type {
    font-size: .72rem;
    color: #64748b;
    display: block;
    margin-top: 2px;
}
.date-book {
    font-size: .7rem;
    font-weight: 700;
    color: #14b8a6;
    background: #f0fdfa;
    border: 1px solid #14b8a6;
    border-radius: 20px;
    padding: 4px 10px;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background .18s, color .18s;
}
.date-book:hover { background: #14b8a6; color: #fff; }

/* ─────────────────────────────────────────────────────────────────────
   5. WEATHER WIDGET  .widget-weather
───────────────────────────────────────────────────────────────────── */
.weather-main {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 13px;
    background: linear-gradient(135deg, #e0f2fe 0%, #f0fdfa 100%);
    border-radius: 12px;
    margin-bottom: 13px;
}
.weather-icon-big {
    font-size: 2.4rem;
    color: #0ea5e9;
    flex-shrink: 0;
    line-height: 1;
}
.weather-temp {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.temp-value {
    display: block;
    font-size: 1.9rem;
    font-weight: 800;
    color: #1e293b;
    line-height: 1;
}
.temp-label {
    font-size: .76rem;
    color: #64748b;
    line-height: 1.4;
}
.temp-label small {
    font-size: .68rem;
    color: #94a3b8;
    display: block;
}
.weather-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px;
    margin-bottom: 11px;
}
.weather-cell {
    background: #f8fafc;
    border: 1px solid #e8f5f2;
    border-radius: 8px;
    padding: 8px 7px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    text-align: center;
    transition: border-color .18s, background .18s;
}
.weather-cell:hover {
    border-color: #14b8a6;
    background: #f0fdfa;
}
.weather-cell i { color: #14b8a6; font-size: .8rem; }
.weather-cell span { font-size: .83rem; font-weight: 700; color: #1e293b; }
.weather-cell small { font-size: .67rem; color: #94a3b8; }
.weather-tip {
    font-size: .76rem;
    color: #64748b;
    background: #fffbeb;
    border-left: 3px solid #f59e0b;
    padding: 8px 10px;
    border-radius: 0 8px 8px 0;
    display: flex;
    align-items: flex-start;
    gap: 7px;
    line-height: 1.45;
    margin: 0;
}
.weather-tip i { color: #f59e0b; margin-top: 1px; flex-shrink: 0; font-size: .78rem; }

/* ─────────────────────────────────────────────────────────────────────
   6. YATRA TIPS WIDGET  .widget-tips
───────────────────────────────────────────────────────────────────── */
.tips-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
}
.tips-list li {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    font-size: .81rem;
    color: #475569;
    padding: 8px 0;
    border-bottom: 1px dashed #e2e8f0;
    line-height: 1.5;
}
.tips-list li:last-child { border-bottom: none; padding-bottom: 0; }
.tips-list li i {
    color: #14b8a6;
    margin-top: 3px;
    font-size: .76rem;
    flex-shrink: 0;
}

/* ─────────────────────────────────────────────────────────────────────
   7. RECENT POSTS WIDGET  .widget-recent
───────────────────────────────────────────────────────────────────── */
.recent-item {
    display: flex;
    gap: 11px;
    align-items: flex-start;
    padding: 9px 0;
    border-bottom: 1px solid #f1f5f9;
}
.recent-item:last-child { border-bottom: none; padding-bottom: 0; }
.recent-item img {
    width: 62px;
    height: 50px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    display: block;
    border: 1px solid #e2f5f0;
    transition: transform .3s;
}
.recent-item:hover img { transform: scale(1.05); }
.recent-item > div {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
a.recent-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: .81rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.35;
    text-decoration: none;
    transition: color .18s;
}
a.recent-title:hover { color: #14b8a6; }
.recent-date {
    font-size: .7rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 5px;
}
.recent-date i { font-size: .66rem; color: #14b8a6; }

/* ─────────────────────────────────────────────────────────────────────
   8. SOCIAL FOLLOW WIDGET  .widget-social
───────────────────────────────────────────────────────────────────── */
.social-follow-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
}
.sfb {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 13px 8px 11px;
    border-radius: 12px;
    text-decoration: none;
    color: #fff;
    transition: transform .2s, box-shadow .2s, filter .15s;
    position: relative;
    overflow: hidden;
}
.sfb:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0,0,0,.18);
    color: #fff;
}
.sfb i    { font-size: 1.2rem; }
.sfb span { font-size: .74rem; font-weight: 700; }
.sfb small{ font-size: .63rem; opacity: .84; }
.sfb.facebook  { background: linear-gradient(135deg, #1877f2 0%, #0d5fca 100%); }
.sfb.instagram { background: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%); }
.sfb.youtube   { background: linear-gradient(135deg, #ff3d3d 0%, #cc0000 100%); }
.sfb.whatsapp  { background: linear-gradient(135deg, #25d366 0%, #128c7e 100%); }

/* ─────────────────────────────────────────────────────────────────────
   WP_WIDGET WRAPPER CLASSES (output by register_sidebar before_widget)
   Maps .mm-widget-* wrappers to the same card style
───────────────────────────────────────────────────────────────────── */
.mm-widget {
    background: #fff;
    border-radius: 16px;
    padding: 20px 18px;
    box-shadow: 0 2px 16px rgba(20,184,166,.08);
    border: 1px solid #e8f5f2;
    transition: box-shadow .25s;
}
.mm-widget:hover { box-shadow: 0 4px 24px rgba(20,184,166,.13); }

/* Booking widget override */
.mm-widget-booking {
    background: linear-gradient(140deg, #0f766e 0%, #14b8a6 100%) !important;
    border: none !important;
    box-shadow: 0 6px 28px rgba(20,184,166,.28) !important;
}

/* ─────────────────────────────────────────────────────────────────────
   SCROLL ENTRANCE ANIMATION
───────────────────────────────────────────────────────────────────── */
.mm-widget-hidden {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity .4s ease, transform .4s ease;
}
.mm-widget-visible {
    opacity: 1;
    transform: translateY(0);
}
.sidebar-widget:nth-child(2) { animation-delay: .05s; }
.sidebar-widget:nth-child(3) { animation-delay: .10s; }
.sidebar-widget:nth-child(4) { animation-delay: .15s; }
.sidebar-widget:nth-child(5) { animation-delay: .20s; }
.sidebar-widget:nth-child(6) { animation-delay: .25s; }
.sidebar-widget:nth-child(7) { animation-delay: .30s; }
.sidebar-widget:nth-child(8) { animation-delay: .35s; }

/* ─────────────────────────────────────────────────────────────────────
   9. POPULAR POSTS & PACKAGES WIDGET  (.mm-widget-popitems)
───────────────────────────────────────────────────────────────────── */
.mm-popitems-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
}
.mm-popitem {
    border-bottom: 1px solid #f1f5f9;
}
.mm-popitem:last-child { border-bottom: none; }
.mm-popitem-link {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 9px 4px;
    text-decoration: none;
    border-radius: 8px;
    transition: background .18s;
    position: relative;
}
.mm-popitem-link:hover { background: #f0fdfa; }

/* Rank number */
.mm-popitem-num {
    width: 20px;
    height: 20px;
    border-radius: 5px;
    background: var(--primary);
    color: #fff;
    font-size: .65rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    line-height: 1;
}
.mm-popitem:nth-child(1) .mm-popitem-num { background: #f59e0b; }
.mm-popitem:nth-child(2) .mm-popitem-num { background: #94a3b8; }
.mm-popitem:nth-child(3) .mm-popitem-num { background: #d97706; }

/* Thumbnail */
.mm-popitem-img {
    width: 58px;
    height: 52px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    border: 1px solid #e8f5f2;
}
.mm-popitem-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .35s;
}
.mm-popitem-link:hover .mm-popitem-img img { transform: scale(1.08); }

/* Body */
.mm-popitem-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.mm-popitem-title {
    font-size: .82rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color .18s;
}
.mm-popitem-link:hover .mm-popitem-title { color: var(--primary); }
.mm-popitem-meta {
    font-size: .71rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 4px;
}
.mm-popitem-meta i { color: var(--primary); font-size: .67rem; }
.mm-popitem-price {
    font-size: .78rem;
    font-weight: 700;
    color: var(--primary);
}

/* ── Live Weather Widget ─────────────────────────────────────── */
.mm-weather-live-wrap { position: relative; }
.mm-weather-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 24px;
    color: #64748b;
    font-size: .84rem;
}
.mm-weather-spinner {
    width: 20px; height: 20px;
    border: 3px solid #e2f5f0;
    border-top-color: #14b8a6;
    border-radius: 50%;
    animation: mmWsSpin .8s linear infinite;
    flex-shrink: 0;
}
@keyframes mmWsSpin { to { transform: rotate(360deg); } }
.mm-weather-error {
    text-align: center;
    padding: 20px;
    color: #94a3b8;
    font-size: .82rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
}
.mm-weather-error i { color: #f59e0b; }
.mm-weather-live-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: .7rem;
    color: #94a3b8;
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px dashed #e2e8f0;
}
.mm-wt-live-dot {
    color: #22c55e;
    font-size: .5rem;
    animation: mmLivePulse 1.5s ease infinite;
}
@keyframes mmLivePulse { 0%,100%{opacity:1} 50%{opacity:.3} }
