/* Cute Baby Name Generator - Table Layout with Search */
.cbng-container {
    max-width: 1100px;
    margin: 2rem auto;
    padding: 2.5rem 2rem 2rem;
    background: #fff;
    border-radius: 36px;
    box-shadow: 0 20px 35px -8px rgba(0,0,0,0.05), 0 8px 18px -6px rgba(0,0,0,0.02);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    text-align: center;
}

.cbng-header { margin-bottom: 2.5rem; }
.cbng-badge {
    display: inline-block;
    background: #fff7ed;
    color: #ea580c;
    font-weight: 600;
    font-size: 0.7rem;
    padding: 0.3rem 1rem;
    border-radius: 30px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-bottom: 1rem;
    border: 1px solid #fed7aa;
}
.cbng-header h2 {
    font-size: 2.3rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    color: #1e1b4b;
}
.cbng-subtitle {
    font-size: 1rem;
    color: #6b7280;
    max-width: 500px;
    margin: 0 auto;
}

.cbng-form { text-align: left; margin-bottom: 2rem; }
.cbng-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 0;
}
.cbng-field label {
    font-weight: 600;
    color: #374151;
    font-size: 0.9rem;
}
.cbng-field label span { font-weight: 400; color: #9ca3af; margin-left: 3px; }
.cbng-field input,
.cbng-field select {
    padding: 0.9rem 1rem;
    border: 1.5px solid #e5e7eb;
    border-radius: 16px;
    font-size: 0.95rem;
    background: #fafbfc;
    width: 100%;
    box-sizing: border-box;
    height: 48px;
    font-family: inherit;
}
.cbng-field input:focus,
.cbng-field select:focus {
    outline: none;
    border-color: #f97316;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(249,115,22,0.1);
}

.cbng-row {
    display: flex;
    gap: 1.2rem;
    flex-wrap: wrap;
}
.cbng-row.two-col { margin-bottom: 1.8rem; }
.cbng-row.three-col { margin-bottom: 2.2rem; }
.cbng-row.two-col .cbng-field { flex: 1; min-width: 200px; }
.cbng-row.three-col .cbng-field { flex: 1; min-width: 150px; }

.cbng-actions { text-align: center; }
.cbng-btn {
    padding: 1.1rem 3.5rem;
    border: none;
    border-radius: 60px;
    font-weight: 700;
    font-size: 1.2rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #e5e7eb;
    height: 58px;
    min-width: 280px;
    transition: all 0.25s;
}
.cbng-btn-primary {
    background: #f97316;
    color: #fff;
    border: none;
    box-shadow: 0 10px 22px -8px rgba(249,115,22,0.35);
}
.cbng-btn-primary:hover {
    background: #ea580c;
    transform: translateY(-2px);
    box-shadow: 0 14px 26px -10px rgba(249,115,22,0.45);
}
.cbng-btn-primary:disabled {
    opacity: 0.7;
    transform: none;
    box-shadow: none;
    cursor: not-allowed;
}

.cbng-spinner {
    width: 22px;
    height: 22px;
    border: 3px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: cbng-spin 0.8s linear infinite;
    display: inline-block;
}
@keyframes cbng-spin { to { transform: rotate(360deg); } }

.cbng-message {
    padding: 0.9rem 1.2rem;
    border-radius: 16px;
    margin: 1.5rem 0;
    font-weight: 500;
    text-align: left;
}
.cbng-message.error { background: #fee2e2; color: #b91c1c; border-left: 4px solid #ef4444; }
.cbng-message.success { background: #dcfce7; color: #166534; border-left: 4px solid #22c55e; }

/* Results Table */
.cbng-results { margin-top: 2.5rem; text-align: left; }
.cbng-results h3 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #1e1b4b;
    margin-bottom: 1.5rem;
}
.cbng-table-wrapper {
    overflow-x: auto;
    border-radius: 20px;
    border: 1px solid #ede9fe;
}
.cbng-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    min-width: 800px;
}
.cbng-table th {
    background: #faf9fe;
    padding: 1rem 0.8rem;
    font-weight: 600;
    color: #374151;
    border-bottom: 1px solid #e5e7eb;
    white-space: nowrap;
}
.cbng-table td {
    padding: 1rem 0.8rem;
    border-bottom: 1px solid #f3f4f6;
    color: #1f2937;
}
.cbng-table tbody tr:last-child td { border-bottom: none; }
.cbng-table tbody tr:hover { background: #fffaf5; }

/* Bottom Navigation */
.cbng-bottom-nav {
    margin-top: 2.8rem;
    padding-top: 1.8rem;
    border-top: 1px solid #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    font-size: 0.9rem;
    color: #6b7280;
}
.cbng-nav-item { cursor: default; font-weight: 500; }
.cbng-nav-item.active { color: #f97316; font-weight: 600; }
.cbng-nav-separator { color: #d1d5db; font-size: 1.2rem; }

/* Search */
.cbng-search-wrapper {
    margin-top: 1.5rem;
    display: flex;
    justify-content: center;
}
.cbng-search-input {
    width: 100%;
    max-width: 400px;
    padding: 0.9rem 1.2rem;
    border: 1.5px solid #e5e7eb;
    border-radius: 40px;
    font-size: 0.95rem;
    background: #fafbfc;
}
.cbng-search-input:focus {
    outline: none;
    border-color: #f97316;
    box-shadow: 0 0 0 3px rgba(249,115,22,0.1);
}

@media (max-width: 700px) {
    .cbng-container { padding: 1.8rem 1rem; }
    .cbng-header h2 { font-size: 1.9rem; }
    .cbng-row { flex-direction: column; }
    .cbng-btn { width: 100%; min-width: unset; }
    .cbng-table { min-width: 700px; }
}