
body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    margin: 20px;
    color: #333;
    background-color: #f9f9f9;
    counter-reset: formulaCounter;
}
header, section, footer {
    margin-bottom: 20px;
    padding: 20px;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border-radius: 8px;
}
header {
    text-align: center;
    background-color: #4CAF50;
    color: white;
    border-radius: 8px 8px 0 0;
}
header h1 {
    margin: 0;
    padding: 20px 0;
    font-size: 2em;
}
header p {
    margin: 0;
    font-size: 1em;
}
section h2 {
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 5px;
    font-size: 1.75em;
    color: #4CAF50;
}
section h3 {
    border-bottom: 1px solid #ccc;
    padding-bottom: 5px;
    font-size: 1.5em;
    color: #555;
}
p, .math {
    margin: 10px 0;
}
.math {
    background: #f0f0f0;
    padding: 10px;
    border-radius: 5px;
}
footer h2 {
    font-size: 1.5em;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 5px;
    color: #4CAF50;
}
footer ul {
    list-style-type: none;
    padding-left: 0;
}
footer ul li {
    margin-bottom: 5px;
    font-size: 1em;
}
.highlight {
    background-color: #ffffcc;
    border-left: 5px solid #ffeb3b;
    padding: 10px;
    margin: 20px 0;
    border-radius: 5px;
}
.author-info {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
}
.author-info img {
    border-radius: 50%;
    width: 100px;
    height: 100px;
}

.input-section {
    margin-top: 20px;
}
.input-section input {
    padding: 10px;
    font-size: 16px;
    width: 200px;
}
.input-section button {
    padding: 10px;
    font-size: 16px;
    cursor: pointer;
}
.result {
    margin-top: 20px;
    padding: 10px;
    background-color: #e9e9e9;
    border-radius: 5px;
}

/* Style for the formula class */
.formula {
    display: block;
    text-align: center;                 
    margin: 10px 0 0 0;          
    font-style: italic;             
  }
  
  /* === Paper-specific Layout Enhancements === */
.container {
    max-width: 1000px;
    margin: 60px auto;
    padding: 40px 60px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 0 12px rgba(0,0,0,0.05);
}

/* === Headings Consistent with Existing Styles === */
h1 {
    font-size: 2.2em;
    text-align: center;
    margin-top: 1.5em;
    margin-bottom: 0.6em;
    color: #222;
}
h2, h3, h4 {
    margin-top: 1.5em;
    margin-bottom: 0.6em;
}
h2 {
    font-size: 1.6em;
    border-bottom: 1px solid #ddd;
    padding-bottom: 0.2em;
}

.subtitle {
    font-size: 1.6em;
    border-bottom: 0px solid #ddd;
    padding-bottom: 0.2em;
}

h3 {
    font-size: 1.3em;
    color: #444;
}
h4 {
    font-weight: normal;
    text-align: left;
    margin-left: 0 em;
    color: #555;
}

/* === Typography Enhancements === */
p {
    line-height: 1.7;
    margin-bottom: 1em;
}
ul {
    margin-left: 1.5em;
    line-height: 1.6;
}

/* === Input Section Styling (Refined) === */
.input-section input {
    padding: 8px;
    font-size: 1em;
    margin: 0.4em 0.6em 0.4em 0;
    width: 180px;
    border: 1px solid #ccc;
    border-radius: 6px;
}
.input-section button {
    padding: 8px 14px;
    background-color: #808080;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}
.input-section button:hover {
    background-color: #707070;
}

/* === Result Output Styling === */
.result {
    margin-top: 10px;
    background: #eef2f5;
    padding: 10px 15px;
    border-radius: 6px;
    border-left: 4px solid #808080;
    white-space: pre-wrap;
    font-family: monospace;
}

.formula {
    position: relative;
    text-align: center;
    margin: 16px 0;
    padding: 8px 40px 8px 12px;
    background: #f0f0f0;
    border-left: 4px solid #aaa;
    font-style: italic;
    font-family: "Cambria Math", "STIX Math", serif;
}

/* Number at right end of paragraph */
.equation-number::before {
    counter-increment: formulaCounter;
    content: "(" counter(formulaCounter) ")";
    position: absolute;
    right: 12px;
    font-style: normal;
    font-weight: normal;
    color: #666;
    top: 50%;
    transform: translateY(-50%);
}



