* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #FF6B35;
    --primary-dark: #e55a2b;
    --secondary: #4ECDC4;
    --secondary-dark: #3bb3ab;
    --dark: #1a2634;
    --dark-light: #334155;
    --gray: #64748b;
    --gray-light: #e2e8f0;
    --gray-bg: #f8fafc;
    --white: #ffffff;
    --shadow: 0 20px 60px rgba(26, 38, 52, 0.10);
    --radius: 20px;
    --radius-sm: 12px;
    --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--gray-bg);
    color: var(--dark);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.app {
    max-width: 840px;
    width: 100%;
    background: var(--white);

    box-shadow: var(--shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ===== HEADER ===== */
.app-header {
    background: var(--dark);
    color: var(--white);
    padding: 24px 40px 24px;
    border-bottom: 4px solid var(--primary);
    position: sticky;
    top: 0;
    z-index: 50;
}

.app-header .brand {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: flex-start;
}

.app-header .brand i {
    font-size: 32px;
    color: var(--primary);
    background: rgba(255, 107, 53, 0.15);
    padding: 10px;
    border-radius: 14px;
}

.app-header .brand h1 {
    font-size: 33px;
    font-weight: 800;
}

.app-header .brand h1 span {
    color: var(--primary);
}

.app-header .brand small {
    display: block;
    font-size: 13px;
    font-weight: 400;
    color: var(--gray-light);
    opacity: 0.7;
    margin-top: -2px;
}

.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

.header-stats {
    display: flex;
    align-items: center;
    gap: 28px;
    background: rgba(255, 255, 255, 0.06);
    padding: 8px 24px 8px 20px;
    border-radius: 60px;
}

.header-stats .stat-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 500;
}

.header-stats .stat-item i {
    color: var(--secondary);
    font-size: 18px;
}

.header-stats .stat-item .num {
    font-size: 22px;
    font-weight: 700;
    color: var(--white);
    min-width: 28px;
    text-align: center;
}

.header-stats .stat-divider {
    width: 1px;
    height: 30px;
    background: rgba(255, 255, 255, 0.12);
}

.header-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.admin-btn,
.share-btn,
.vault-btn,
.member-login-btn,
.copy-lib-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--white);
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-decoration: none;
    text-align: center;
}

.admin-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
}

.share-btn {
    background: rgba(78, 205, 196, 0.15);
    border: 1px solid rgba(78, 205, 196, 0.3);
}
.share-btn:hover {
    background: var(--secondary);
    border-color: var(--secondary);
}

.vault-btn {
    background: rgba(255, 215, 0, 0.12);
    border: 1px solid rgba(255, 215, 0, 0.25);
}
.vault-btn:hover {
    background: #D4A017;
    border-color: #D4A017;
}

.member-login-btn {
    background: rgba(78, 205, 196, 0.12);
    border-color: rgba(78, 205, 196, 0.3);
}
.member-login-btn:hover {
    background: var(--secondary);
    border-color: var(--secondary);
}
.member-login-btn.logged-in {
    background: rgba(255, 107, 53, 0.15);
    border-color: var(--primary);
}
.member-login-btn.logged-in:hover {
    background: var(--primary);
}

.copy-lib-btn {
    background: rgba(255, 107, 53, 0.15);
    border: 1px solid rgba(255, 107, 53, 0.3);
}
.copy-lib-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
}

.brand-icon-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #af522f;
    font-size: 32px;
    line-height: 1;
    flex-shrink: 0;
    border: 3px solid #ff6b35;
}

.member-login-status {
    font-size: 13px;
    color: var(--gray-light);
    margin-left: 8px;
}

/* ===== HEADER RESPONSIVE ===== */
@media (max-width: 820px) {
    .app-header {
        padding: 20px 16px;
    }
    .header-top {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    .brand {
        justify-content: center;
    }
    .header-stats {
        justify-content: center;
        padding: 6px 16px;
    }
    .header-stats .stat-item {
        font-size: 14px;
    }
    .header-stats .stat-item .num {
        font-size: 20px;
    }
    .header-buttons {
        gap: 8px;
        margin-top: 12px;
    }
    .admin-btn,
    .share-btn,
    .vault-btn,
    .member-login-btn,
    .copy-lib-btn {
        font-size: 14px;
        padding: 6px 14px;
        flex: 1 0 auto;
    }
}

@media (max-width: 480px) {
    .header-buttons {
        gap: 8px;
    }
    .admin-btn,
    .share-btn,
    .vault-btn,
    .member-login-btn,
    .copy-lib-btn {
        font-size: 12px;
        padding: 8px 8px;
    }
    .header-stats .stat-item {
        font-size: 12px;
        gap: 4px;
    }
    .header-stats .stat-item .num {
        font-size: 17px;
        min-width: 20px;
    }
}

/* ===== TABS ===== */
.tabs {
    display: flex;
    background: #1a26341c;
    border-bottom: 1px solid var(--gray-light);
    padding: 0 32px;
    gap: 4px;
    flex-wrap: wrap;
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 16px 18px;
    background: transparent;
    border: none;
    font-family: inherit;
    font-size: 16px;
    font-weight: 600;
    color: var(--gray);
    cursor: pointer;
    transition: var(--transition);
    border-bottom: 3px solid transparent;
}

.tab-btn i {
    font-size: 18px;
}

.tab-btn:hover {
    color: var(--dark);
    background: rgba(255, 255, 255, 0.5);
}

.tab-btn.active {
    color: var(--primary);
    border-bottom-color: var(--primary);
    background: var(--white);
}

.tab-btn .badge {
    background: var(--primary);
    color: var(--white);
    font-size: 16px;
    font-weight: 700;
    padding: 2px 10px;
    border-radius: 30px;
    margin-left: 4px;
    min-width: 20px;
    text-align: center;
}

.tab-btn .badge.secondary {
    background: var(--secondary);
}

.tab-content {
    display: none;
    padding: 20px 20px 20px;
    animation: fadeUp 0.4s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== REGISTER ===== */
.register-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 20px;
    align-items: start;
}

.register-form {
    background: var(--gray-bg);
    padding: 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-light);
}

.register-form h2 {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.register-form h2 i {
    color: var(--primary);
}

.register-form .subtitle {
    color: var(--gray);
    font-size: 16px;
    margin-bottom: 24px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: var(--dark-light);
    margin-bottom: 5px;
}

.form-group label i {
    margin-right: 6px;
    color: var(--primary);
    width: 18px;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(255, 107, 53, 0.08);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 16px;
    transition: var(--transition);
    background: #ffb59a33;
    color: var(--dark);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 107, 53, 0.10);
}

.form-group .referrer-name-display {
    font-size: 16px;
    color: var(--gray-light);
    margin-top: 6px;
    padding: 10px 12px;
    background: var(--white);
    border-radius: var(--radius-sm);
    border: 2px dotted var(--gray-light);
    min-height: 40px;
    display: flex;
    align-items: center;
}

.form-group .referrer-name-display .found {
    color: var(--primary);
    font-weight: 600;
}

.form-group .referrer-name-display .not-found {
    color: #ef4444;
}

.form-group .referrer-name-display .placeholder {
    color: var(--gray);
    font-style: italic;
}

.gray-box {
    background: var(--gray-bg);
    padding: 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-light);
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 32px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    width: 100%;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
}
.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 107, 53, 0.30);
}
.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: var(--secondary);
    color: var(--white);
}
.btn-secondary:hover {
    background: var(--secondary-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(78, 205, 196, 0.30);
}

.btn-sm {
    padding: 8px 18px;
    font-size: 16px;
    width: auto;
}

.btn-danger {
    background: #ef4444;
    color: var(--white);
}
.btn-danger:hover {
    background: #dc2626;
}

/* ===== SLOTS / TABLE ===== */
.slots-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
}

.slots-header h2 {
    font-size: 22px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.slots-header h2 i {
    color: var(--secondary);
}

.slots-search {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--gray-bg);
    padding: 4px 16px 4px 4px;
    border-radius: 60px;
    border: 1px solid var(--gray-light);
}

.slots-search i {
    color: var(--gray);
    font-size: 16px;
    padding-left: 8px;
}

.slots-search input {
    border: none;
    background: transparent;
    padding: 8px 0;
    font-family: inherit;
    font-size: 16px;
    min-width: 140px;
    outline: none;
}

.slots-header .actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.slots-header .actions .slots-search {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1 1 auto;
    min-width: 180px;
}

.slots-header .actions .slots-search input {
    flex: 1;
    min-width: 120px;
}

.slots-header .actions #exportCsvBtn {
    flex-shrink: 0;
}

.table-wrap {
    overflow-x: auto;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-light);
    background: var(--white);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

thead {
    background: var(--gray-bg);
    border-bottom: 2px solid var(--gray-light);
}

th {
    text-align: left;
    padding: 14px 20px;
    font-weight: 600;
    color: var(--dark-light);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

td {
    padding: 10px 10px;
    border-bottom: 1px solid var(--gray-light);
    color: var(--dark);
    vertical-align: middle;
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background: rgba(78, 205, 196, 0.04);
}

.table-wrap table th:nth-child(1),
.table-wrap table td:nth-child(1) {
    width: 10%;
}
.table-wrap table th:nth-child(2),
.table-wrap table td:nth-child(2) {
    width: 30%;
}
.table-wrap table th:nth-child(3),
.table-wrap table td:nth-child(3) {
    width: 23%;
}
.table-wrap table th:nth-child(4),
.table-wrap table td:nth-child(4) {
    width: 32%;
}
.table-wrap table th:nth-child(5),
.table-wrap table td:nth-child(5) {
    width: 5%;
}

.slot-number {
    font-family: monospace;
    font-weight: 700;
    color: var(--primary);
}

.member-name-truncate {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    vertical-align: middle;
}

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--gray);
}

.empty-state i {
    font-size: 56px;
    color: var(--gray-light);
    margin-bottom: 16px;
    display: block;
}

.empty-state h3 {
    font-size: 18px;
    color: var(--dark-light);
    margin-bottom: 6px;
}

/* ===== NOTIFICATIONS ===== */
.notif-log {
    background: #ffffff;
    padding: 18px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-light);
    max-height: 480px;
    overflow-y: auto;
}

.notif-log h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.notif-log h3 i {
    color: var(--primary);
}

/* ===== BELL NOTIFICATION DROPDOWN (minimalist) ===== */
.notif-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid #f2f2f2;
    cursor: pointer;
    transition: background 0.15s ease;
}
.notif-item:last-child {
    border-bottom: none;
}
.notif-item:hover {
    background: #fafafa;
}
/* FIX: Itago ang red dot indicator sa notifications */
.notif-item .notif-dot {
    display: none !important;
}

/* Optional: Bahagyang bawasan ang gap para hindi masyadong malaki ang space sa kaliwa */
.notif-item {
    gap: 8px !important;
}
.notif-item .notif-icon {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #f5f5f7;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
}
.notif-item.unread .notif-icon {
    background: #fff1ea;
    color: #FF6B35;
}
.notif-item .notif-body {
    flex: 1;
    min-width: 0;
}
.notif-item .notif-msg {
    font-size: 13.5px;
    line-height: 1.4;
    color: #1a1a1a;
    font-weight: 400;
}
.notif-item.unread .notif-msg {
    font-weight: 600;
}
.notif-item .notif-time {
    font-size: 11.5px;
    color: #9ca3af;
    margin-top: 3px;
}

.log-item {
    display: flex;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--gray-light);
    align-items: flex-start;
}

.log-item:last-child {
    border-bottom: none;
}

.log-icon {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(78, 205, 196, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary);
    flex-shrink: 0;
    font-size: 16px;
}

.log-content {
    flex: 1;
}

.log-content .log-title {
    font-weight: 600;
    font-size: 16px;
}

.log-content .log-detail {
    font-size: 14px;
    color: var(--gray);
    margin-top: 2px;
	line-height: 1.3em;
}

.log-content .log-time {
    font-size: 16px;
    color: var(--gray);
    opacity: 0.6;
    margin-top: 4px;
}

.log-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--gray);
}

.log-empty i {
    font-size: 40px;
    color: var(--gray-light);
    margin-bottom: 12px;
    display: block;
}

/* ===== TOAST & CONFETTI ===== */
.toast-container {
    position: fixed;
    top: 180px;
    right: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 400px;
    width: 100%;
}

.toast {
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    background: var(--white);
    box-shadow: var(--shadow);
    border-left: 4px solid var(--secondary);
    display: flex;
    align-items: center;
    gap: 14px;
    animation: slideIn 0.4s ease;
    font-size: 16px;
}

.toast.success {
    border-left-color: var(--secondary);
}
.toast.error {
    border-left-color: #ef4444;
}
.toast.info {
    border-left-color: #3b82f6;
}

.toast i {
    font-size: 20px;
}
.toast.success i {
    color: var(--secondary);
}
.toast.error i {
    color: #ef4444;
}
.toast.info i {
    color: #3b82f6;
}

.toast .toast-msg {
    flex: 1;
    font-weight: 500;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.confetti-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9998;
    overflow: hidden;
}

.confetti-piece {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 2px;
    animation: confettiFall linear forwards;
}

@keyframes confettiFall {
    0% {
        opacity: 1;
        transform: translateY(-20px) rotate(0deg) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(110vh) rotate(720deg) scale(0.3);
    }
}

/* ===== SOCIAL PROOF ===== */
.social-proof {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.social-proof .card {
    background: var(--gray-bg);
    padding: 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-light);
}

.social-proof .card h4 {
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}

.social-proof .card .avatar-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

/* ===== WHY CARD ===== */
.why-card {
    background: linear-gradient(145deg, var(--dark), #1e2a3a);
    color: var(--white);
    border: none;
    padding: 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--gray-light);
    margin-bottom: 16px;

}

.why-card .why-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.why-card .why-header i {
    font-size: 24px;
    color: var(--primary);
}

.why-card .why-header h3 {
    font-size: 19px;
    font-weight: 600;
}

.why-card .why-header button {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    margin-left: auto;
}

.why-card .why-header button:hover {
    background: rgba(255, 255, 255, 0.2);
}

.why-card .why-content {
    color: rgba(255, 255, 255, 0.85);
    font-size: 16px;
    line-height: 1.7;
    text-align: left;
    opacity: 0.85;
}

.why-card .why-content ul {
    list-style: none;
    padding-left: 0;
    margin: 12px 0;
}

.why-card .why-content .divider {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 14px;
    margin-top: 12px;
}

.why-card .why-content .team-first {
    font-size: 18px;
    line-height: 1.2;
    font-weight: 700;
    color: var(--primary);
}

.why-card .why-content .spacer {
    padding: 10px 0;
}

/* ===== MODALS ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 10px;
}

.modal-overlay.active {
    display: flex;
}

.modal-box {
    background: var(--white);
    padding: 32px 36px 28px;
    border-radius: var(--radius-sm);
    max-width: 400px;
    width: 100%;
    box-shadow: var(--shadow);
    text-align: center;
    position: relative;
}

.modal-box h3 {
    margin-bottom: 8px;
    font-size: 20px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.modal-box h3 i {
    color: #ffffff;
}

.modal-box p {
    color: var(--gray);
    font-size: 14px;
    margin-bottom: 20px;
}

.modal-box input {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--gray-light);
    border-radius: var(--radius-sm);
    font-size: 16px;
    letter-spacing: 4px;
    text-align: center;
    margin-bottom: 16px;
    font-family: inherit;
    transition: var(--transition);
}

.modal-box input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(255, 107, 53, 0.10);
}

.modal-box .btn {
    width: 100%;
    padding: 12px;
    font-size: 16px;
}

.modal-box .close-btn {
    position: absolute;
    top: 0px;
    right: 5px;
    font-size: 28px;
    cursor: pointer;
    color: var(--gray);
    background: none;
    border: none;
    line-height: 1;
    transition: var(--transition);
}

.modal-box .close-btn:hover {
    color: var(--dark);
}

.modal-box #adminLoginError {
    color: #ef4444;
    margin-top: 12px;
    font-size: 14px;
    display: none;
}

#edgieModal .modal-box {
    max-height: 90vh;
    overflow-y: auto;
}

#memberLoginModal .modal-box {
    max-width: 420px;
}

#memberLoginModal .step2 {
    display: none;
}

#memberLoginModal .otp-input {
    letter-spacing: 8px;
    font-size: 24px;
}

/* ===== SHARE ===== */
.share-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin: 16px 0 20px 0;
}

.share-grid .share-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 8px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    background: var(--gray-bg);
    border: 1px solid var(--gray-light);
    text-decoration: none;
    color: var(--dark);
}

.share-grid .share-item:hover {
    transform: scale(1.05);
    border-color: var(--primary);
}

.share-grid .share-item i {
    font-size: 32px;
    margin-bottom: 6px;
}

.share-grid .share-item span {
    font-size: 12px;
    font-weight: 500;
}

.share-grid .share-item .fa-copy {
    color: var(--primary);
}
.share-grid .share-item .fa-facebook {
    color: #1877F2;
}
.share-grid .share-item .fa-x-twitter {
    color: #000;
}
.share-grid .share-item .fa-whatsapp {
    color: #25D366;
}

.share-grid .share-item.copy-success i {
    color: #16a34a;
}
.share-grid .share-item.copy-success span {
    color: #16a34a;
}

.share-text-preview {
    background: var(--gray-bg);
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    font-size: 15px;
    color: var(--dark);
    text-align: left;
    max-height: 280px;
    overflow-y: auto;
    border: 1px solid var(--gray-light);
    margin-bottom: 16px;
    white-space: pre-wrap;
    line-height: 1.7;
    font-family: inherit;
}

/* ===== SLOT FILTER / SPONSORED ===== */
.slot-filter-area {
    margin-top: 5px;
}

.slot-filter-area .filter-input {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    align-items: center;
}

.slot-filter-area .filter-input input {
    width: 200px;
    padding: 10px 14px;
    border: 2px solid #ffb59a;
    border-radius: var(--radius-sm);
    font-size: 16px;
    font-family: inherit;
    text-align: center;
}

.slot-filter-area .filter-input input:focus {
    outline: none;
    border-color: var(--primary);
}

.slot-filter-area .filter-input button {
    padding: 14px 20px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    white-space: nowrap;
}

.slot-filter-area .filter-input button:hover {
    background: var(--primary-dark);
}

.slot-filter-results {
    background: var(--gray-bg);
    min-height: 30px;
    cursor: default;
}

.sponsored-area {
    margin-top: 5px;
}

.sponsored-area .filter-input {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    align-items: center;
}

.sponsored-area .filter-input input {
    width: 200px;
    padding: 10px 14px;
    border: 2px solid #ffb59a;
    border-radius: var(--radius-sm);
    font-size: 16px;
    font-family: inherit;
    text-align: center;
}

.sponsored-area .filter-input input:focus {
    outline: none;
    border-color: var(--primary);
}

.sponsored-area .filter-input button {
    padding: 14px 20px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    white-space: nowrap;
}

.sponsored-area .filter-input button:hover {
    background: var(--primary-dark);
}

.sponsored-results {
    background: var(--gray-bg);
    min-height: 30px;
}

/* ===== SLOT TRIANGLE ===== */
.slot-triangle {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 8px 0;
}

.slot-triangle .top-row {
    display: flex;
    justify-content: center;
    min-width: 100%;
}

.slot-triangle .bottom-row {
    display: flex;
    gap: 10px;
    width: 100%;
    max-width: 400px;
    justify-content: space-between;
}

.slot-triangle .person {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: pointer;
    padding: 8px 0px;
    border-radius: 12px;
    transition: all 0.2s ease;
    user-select: none;
    min-width: 140px;
}

.slot-triangle .person:hover {
    /* background: rgba(255, 107, 53, 0.08); */
    transform: scale(1.02);
}

.slot-triangle .person:active {
    transform: scale(0.95);
}

.slot-triangle .person .person-icon {
    font-size: 32px;
    line-height: 1;
    margin-bottom: 4px;
    color: #22c55e;
}

.slot-triangle .person .person-icon i {
    font-weight: 900 !important;
	font-size: 39px;
}

.slot-triangle .person .person-icon.empty {
    color: #a0aec0;
}

.slot-triangle .person .name {
    font-size: 16px;
    font-weight: 700;
    color: var(--dark);
    letter-spacing: 0.3px;
    line-height: 1.2;
}

.slot-triangle .person .name.empty {
    color: var(--gray);
    font-style: italic;
    font-weight: 400;
    font-size: 16px;
}

.slot-triangle .person .slot {
    font-size: 14px;
    color: var(--gray);
    margin-top: 2px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.slot-triangle .person .slot.empty {
    color: #b0b8c4;
}

.slot-triangle .person.main-person .name {
    color: var(--primary);
    font-size: 22px;
}

.slot-triangle .person.main-person .slot {
    color: var(--primary-dark);
}

.slot-triangle .person.main-person .person-icon {
    color: var(--primary);
}

/* Click hint */
.slot-triangle .person .click-hint {
    font-size: 10px;
    color: var(--gray);
    opacity: 0.5;
    margin-top: 4px;
    font-weight: 400;
}

.slot-triangle .person:hover .click-hint {
    opacity: 0.8;
}

.slot-filter-results .message-box {
    margin-top: 16px;
    padding: 14px 16px;
    background: rgba(78, 205, 196, 0.08);
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--secondary);
    font-size: 16px;
    color: var(--dark-light);
    line-height: 1.4;
}

.slot-filter-results .message-box.complete {
    background: rgba(255, 107, 53, 0.08);
    border-left-color: var(--primary);
}

.slot-filter-results .count-highlight {
    color: var(--primary);
    font-weight: 700;
}

.sponsored-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 0;
    border-bottom: 1px solid var(--gray-light);
}

.sponsored-item:last-child {
    border-bottom: none;
}

.sponsored-item .sp-slot {
    font-weight: 600;
    color: var(--primary);
    min-width: 60px;
}

.sponsored-item .sp-name {
    font-weight: 500;
}

/* ===== EDITABLE (ADMIN) ===== */
.editable-sponsor {
    cursor: pointer;
    /* padding: 4px 8px; */
    border-radius: 4px;
    transition: background 0.2s;
    display: inline-block;
    min-width: 80px;
}

.editable-sponsor:hover {
    background: rgba(78, 205, 196, 0.12);
}

.editable-sponsor .sponsor-edit-input {
    border: 2px solid var(--primary);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 14px;
    width: 80px;
    font-family: monospace;
    background: white;
    color: var(--dark);
    outline: none;
}

.editable-sponsor .sponsor-edit-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.15);
}

.editable-sponsor .sponsor-display {
    font-weight: 500;
}

.editable-sponsor .sponsor-display.empty {
    color: var(--gray);
    font-style: italic;
}

.editable-sponsor .sponsor-display .sponsor-name-display {
    color: var(--dark);
    font-weight: 400;
	font-size: small;
}

.editable-slot {
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.2s;
    display: inline-block;
    min-width: 80px;
}

.editable-slot:hover {
    background: rgba(78, 205, 196, 0.12);
}

.editable-slot .slot-edit-input {
    border: 2px solid var(--primary);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 14px;
    width: 70px;
    font-family: monospace;
    background: white;
    color: var(--dark);
    outline: none;
}

.editable-slot .slot-edit-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.15);
}

.editable-slot .slot-display {
    font-weight: 600;
    font-family: monospace;
}

/* ===== TEST EMAIL ===== */
.test-email-btn {
    background: var(--secondary);
    color: var(--white);
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
}

.test-email-btn:hover {
    background: var(--secondary-dark);
}

/* ===== MATRIX ===== */
.matrix-text {
    font-family: 'Courier New', monospace;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.8;
    background: #f8fafc;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow-x: auto;
    white-space: pre;
    color: #1a2634;
}

.tree-node,
.tree-node * {
    text-align: center !important;
}

/* ===== FOOTER ===== */
.app-footer {
    background: var(--dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 20px 40px;
    text-align: center;
    font-size: 14px;
    border-top: 2px solid var(--primary);
    margin-top: auto;
}

.app-footer a {
    color: var(--primary);
    text-decoration: none;
    cursor: pointer;
}

.app-footer a:hover {
    text-decoration: underline;
}

/* ============================================================
   RESPONSIVE (GENERAL)
   ============================================================ */
@media (max-width: 820px) {
    body {
        padding: 0;
        align-items: flex-start;
    }
    .app {
        border-radius: 0;
        box-shadow: none;
        min-height: 100vh;
        height: auto !important;
        max-height: none !important;
        overflow-y: visible !important;
    }
    .register-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .tabs {
        padding: 0 8px;
    }
    .tab-btn {
        padding: 10px 12px;
        font-size: 16px;
    }
    .tab-btn span.tab-label {
        display: none;
    }
    .tab-content {
        padding: 16px;
    }
    .notif-grid {
        grid-template-columns: 1fr;
    }
    .app-footer {
        padding: 16px 20px;
        font-size: 12px;
    }
    .slots-header .actions {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
    }
    .slots-header .actions .slots-search {
        flex: 1 1 auto;
        width: 100%;
    }
    .slots-header .actions .slots-search input {
        width: 100%;
        min-width: unset;
    }
    .slots-header .actions #exportCsvBtn {
        width: 100%;
    }
    .table-wrap table th:nth-child(1),
    .table-wrap table td:nth-child(1) {
        width: 15%;
    }
    .table-wrap table th:nth-child(2),
    .table-wrap table td:nth-child(2) {
        width: 25%;
    }
    .table-wrap table th:nth-child(3),
    .table-wrap table td:nth-child(3) {
        width: 15%;
    }
    .table-wrap table th:nth-child(4),
    .table-wrap table td:nth-child(4) {
        width: 40%;
    }
    .table-wrap table th:nth-child(5),
    .table-wrap table td:nth-child(5) {
        width: 5%;
    }
}

@media (max-width: 600px) {
    .slot-triangle .bottom-row {
        gap: 8px;
    }
    .slot-triangle .person .name {
        font-size: 16px;
    }
    .slot-triangle .person.main-person .name {
        font-size: 20px;
    }
    .slot-triangle .person .person-icon {
        font-size: 28px;
    }
    .share-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .slot-filter-area .filter-input input,
    .sponsored-area .filter-input input {
        width: 100%;
    }
    .modal-box {
        padding: 24px 20px 20px;
    }
}

/* ============================================================
   FONT-WEIGHT FIX — SIGURADONG NORMAL ANG MGA TEXT NA ITO
   ============================================================ */
.slot-filter-results,
.slot-filter-results *,
.sponsored-results,
.sponsored-results * {
    font-weight: normal !important;
}

.slot-filter-area .filter-input button,
.sponsored-area .filter-input button,
.slot-filter-area h4,
.sponsored-area h4 {
    font-weight: 600 !important;
}

.app-footer {
  font-weight: normal;
}

.editable-name {
    cursor: pointer;
    /* padding: 4px 8px; */
	font-weight: 600;
    border-radius: 4px;
    transition: background 0.2s;
    display: inline-block;
    min-width: 60px;
}

.editable-registered {
    cursor: pointer;
    /* padding: 4px 8px; */
	font-size: small;
    border-radius: 4px;
    transition: background 0.2s;
    display: inline-block;
    min-width: 60px;
}

.editable-name:hover,
.editable-registered:hover {
    background: rgba(78, 205, 196, 0.12);
}

.editable-email {
    cursor: pointer;
   /* padding: 2px 4px; */
    border-radius: 4px;
    transition: background 0.2s;
    display: inline-block;
}
.editable-email:hover {
    background: rgba(78, 205, 196, 0.12);
}

/* Para maging normal ang font-weight ng lahat ng table data */
.table-wrap table td {
    font-weight: normal !important;
}

/* I-preserve ang bold ng slot number */
.table-wrap table td .slot-display {
    font-weight: 600 !important;
}

/* Para maging normal ang font-weight ng notifications */
.notif-log .log-item,
.notif-log .log-item *:not(.log-title):not(.log-title *) {
    font-weight: normal !important;
}

.notif-log .log-title {
    font-weight: 600 !important;
}

/* Fix: Normal font-weight for notifications & emailer */
.notif-log .log-item *:not(.log-title),
.notif-grid > div:last-child *:not(h3):not(label):not(.btn):not(strong) {
    font-weight: normal !important;
}

/* Fix: Normal font-weight for matrix nav */
#matrixNavInfo *:not(.btn) {
    font-weight: normal !important;
}

/* Fix: Normal font-weight for matrix total text */
#tab-p4 > div:first-child > div > span,
#tab-p4 > div:first-child > div > span strong {
    font-weight: normal !important;
}


@keyframes fadeSlide {
    from { opacity: 0; transform: translateY(12px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.recent-item {
    animation: fadeSlide 0.5s ease forwards;
    opacity: 0;
}


#socialProofAvatars {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.recent-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--white);
    padding: 4px 12px 4px 4px;
    border-radius: 30px;
    border: 1px solid var(--gray-light);
    animation: fadeSlide 0.5s ease forwards;
    opacity: 0;
    transition: all 0.2s ease;
}

.recent-item:hover {
    transform: scale(1.02);
    border-color: var(--primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

@keyframes fadeSlide {
    from { opacity: 0; transform: translateY(10px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Member Activity Popup */
#memberActivityContainer {
    position: fixed;
    bottom: 24px;
    left: 24px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 320px;
    pointer-events: none;
}

.member-activity-toast {
    background: var(--white);
    border-radius: var(--radius-sm);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    padding: 10px 10px 10px 8px;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: slideUp 0.4s ease;
    border-left: 4px solid var(--primary);
    pointer-events: auto;
    transition: all 0.2s;
}

.member-activity-toast:hover {
    transform: scale(1.02);
    box-shadow: 0 12px 32px rgba(0,0,0,0.18);
}

.member-activity-toast .avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    flex-shrink: 0;
}

.member-activity-toast .info {
    flex: 1;
    font-size: 14px;
    line-height: 1.3;
}

.member-activity-toast .info .name {
    font-weight: 600;
    color: var(--dark);
}

.member-activity-toast .info .tb {
    font-size: 12px;
    color: var(--primary);
    font-weight: 600;
}

.member-activity-toast .info .time {
    font-size: 11px;
    color: var(--gray);
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.member-activity-toast.removing {
    animation: fadeOut 0.3s ease forwards;
}

@keyframes fadeOut {
    to { opacity: 0; transform: translateY(-10px); }
}

/* ===== DESKTOP FIX ===== */
@media (min-width: 821px) {
    body {
        align-items: flex-start !important;
    }
    .app {
        height: auto !important;
        max-height: none !important;
        overflow-y: visible !important;
        min-height: 100vh;
    }
}

/* ============================================================
   VIDEO CONTAINER RESPONSIVE (same as vault)
   ============================================================ */
/* Default: 4:3 with padding-bottom */
.video-container-why {
    position: relative;
    width: 100%;
    padding-bottom: 75%; /* 4:3 */
    background: #000;
    border-radius: 8px;
    overflow: hidden;
    margin: 0 0 18px 0;
}
.video-container-why video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

/* Landscape override for phones (max-width: 767px) */
@media (max-width: 767px) and (orientation: landscape) {
    .video-container-why {
        padding-bottom: 0 !important;          /* remove padding-bottom */
        aspect-ratio: 4 / 3;                  /* maintain 4:3 */
        max-height: 80vh;                     /* limit height to fit screen */
        width: 100%;
        margin: 0 auto 18px auto;
        background: #000;
        border-radius: 8px;
        overflow: hidden;
    }
    .video-container-why video {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: contain;
        background: #000;
    }
}

/* Disabled state for Community button */
.disabled-btn {
    opacity: 0.5;
    cursor: not-allowed;
}
.disabled-btn:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    transform: none !important;
    box-shadow: none !important;
}


/* Default (desktop) styles */
#videoTitle {
    padding: 8px 15px;
    border-radius: 5px;
}
#titleName {
    font-size: 24px;
    font-weight: bold;
    line-height: 1.1;
}
#titleSub {
    font-size: 15px;
    color: #ddd;
}

/* Mobile responsive */
@media (max-width: 768px) {
    #videoTitle {
        bottom: 35px;          /* Itaas ng konti para hindi matakpan controls */
        right: 8px;
        padding: 4px 8px;      /* Mas maliit na padding */
        border-radius: 4px;
        background: rgba(0,0,0,0.5); /* Mas transparent para hindi masyadong pansin */
    }
    #titleName {
        font-size: 12px;       /* Mas maliit */
        line-height: 1.2;
    }
    #titleSub {
        font-size: 10px;        /* Mas maliit */
    }
}

/* Para sa sobrang liit na phone (optional) */
@media (max-width: 480px) {
    #titleName {
        font-size: 11px;
    }
    #titleSub {
        font-size: 9px;
    }
    #videoTitle {
        padding: 3px 6px;
        bottom: 30px;
        right: 5px;
    }
}

.why-content .divider {
    margin-bottom: 8px !important;
}

/* ===== UNMUTE BUTTON OVERLAY ===== */
.unmute-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.6);
    color: #ffffff;
    width: 125px;               /* Desktop default — mas proportional sa video */
    height: 125px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 20;
    transition: all 0.3s ease;
    border: 5px solid #ffffff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
    animation: pulseAudio 2s infinite;
}

.unmute-overlay i {
    font-size: 62px;            /* Desktop icon */
    color: #ffffff;
    margin-left: -5px;
}

.unmute-overlay:hover {
    background: var(--primary);
    border-color: var(--primary);
    transform: translate(-50%, -50%) scale(1.1);
}

/* Pulse animation */
@keyframes pulseAudio {
    0%   { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0.7); }
    70%  { box-shadow: 0 0 0 18px rgba(255, 107, 53, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0); }
}

/* ─── Tablet (601px – 820px) ─── */
@media (max-width: 820px) {
    .unmute-overlay {
        width: 95px;
        height: 95px;
        border-width: 4px;
    }
    .unmute-overlay i {
        font-size: 42px;
        margin-left: -4px;
    }
    @keyframes pulseAudio {
        0%   { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0.7); }
        70%  { box-shadow: 0 0 0 14px rgba(255, 107, 53, 0); }
        100% { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0); }
    }
}

/* ─── Phone (≤600px) ─── */
@media (max-width: 600px) {
    .unmute-overlay {
        width: 60px;
        height: 60px;
        border-width: 3px;
    }
    .unmute-overlay i {
        font-size: 27px;
        margin-left: -3px;
    }
    @keyframes pulseAudio {
        0%   { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0.7); }
        70%  { box-shadow: 0 0 0 8px rgba(255, 107, 53, 0); }
        100% { box-shadow: 0 0 0 0 rgba(255, 107, 53, 0); }
    }
}

/* ─── Maliit na phone (≤380px) ─── */
@media (max-width: 380px) {
    .unmute-overlay {
        width: 50px;
        height: 50px;
        border-width: 2.5px;
    }
    .unmute-overlay i {
        font-size: 22px;
        margin-left: -2px;
    }
}

#calcResult {
    transition: all 0.3s ease;
}
#calcTotalEarning {
    transition: color 0.3s ease, transform 0.3s ease;
}
#calcTotalEarning.pulse {
    transform: scale(1.08);
}

