/* =============================================
   Lịch Âm Việt Nam - Plugin Styles
   Màu ấm áp, đẹp và sống động
============================================= */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@300;400;500;600;700;800&display=swap');

/* ── ROOT VARIABLES ── */
:root {
    --licham-primary:    #c0392b;
    --licham-primary-dk: #96281b;
    --licham-orange:     #e67e22;
    --licham-gold:       #f39c12;
    --licham-gold-lt:    #fef9e7;
    --licham-red:        #e74c3c;
    --licham-brown:      #8d5524;
    --licham-cream:      #fdf6ec;
    --licham-cream2:     #fef3e2;
    --licham-green:      #27ae60;
    --licham-bg:         #fff9f2;
    --licham-text:       #3d2b1f;
    --licham-text-lt:    #7a5c4a;
    --licham-border:     #f0d9c0;
    --licham-shadow:     rgba(192,57,43,0.12);
    --licham-radius:     16px;
    --licham-radius-sm:  10px;
    --licham-font:       'Be Vietnam Pro', 'Segoe UI', sans-serif;
}

/* ── WIDGET WRAPPER ── */
.licham-widget {
    font-family: var(--licham-font);
    color: var(--licham-text);
    background: var(--licham-bg);
    max-width: 780px;
    margin: 0 auto 32px;
    border-radius: var(--licham-radius);
    box-shadow: 0 8px 40px var(--licham-shadow), 0 2px 8px rgba(0,0,0,0.06);
    overflow: hidden;
}

/* ── HEADER ── */
.licham-header {
    background: linear-gradient(135deg, #c0392b 0%, #e74c3c 40%, #e67e22 100%);
    padding: 20px 24px 16px;
    position: relative;
    overflow: hidden;
}
.licham-header::before {
    content: '🌙';
    position: absolute;
    right: -10px;
    top: -20px;
    font-size: 100px;
    opacity: 0.08;
    transform: rotate(-15deg);
}
.licham-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    position: relative;
}
.licham-logo {
    font-size: 1.15rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.5px;
    text-shadow: 0 1px 4px rgba(0,0,0,0.2);
}
.licham-nav-day {
    display: flex;
    align-items: center;
    gap: 12px;
}
.licham-nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: rgba(255,255,255,0.2);
    color: #fff;
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.1rem;
    transition: background 0.2s;
    backdrop-filter: blur(4px);
}
.licham-nav-btn:hover {
    background: rgba(255,255,255,0.35);
    color: #fff;
    text-decoration: none;
}
.licham-nav-label {
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.3px;
}

/* ── MAIN DATE CARD ── */
.licham-main-card {
    display: flex;
    align-items: stretch;
    background: linear-gradient(135deg, #fff9f2 0%, #fef3e2 100%);
    border-bottom: 2px solid var(--licham-border);
    padding: 0;
}
.licham-solar-block,
.licham-lunar-block {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 28px 20px;
    text-align: center;
}
.licham-solar-block {
    border-right: 1px solid var(--licham-border);
    background: linear-gradient(160deg, #fff 60%, #fef9f2 100%);
}
.licham-solar-day {
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    color: var(--licham-primary);
    text-shadow: 2px 4px 12px rgba(192,57,43,0.18);
    letter-spacing: -2px;
}
.licham-solar-label {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--licham-text-lt);
    margin: 6px 0 4px;
}
.licham-solar-month {
    font-size: 0.9rem;
    color: var(--licham-text-lt);
    font-weight: 500;
}
.licham-lunar-block {
    background: linear-gradient(160deg, #fef9f2 0%, #fef3e2 100%);
}
.licham-lunar-day {
    font-size: 5rem;
    font-weight: 800;
    line-height: 1;
    color: var(--licham-gold);
    text-shadow: 2px 4px 12px rgba(243,156,18,0.25);
    letter-spacing: -2px;
}
.licham-lunar-label {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--licham-orange);
    margin: 6px 0 4px;
}
.licham-lunar-month {
    font-size: 0.88rem;
    color: var(--licham-text-lt);
    font-weight: 500;
}
.licham-divider-vert {
    display: none;
}

/* ── INFO GRID ── */
.licham-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 20px 20px 8px;
}
.licham-info-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: var(--licham-radius-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}
.licham-info-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}
.licham-card-orange { background: linear-gradient(135deg, #fff3e0, #ffe0b2); border-left: 4px solid #e67e22; }
.licham-card-red    { background: linear-gradient(135deg, #fce4e4, #f9caca); border-left: 4px solid #e74c3c; }
.licham-card-gold   { background: linear-gradient(135deg, #fff9e6, #fef3c7); border-left: 4px solid #f39c12; }
.licham-card-green  { background: linear-gradient(135deg, #e8f8ef, #d1f2e3); border-left: 4px solid #27ae60; }

.licham-info-icon {
    font-size: 1.6rem;
    line-height: 1;
    flex-shrink: 0;
}
.licham-info-title {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--licham-text-lt);
    margin-bottom: 3px;
}
.licham-info-value {
    font-size: 1rem;
    font-weight: 700;
    color: var(--licham-text);
}

/* ── SECTIONS ── */
.licham-section {
    padding: 20px 20px;
    border-top: 1px solid var(--licham-border);
}
.licham-section-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--licham-primary);
    margin-bottom: 14px;
    letter-spacing: 0.3px;
}

/* ── HOÀNG ĐẠO ── */
.licham-hoangdao-section {
    background: linear-gradient(135deg, #fff8f0 0%, #ffeedd 100%);
}
.licham-hoangdao-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.licham-hoangdao-item {
    background: linear-gradient(135deg, #e67e22, #f39c12);
    color: #fff;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 20px;
    box-shadow: 0 2px 8px rgba(230,126,34,0.3);
    letter-spacing: 0.3px;
}

/* ── LỊCH THÁNG ── */
.licham-calendar-section {
    background: #fff;
}
.licham-cal-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.licham-cal-nav-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: var(--licham-cream2);
    color: var(--licham-primary);
    border-radius: 50%;
    text-decoration: none;
    font-weight: 700;
    transition: background 0.2s;
    font-size: 1rem;
    border: 1.5px solid var(--licham-border);
}
.licham-cal-nav-btn:hover {
    background: var(--licham-primary);
    color: #fff;
    text-decoration: none;
    border-color: var(--licham-primary);
}
.licham-cal-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--licham-text);
    text-align: center;
}
.licham-cal-title small {
    display: block;
    font-size: 0.72rem;
    color: var(--licham-text-lt);
    font-weight: 400;
    margin-top: 2px;
}

/* Calendar grid: 7 cols */
.licham-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}
.licham-cal-header {
    text-align: center;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--licham-text-lt);
    padding: 6px 0;
    letter-spacing: 0.5px;
}
.licham-cal-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 7px 4px 6px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--licham-text);
    background: transparent;
    transition: all 0.18s;
    min-height: 52px;
    cursor: pointer;
    border: 1.5px solid transparent;
}
.licham-cal-cell:hover {
    background: var(--licham-cream2);
    border-color: var(--licham-border);
    text-decoration: none;
    color: var(--licham-primary);
    transform: scale(1.05);
}
.licham-cal-empty {
    cursor: default;
    pointer-events: none;
}
.licham-cal-solar {
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.1;
}
.licham-cal-lunar {
    font-size: 0.65rem;
    color: var(--licham-text-lt);
    margin-top: 2px;
    font-weight: 500;
}
/* Today */
.licham-cal-today {
    background: linear-gradient(135deg, #c0392b, #e74c3c) !important;
    color: #fff !important;
    border-color: transparent !important;
    box-shadow: 0 4px 16px rgba(192,57,43,0.35);
}
.licham-cal-today .licham-cal-lunar {
    color: rgba(255,255,255,0.8) !important;
}
.licham-cal-today:hover {
    transform: scale(1.08);
    color: #fff !important;
}
/* Sunday */
.licham-cal-sunday .licham-cal-solar { color: #e74c3c; }
.licham-cal-saturday .licham-cal-solar { color: #3498db; }
.licham-cal-today .licham-cal-solar,
.licham-cal-today .licham-cal-lunar { color: #fff !important; }

/* ── ĐỔI NGÀY ── */
.licham-convert-section {
    background: linear-gradient(135deg, #fff9f2 0%, #fef3e2 100%);
}
.licham-convert-inputs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}
.licham-input {
    flex: 1;
    min-width: 70px;
    max-width: 120px;
    padding: 10px 14px;
    border: 2px solid var(--licham-border);
    border-radius: var(--licham-radius-sm);
    font-family: var(--licham-font);
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--licham-text);
    background: #fff;
    outline: none;
    transition: border-color 0.2s;
    appearance: none;
    -moz-appearance: textfield;
}
.licham-input:focus {
    border-color: var(--licham-orange);
    box-shadow: 0 0 0 3px rgba(230,126,34,0.15);
}
.licham-input::-webkit-inner-spin-button,
.licham-input::-webkit-outer-spin-button { -webkit-appearance: none; }

.licham-btn {
    padding: 10px 22px;
    background: linear-gradient(135deg, #c0392b, #e74c3c);
    color: #fff;
    border: none;
    border-radius: var(--licham-radius-sm);
    font-family: var(--licham-font);
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 3px 12px rgba(192,57,43,0.3);
    white-space: nowrap;
}
.licham-btn:hover {
    background: linear-gradient(135deg, #96281b, #c0392b);
    transform: translateY(-1px);
    box-shadow: 0 5px 16px rgba(192,57,43,0.4);
}
.licham-convert-result {
    margin-top: 14px;
    padding: 14px 18px;
    background: #fff;
    border-radius: var(--licham-radius-sm);
    border: 1.5px solid var(--licham-border);
    font-size: 0.92rem;
    line-height: 1.7;
    display: none;
}
.licham-convert-result.show { display: block; }
.licham-convert-result strong { color: var(--licham-primary); }
.licham-convert-result a {
    color: var(--licham-orange);
    font-weight: 600;
    text-decoration: none;
}
.licham-convert-result a:hover { text-decoration: underline; }

/* ── STANDALONE PAGE ── */
.licham-standalone-wrap {
    max-width: 840px;
    margin: 32px auto;
    padding: 0 16px;
}

/* ── RESPONSIVE ── */
@media (max-width: 600px) {
    .licham-header { padding: 16px 16px 14px; }
    .licham-logo { font-size: 1rem; }
    .licham-nav-label { font-size: 0.85rem; }
    .licham-solar-day,
    .licham-lunar-day { font-size: 3.6rem; }
    .licham-main-card { flex-direction: column; }
    .licham-solar-block { border-right: none; border-bottom: 1px solid var(--licham-border); padding: 20px; }
    .licham-lunar-block { padding: 20px; }
    .licham-info-grid { grid-template-columns: 1fr 1fr; gap: 8px; padding: 14px 14px 6px; }
    .licham-info-icon { font-size: 1.3rem; }
    .licham-info-value { font-size: 0.9rem; }
    .licham-section { padding: 16px 14px; }
    .licham-cal-cell { min-height: 44px; padding: 5px 2px; }
    .licham-cal-solar { font-size: 0.88rem; }
    .licham-cal-lunar { font-size: 0.58rem; }
    .licham-convert-inputs { gap: 8px; }
    .licham-input { min-width: 60px; padding: 9px 10px; font-size: 0.88rem; }
    .licham-btn { padding: 9px 16px; font-size: 0.88rem; }
}
@media (max-width: 400px) {
    .licham-info-grid { grid-template-columns: 1fr; }
}
