/* Main Container */
.worksheet-34-container {
    width: 100%;
    margin: 0 auto;
    font-family: 'Noto Sans KR', sans-serif;
}

/* Legend Area (Top Row) */
.legend-container {
    display: flex;
    justify-content: space-between;
    padding: 15px 10px;
    border : 1px solid #ccc;
	border-radius:20px;
    margin-bottom: 10px;
	margin-top:-20px;
    background-color: #fff;
}

.legend-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 10%;
}

.legend-shape {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.legend-number {
    font-size: 24px;
    font-weight: 800;
    margin-top: 5px;
    color: #000;
}

/* Problem Area */
.problem-row {
    display: flex;
    align-items: center;
    margin-bottom: 0px;
    padding: 3px;
    border-bottom: 1px dashed #eee;
   gap: 0 30px;
}

.problem-equation {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 2;
    font-size: 30px;
    font-weight: bold;
    color: #333;
    min-width: 350px;
}

.equation-shape-box {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.equation-symbol {
    font-size: 30px;
    color: #333;
    margin: 0 5px;
}

/* Answer Input Area */
.answer-box-container {
    flex: 1;
    display: flex;
    justify-content: flex-end;
}

.calc-answer-box {
    width: 250px;
    height: 50px;
    border: 2px solid #6d9ed3;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    color: #000;
    border-radius: 5px;
}

/* Example Box Style */
.example-box {
    background-color: #f9f9f9;
}

/* Print Optimization */
@media print {
    .legend-container {
        border-bottom: 2px solid #000;
    }
}


/* Item 50: Make-10 Subtraction Tree (Kid-Friendly Design) */
.w34-item50-wrapper {
    display: inline-block;
    width: 30%;
    margin: 0px 0.5%;
    vertical-align: top;
    box-sizing: border-box;
}

.w50-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 5px 5px;
    background-color: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 20px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s;
}

/* Example card specific styling */
.w50-card.examplex {
    background-color: #fffbe6;
    /* Light yellow for example */
    border-color: #ffe58f;
 
}

.w50-example-label {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: #ffec3d;
    color: #d46b08;
    font-weight: 800;
    padding: 2px 12px;
    font-size: 14px;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.w50-row {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 10px 0;
    gap: 8px;
}

.w50-box {
    width: 42px;
    height: 42px;
    border: 2px solid #69c0ff;
    /* Soft blue border */
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 800;
    background: #fff;
    color: #0050b3;
    /* Darker blue text */
    font-family: 'Jua', 'Gamja Flower', 'Noto Sans KR', sans-serif;
    /* Playful font try */
}

/* Input box style (results) */
.w50-box:empty {
    background-color: #fafafa;
    border: 2px dashed #d9d9d9;
}

.w50-box.noborder {
    border: none;
    width: auto;
    font-size: 26px;
    color: #8c8c8c;
    background: transparent;
}

.w50-split-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 5px 0;
}

.w50-split-arrows {
    width: 70px;
    height: 35px;
    margin-bottom: 2px;
    /* Arrows color controlled via PHP or filter here */
}

.w50-split-boxes {
    display: flex;
    gap: 15px;
}

.w50-small-box {
    width: 36px;
    height: 36px;
    border: 2px solid #95de64;
    /* Soft green */
    border-radius: 50%;
    /* Circle for split numbers to look cute */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 800;
    background: #fff;
    color: #237804;
}

.w50-eq-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 8px;
    font-size: 18px;
    font-weight: bold;
    color: #595959;
}

.w50-eq-box {
    width: 34px;
    height: 34px;
    border: 2px solid #ffa749;
    /* Soft amber */
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    background: #fff;
    color: #d48806;
}

/* Colors for answers */
.text-red {
    color: #ff4d4f;
}

.text-green {
    color: #52c41a;
}

/* Item 51: Number House (Make Sum) */
.w34-item51-wrapper {
    display: inline-block;
    width: 21%;
    margin: -5px 1%;
    vertical-align: top;
    box-sizing: border-box;
}

.w51-house {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.w51-roof {
    width: 100%;
    height: 60px;
    position: relative;
    z-index: 1;
    margin-bottom: -2px;
    /* Pull body up to connect */
}

.w51-roof svg {
    width: 100%;
    height: 100%;
    display: block;
    overflow: visible;
}

.w51-roof-text {
    position: absolute;
    top: 60%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 30px;
    font-weight: 800;
    color: #1890ff;
    /* Blue text as per user ref image 1 typically has color */
    /* text-shadow: 1px 1px 0 #fff; */
    z-index: 2;
}

.w51-body {
    width: 80%;
    /* Width of the house body, narrower than roof eaves */
    border: 3px solid #1890ff;
    /* Blue border */
    border-top: none;
    background: #fff;
    display: flex;
    flex-direction: column;
}

.w51-row {
    display: flex;
    border-bottom: 2px solid #1890ff;
    height: 30px;
}

.w51-row:last-child {
    border-bottom: none;
}

.w51-cell {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 2px solid #1890ff;
    font-size: 20px;
    font-weight: bold;
    color: #333;
}

.w51-cell:last-child {
    border-right: none;
}

.w51-input {
    color: #333;
}

.w51-input.answer {
    color: #ff4d4f;
    /* Red for answers */
}