/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #ff6b6b;
    --primary-dark: #ee5a5a;
    --secondary-color: #4ecdc4;
    --accent-color: #ffe66d;
    --bg-dark: #1a1a2e;
    --bg-card: #16213e;
    --bg-light: #0f3460;
    --text-primary: #eaeaea;
    --text-secondary: #a0a0a0;
    --success-color: #2ecc71;
    --warning-color: #f39c12;
    --info-color: #3498db;
    
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.4);
    --radius: 16px;
    --radius-sm: 8px;
    --transition: all 0.3s ease;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-card) 100%);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

/* App Container */
.app-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    margin-bottom: 30px;
    border-bottom: 2px solid var(--bg-light);
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo i {
    font-size: 2.5rem;
    color: var(--primary-color);
    animation: pulse 2s infinite;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* Navigation Tabs */
.nav-tabs {
    display: flex;
    gap: 10px;
    background: var(--bg-light);
    padding: 8px;
    border-radius: var(--radius);
}

.tab-btn {
    padding: 12px 24px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.tab-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: var(--shadow);
}

/* Main Content */
.main-content {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 30px;
    margin-bottom: 40px;
}

/* Body Section */
.body-section {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 30px;
    box-shadow: var(--shadow);
}

.view-title {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 25px;
    text-align: center;
    color: var(--secondary-color);
}

.body-diagram {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 500px;
}

.hands-diagram, .feet-diagram {
    min-height: 350px;
}

.body-svg {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.3));
}

/* Acupressure Points */
.acupoint {
    fill: var(--primary-color);
    stroke: white;
    stroke-width: 2;
    cursor: pointer;
    transition: var(--transition);
    animation: pointPulse 2s infinite;
}

.acupoint:hover {
    fill: var(--accent-color);
    stroke: var(--primary-dark);
    stroke-width: 3;
    r: 12;
    filter: drop-shadow(0 0 10px var(--primary-color));
}

.acupoint.active {
    fill: var(--accent-color);
    stroke: var(--primary-dark);
    stroke-width: 4;
    filter: drop-shadow(0 0 15px var(--accent-color));
}

@keyframes pointPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.point-label {
    font-size: 11px;
    fill: var(--text-secondary);
    font-weight: 500;
    pointer-events: none;
}

/* Info Panel */
.info-panel {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 30px;
    box-shadow: var(--shadow);
    height: fit-content;
    position: sticky;
    top: 20px;
}

.info-content {
    min-height: 400px;
}

.default-message {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.default-message i {
    font-size: 4rem;
    margin-bottom: 20px;
    color: var(--bg-light);
}

.default-message h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.default-message p {
    font-size: 0.95rem;
    line-height: 1.8;
}

/* Point Info Card */
.point-info-card {
    animation: slideIn 0.4s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.point-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--bg-light);
}

.point-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    box-shadow: var(--shadow);
}

.point-title h2 {
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.point-title span {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Benefits Section */
.benefits-section {
    margin-bottom: 25px;
}

.benefits-section h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.benefits-section h3 i {
    font-size: 1.1rem;
}

.benefits-list {
    list-style: none;
}

.benefits-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--bg-light);
}

.benefits-list li:last-child {
    border-bottom: none;
}

.benefits-list li i {
    color: var(--success-color);
    margin-top: 3px;
    font-size: 0.9rem;
}

.benefits-list li span {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Instructions Section */
.instructions-section {
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    padding: 20px;
    margin-bottom: 25px;
}

.instructions-section h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--accent-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.instructions-section ol {
    padding-left: 20px;
}

.instructions-section li {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 10px;
    line-height: 1.6;
}

/* Technique Section */
.technique-section {
    margin-bottom: 25px;
}

.technique-section h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--info-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.technique-box {
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.1), rgba(78, 205, 196, 0.05));
    border: 1px solid var(--secondary-color);
    border-radius: var(--radius-sm);
    padding: 20px;
}

.technique-box p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.technique-box strong {
    color: var(--secondary-color);
}

/* Duration Section */
.duration-section {
    display: flex;
    gap: 15px;
}

.duration-box {
    flex: 1;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    padding: 15px;
    text-align: center;
}

.duration-box i {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.duration-box .label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 5px;
}

.duration-box .value {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Quick Reference */
.quick-reference {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.quick-reference h2 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 25px;
    text-align: center;
    color: var(--text-primary);
}

.conditions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 15px;
}

.condition-card {
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: 2px solid transparent;
}

.condition-card:hover {
    background: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.condition-card.active {
    background: var(--primary-color);
    border-color: var(--accent-color);
}

.condition-card i {
    font-size: 2rem;
    margin-bottom: 10px;
    display: block;
}

.condition-card span {
    font-size: 0.9rem;
    font-weight: 500;
    display: block;
}

/* Footer */
.footer {
    text-align: center;
    padding: 20px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer i {
    color: var(--warning-color);
    margin-right: 8px;
}

/* Hidden Class */
.hidden {
    display: none !important;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .info-panel {
        position: static;
    }
    
    .header {
        flex-direction: column;
        gap: 20px;
    }
    
    .nav-tabs {
        flex-wrap: wrap;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .app-container {
        padding: 15px;
    }
    
    .logo h1 {
        font-size: 1.4rem;
    }
    
    .tab-btn {
        padding: 10px 16px;
        font-size: 0.85rem;
    }
    
    .body-section {
        padding: 20px;
    }
    
    .body-diagram {
        min-height: 400px;
    }
    
    .conditions-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .conditions-grid {
        grid-template-columns: 1fr;
    }
    
    .point-header {
        flex-direction: column;
        text-align: center;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.view-container:not(.hidden) {
    animation: fadeIn 0.5s ease;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-light);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Highlight Effect for Condition Search */
.point-highlight {
    animation: highlight 1s ease infinite alternate;
}

@keyframes highlight {
    from {
        fill: var(--primary-color);
        filter: drop-shadow(0 0 5px var(--primary-color));
    }
    to {
        fill: var(--accent-color);
        filter: drop-shadow(0 0 20px var(--accent-color));
    }
}