
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
        }
        
        body {
            background: linear-gradient(135deg, #f0f5ff, #e2e9ff);
            min-height: 100vh;
            padding: 20px;
            color: #1c2e4c;
        }
        
        header {
            text-align: center;
            padding: 35px 0;
            background: linear-gradient(135deg, #3a4fac, #1a2870);
            color: white;
            border-radius: 12px 12px 0 0;
            box-shadow: 0 8px 20px rgba(0, 30, 120, 0.25);
            margin-bottom: 30px;
        }
        
        h1 {
            font-size: 2.8rem;
            font-weight: 650;
            letter-spacing: 1.5px;
            text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.3);
            margin-bottom: 10px;
        }
        
        .subtitle {
            font-size: 1.15rem;
            font-weight: 350;
            opacity: 0.9;
            max-width: 650px;
            margin: 0 auto;
            line-height: 1.5;
        }
        
        .container {
            display: flex;
            max-width: 1300px;
            margin: 0 auto 30px;
            gap: 30px;
            flex-wrap: wrap;
        }
        
        .canvas-container {
            flex: 1;
            min-width: 500px;
            background-color: white;
            border-radius: 12px;
            box-shadow: 0 10px 30px rgba(0, 0, 100, 0.12);
            padding: 25px;
            position: relative;
            overflow: hidden;
        }
        
        #triangleCanvas {
            width: 100%;
            height: 500px;
            background-color: #fafcff;
            border: 1px solid #d0d8ff;
            border-radius: 8px;
            cursor: pointer;
            box-shadow: inset 0 0 20px rgba(58, 79, 172, 0.08);
        }
        
        .control-panel {
            width: 320px;
            background-color: white;
            border-radius: 12px;
            box-shadow: 0 10px 30px rgba(0, 0, 100, 0.12);
            padding: 25px;
            display: flex;
            flex-direction: column;
            gap: 25px;
        }
        
        .panel-section {
            padding-bottom: 20px;
            border-bottom: 1px solid #f0f3ff;
        }
        
        h2 {
            font-size: 1.65rem;
            color: #2c3a88;
            margin-bottom: 22px;
            font-weight: 600;
            position: relative;
            padding-left: 15px;
        }
        
        h2::before {
            content: "";
            position: absolute;
            left: 0;
            top: 5px;
            height: 80%;
            width: 5px;
            background: linear-gradient(to bottom, #4a67d0, #2c3a88);
            border-radius: 3px;
        }
        
        h3 {
            font-size: 1.3rem;
            margin-bottom: 16px;
            font-weight: 550;
            color: #38479b;
            padding-left: 10px;
            border-left: 4px solid #d0d8ff;
        }
        
        .btn-group {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            margin-top: 18px;
        }
        
        .btn {
            background-color: #eef1ff;
            color: #3a4fac;
            border: none;
            padding: 13px 22px;
            border-radius: 8px;
            cursor: pointer;
            font-weight: 510;
            font-size: 1.05rem;
            transition: all 0.25s ease;
            box-shadow: 0 3px 8px rgba(58, 79, 172, 0.1);
            flex: 1;
            min-width: 100px;
            text-align: center;
        }
        
        .btn:hover {
            background-color: #e0e5ff;
            transform: translateY(-2px);
            box-shadow: 0 6px 15px rgba(58, 79, 172, 0.18);
        }
        
        .btn.active {
            background: linear-gradient(to right, #3a4fac, #4a5fd0);
            color: white;
            box-shadow: 0 5px 12px rgba(58, 79, 172, 0.3);
        }
        
        .instructions {
            line-height: 1.65;
            color: #4452a0;
            font-size: 1.05rem;
        }
        
        .instructions ul {
            margin: 15px 0 15px 28px;
        }
        
        .instructions li {
            margin-bottom: 12px;
            position: relative;
            padding-left: 22px;
        }
        
        .instructions li::before {
            content: "•";
            color: #3a4fac;
            font-size: 1.5rem;
            position: absolute;
            left: 0;
            top: -5px;
        }
        
        footer {
            text-align: center;
            padding: 25px 0;
            background: linear-gradient(135deg, #1c2457, #121a47);
            color: rgba(255, 255, 255, 0.95);
            border-radius: 0 0 12px 12px;
            box-shadow: 0 8px 20px rgba(0, 15, 70, 0.25);
            font-size: 1.05rem;
        }
        
        .footer-content {
            max-width: 800px;
            margin: 0 auto;
            letter-spacing: 0.5px;
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 20px;
            flex-wrap: wrap;
        }
        
        .formula {
            background-color: #f5f7ff;
            padding: 15px;
            border-radius: 8px;
            font-size: 1.2rem;
            text-align: center;
            margin: 18px 0;
            border: 1px solid #e0e7ff;
            position: relative;
            overflow: hidden;
        }
        
        .dimension {
            font-weight: 550;
            color: #3a4fac;
            font-size: 1.45rem;
            letter-spacing: 1px;
        }
        
        .highlight {
            background: linear-gradient(to right, #eef1ff, #e0e5ff);
            padding: 4px 10px;
            border-radius: 6px;
            color: #3a4fac;
            font-weight: 520;
            border: 1px solid #d0d8ff;
        }
        
        .symbol {
            font-weight: bold;
            color: #d32f2f;
            font-size: 1.1em;
        }
        
        .vertex-controls {
            display: flex;
            justify-content: space-between;
            margin-top: 15px;
        }
        
        .vertex-btn {
            padding: 10px 15px;
            background: #eef1ff;
            border: 2px solid #d0d8ff;
            border-radius: 8px;
            cursor: pointer;
            font-weight: 500;
            color: #3a4fac;
            transition: all 0.2s;
        }
        
        .vertex-btn:hover {
            background: #e0e5ff;
        }
        
        .vertex-btn.active {
            background: linear-gradient(to bottom, #3a4fac, #4a5fd0);
            color: white;
            border-color: #3a4fac;
        }
        
        @media (max-width: 900px) {
            .container {
                flex-direction: column;
            }
            
            .canvas-container, .control-panel {
                min-width: 100%;
            }
        }
        
        canvas {
            display: block;
        }
        
        .formula::before {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 4px;
            background: linear-gradient(to right, #3a4fac, #5a6ff0);
        }
        
        .coords {
            display: flex;
            justify-content: space-between;
            margin-top: 15px;
            font-size: 0.95rem;
            color: #5a6ad0;
        }
        
        .coord-box {
            background: #f5f7ff;
            padding: 8px 12px;
            border-radius: 6px;
            border: 1px solid #e0e7ff;
            font-family: monospace;
        }
        
        .status {
            margin-top: 15px;
            padding: 12px;
            background: #f5f7ff;
            border-radius: 8px;
            border: 1px solid #e0e7ff;
            text-align: center;
            font-weight: 500;
            color: #3a4fac;
        }
        
        .vertex-highlight {
            position: absolute;
            width: 24px;
            height: 24px;
            border-radius: 50%;
            background-color: rgba(211, 47, 47, 0.3);
            pointer-events: none;
            transform: translate(-50%, -50%);
            z-index: 10;
            display: none;
        }
