:root {
            --primary-color: #2c7da0;
            --secondary-color: #a9d6e5;
            --accent-color: #01497c;
            --light-gray: #f8f9fa;
            --border-color: #eaeaea;
            --text-color: #333;
            --text-muted: #6c757d;
            --success-color: #28a745;
            --warning-color: #ffc107;
            --math-color: #6f42c1;
            --calc-color: #e83e8c;
            --geometry-color: #20c997;
            --intersection-color: #fd7e14;
        }
        .page-header {
            background: linear-gradient(135deg, rgba(32, 201, 151, 0.4) 0%, rgba(44, 125, 160, 0.4) 100%);
            padding: 1.5rem 0;
            margin-bottom: 2rem;
            border-bottom: 1px solid rgba(44, 125, 160, 0.2);
            position: relative;
            overflow: hidden;
        }
        .breadcrumb {
            background-color: transparent;
            padding: 0.5rem 0;
            margin-bottom: 0.5rem;
        }
        .breadcrumb-item a {
            color: var(--text-muted);
            text-decoration: none;
        }
        .breadcrumb-item.active {
            color: var(--text-color);
        }
        .form-control:focus {
            border-color: var(--primary-color);
            box-shadow: 0 0 0 3px rgba(44, 125, 160, 0.15);
        }
        .math-input {
            font-family: 'Cambria Math', 'Latin Modern Math', STIXGeneral, serif;
            font-size: 1.1rem;
        }
        .input-mode-selector {
            display: flex;
            border-radius: 6px;
            overflow: hidden;
            margin-bottom: 1.5rem;
            border: 1px solid var(--border-color);
        }
        .mode-btn {
            flex: 1;
            padding: 0.75rem;
            background-color: white;
            border: none;
            text-align: center;
            font-weight: 600;
            color: var(--text-muted);
            transition: all 0.3s;
        }
        .mode-btn:hover {
            background-color: var(--light-gray);
        }
        .mode-btn.active {
            background-color: var(--primary-color);
            color: white;
        }
        .coordinate-inputs {
            display: flex;
            gap: 1rem;
            margin-bottom: 1rem;
            align-items: center;
        }
        .coordinate-label {
            width: 30px;
            font-weight: 600;
            color: var(--math-color);
        }
        .coordinate-input {
            flex: 1;
        }
        .point-container {
            background-color: rgba(32, 201, 151, 0.05);
            border-radius: 6px;
            padding: 1.25rem;
            margin-bottom: 1.5rem;
            border-left: 3px solid var(--geometry-color);
        }
        .point-title {
            font-weight: 600;
            margin-bottom: 0.75rem;
            color: var(--geometry-color);
        }
        .math-result {
            padding: 12px;
            background-color: white;
            border-radius: 4px;
            border: 1px solid #eee;
            font-size: 1.1rem;
            font-family: 'Cambria Math', 'Latin Modern Math', STIXGeneral, serif;
            margin: 10px 0;
            text-align: center;
        }
        .math-equation {
            font-size: 1.3rem;
            padding: 15px;
            background-color: rgba(111, 66, 193, 0.05);
            border-left: 4px solid var(--math-color);
            border-radius: 4px;
            margin: 15px 0;
        }
        .visualization-container {
            position: relative;
            height: 400px;
            width: 100%;
            margin: 2rem 0;
            border-radius: 6px;
            overflow: hidden;
            border: 1px solid var(--border-color);
        }
        #planeCanvas {
            width: 100%;
            height: 100%;
        }
        .canvas-controls {
            position: absolute;
            bottom: 10px;
            right: 10px;
            display: flex;
            gap: 5px;
            z-index: 10;
        }
        .canvas-btn {
            width: 36px;
            height: 36px;
            border-radius: 50%;
            background-color: rgba(255, 255, 255, 0.8);
            border: 1px solid var(--border-color);
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.2s;
        }
        .canvas-btn:hover {
            background-color: white;
            transform: scale(1.1);
        }
        .performance-warning {
            display: none;
            background-color: rgba(255, 193, 7, 0.1);
            border-left: 3px solid var(--warning-color);
            padding: 0.75rem;
            margin: 1rem 0;
            border-radius: 0 4px 4px 0;
        }
        .enhanced-features {
            border-top: 1px solid var(--border-color);
            margin-top: 2rem;
            padding-top: 2rem;
        }
        .feature-toggle {
            display: flex;
            align-items: center;
            margin-bottom: 1rem;
            padding: 0.75rem;
            background-color: rgba(44, 125, 160, 0.05);
            border-radius: 6px;
            cursor: pointer;
        }
        .feature-toggle input {
            margin-right: 10px;
        }
        .feature-content {
            display: none;
            margin-top: 1rem;
            padding: 1.5rem;
            background-color: rgba(253, 126, 20, 0.05);
            border-radius: 6px;
            border-left: 3px solid var(--intersection-color);
        }
        .intersection-result {
            padding: 12px;
            background-color: rgba(253, 126, 20, 0.1);
            border-left: 3px solid var(--intersection-color);
            border-radius: 0 4px 4px 0;
            margin: 10px 0;
        }
        .distance-input {
            background-color: rgba(108, 117, 125, 0.05);
            border-radius: 6px;
            padding: 1.25rem;
            margin-bottom: 1.5rem;
        }
        .history-panel {
            max-height: 300px;
            overflow-y: auto;
            margin-top: 1rem;
        }
        .history-item {
            padding: 0.75rem;
            border-bottom: 1px solid var(--border-color);
            cursor: pointer;
            transition: background-color 0.2s;
        }
        .history-item:hover {
            background-color: rgba(44, 125, 160, 0.05);
        }
        .history-item:last-child {
            border-bottom: none;
        }
        .history-title {
            font-weight: 600;
            margin-bottom: 0.25rem;
        }
        .history-equation {
            font-family: 'Courier New', monospace;
            font-size: 0.9rem;
            color: var(--text-muted);
        }
        .export-buttons {
            display: flex;
            gap: 0.5rem;
            margin-top: 1rem;
        }
        .math-box {
            background-color: rgba(111, 66, 193, 0.05);
            border-left: 3px solid var(--math-color);
            padding: 1rem;
            border-radius: 0 4px 4px 0;
            margin: 1.5rem 0;
        }
        .geometry-box {
            background-color: rgba(32, 201, 151, 0.05);
            border-left: 3px solid var(--geometry-color);
            padding: 1rem;
            border-radius: 0 4px 4px 0;
            margin: 1.5rem 0;
        }
        @media (max-width: 768px) {
            .coordinate-inputs {
                flex-direction: column;
                gap: 0.5rem;
            }
            .coordinate-label {
                width: auto;
            }
            .performance-warning {
                display: block;
            }
            .visualization-container {
                height: 300px;
            }
        }
        .preset-examples {
            display: flex;
            flex-wrap: wrap;
            gap: 0.5rem;
            margin: 1rem 0;
        }
        .example-btn {
            background-color: rgba(44, 125, 160, 0.1);
            border: 1px solid rgba(44, 125, 160, 0.2);
            border-radius: 4px;
            padding: 0.5rem 0.75rem;
            font-size: 0.9rem;
            color: var(--primary-color);
            cursor: pointer;
            transition: all 0.2s;
            font-family: 'Courier New', monospace;
        }
        .example-btn:hover {
            background-color: rgba(44, 125, 160, 0.2);
            transform: translateY(-2px);
        }
        .math-notation {
            font-family: 'Cambria Math', 'Latin Modern Math', STIXGeneral, serif;
            font-size: 1.1rem;
        }
        .calculation-step {
            margin-bottom: 1.5rem;
            padding-bottom: 1.5rem;
            border-bottom: 1px dashed var(--border-color);
        }
        .vector-table {
            width: 100%;
            border-collapse: collapse;
            margin: 1.5rem 0;
        }
        .vector-table th, .vector-table td {
            padding: 0.75rem;
            text-align: center;
            border: 1px solid var(--border-color);
        }
        .vector-table th {
            background-color: var(--light-gray);
            font-weight: 600;
        }
        .vector-table tr:nth-child(even) {
            background-color: rgba(44, 125, 160, 0.05);
        }
        .point-display {
            display: flex;
            align-items: center;
            margin: 1rem 0;
            padding: 1rem;
            background-color: rgba(255,255,255,0.8);
            border-radius: 6px;
            border: 1px solid var(--border-color);
        }
        .point-coordinate {
            font-family: 'Courier New', monospace;
            background-color: rgba(32, 201, 151, 0.1);
            padding: 0.5rem;
            border-radius: 4px;
            margin: 0 0.5rem;
        }
        .point-label {
            font-weight: 600;
            margin-right: 0.5rem;
        }
        .graph-legend {
            display: flex;
            justify-content: center;
            flex-wrap: wrap;
            gap: 1.5rem;
            margin-top: 1rem;
        }
        .legend-item {
            display: flex;
            align-items: center;
        }
        .legend-color {
            width: 20px;
            height: 4px;
            margin-right: 0.5rem;
        }
        .plane-color {
            background-color: rgba(44, 125, 160, 0.6);
        }
        .normal-color {
            background-color: rgba(232, 62, 140, 0.8);
        }
        .intersection-color {
            background-color: rgba(253, 126, 20, 0.8);
        }
        .point-marker {
            width: 10px;
            height: 10px;
            border-radius: 50%;
            margin-right: 0.5rem;
        }
        .p1-color {
            background-color: rgba(220, 53, 69, 0.8);
        }
        .p2-color {
            background-color: rgba(255, 193, 7, 0.8);
        }
        .p3-color {
            background-color: rgba(25, 135, 84, 0.8);
        }
        .ad-placeholder {
            padding: 2rem;
            background-color: white;
            border-radius: 4px;
            border: 1px solid var(--border-color);
        }
        .input-mode-content {
            display: none;
        }
        .input-mode-content.active {
            display: block;
        }
        .interactive-formula {
            cursor: pointer;
            border-bottom: 1px dashed var(--math-color);
        }
        .formula-explanation {
            display: none;
            padding: 1rem;
            background-color: rgba(32, 201, 151, 0.05);
            border-radius: 6px;
            margin-top: 0.5rem;
        }
        .is-valid {
            border-color: var(--success-color) !important;
        }
        .is-invalid {
            border-color: var(--warning-color) !important;
        }
        .validation-feedback {
            display: none;
            font-size: 0.875rem;
            margin-top: 0.25rem;
        }
        .is-valid + .validation-feedback {
            display: none;
            color: var(--success-color);
        }
        .is-invalid + .validation-feedback {
            display: block;
            color: var(--warning-color);
        }
        .unit-toggle {
            display: flex;
            align-items: center;
            margin-bottom: 1rem;
            gap: 0.5rem;
        }
        .unit-btn {
            padding: 0.25rem 0.75rem;
            border: 1px solid var(--border-color);
            border-radius: 4px;
            background-color: white;
            cursor: pointer;
        }
        .unit-btn.active {
            background-color: var(--primary-color);
            color: white;
            border-color: var(--primary-color);
        }
        .additional-plane {
            background-color: rgba(253, 126, 20, 0.05);
            border-radius: 6px;
            padding: 1.5rem;
            margin-top: 1.5rem;
            border-left: 3px solid var(--intersection-color);
        }