/* =====================
   GLOBAL STYLES
===================== */

body {
  font-family: "Play", sans-serif;
  background-image: linear-gradient(to bottom, #2c3e50, #bdc3c7),
    url("./Backgrounds.avif");
  background-size: cover;
  background-attachment: fixed;
  background-repeat: no-repeat;
  margin: 0;
  padding: 0;
}

header {
  background-color: rgb(132, 113, 90);
  color: #fff;
  padding: 10px 0;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1800px;
  margin: 0 auto;
  padding: 0 20px;
  font-size: 1.2rem;
}

nav ul {
  list-style: none;
}

nav ul li {
  display: inline;
  margin-right: 20px;
}

nav ul li:last-child {
  margin-right: 0;
}

nav a {
  text-decoration: none;
  color: #fff;
  font-weight: bold;
}

a {
  color: #0078e7;
}

a:hover {
  text-decoration: underline;
}

/* =====================
   HEADINGS
===================== */

h1, h2, h4 {
  font-family: "Play", sans-serif;
  text-align: center;
}

h1 {
  font-size: 2rem;
}

h2 {
  color: red;
  font-size: 1.7rem;
}

h4 {
  font-size: 1.5rem;
}

/* =====================
   CONTENT BOX
===================== */

.explain {
  background-color: white;
  border-radius: 10px;
  padding: 20px;
  margin-top: 20px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  font-size: 1.2rem;
}

/* =====================
   TABLE BASE
===================== */

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}

th,
td {
  font-size: 1.2rem;
  padding: 10px;
  text-align: center;
  border: 1px solid #000;
}

th {
  background-color: #fff700;
}

/* =====================
   CALCULATION TABLE (MAIN)
===================== */

.calcul-table-new {
  margin-top: 40px;
  padding: 20px;
  background-color: #ffffff;
  border-radius: 10px;
}

.calcul-table-new table {
  width: 90%;
  max-width: 1100px;
  margin: 0 auto;
  font-size: 0.95rem;
  border: 1px solid #444;
}

.calcul-table-new th,
.calcul-table-new td {
  padding: 8px;
  border: 1px solid #444;
  text-align: center;
}

.calcul-table-new thead th {
  background-color: #fff700;
  font-size: 1rem;
  font-weight: 600;
}

.calcul-table-new tbody td {
  background-color: #ffffff;
  font-size: 1rem;
  font-weight: 600;
}

/* =====================
   INPUTS – BASE
===================== */

.calcul-table-new input {
  box-sizing: border-box;
  padding: 2px 4px;
  font-size: 0.9rem;
}

/* =====================
   INPUTS – COLUMN SIZES
===================== */

/* Number (row index) */
.calcul-table-new input.Number {
  width: 40px;
  text-align: center;
}

/* Company name */
.calcul-table-new input.company {
  width: 160px;
  text-align: left;
}

/* Price */
.calcul-table-new input.price {
  width: 90px;
  text-align: right;
}

/* Compact numeric fields */
.calcul-table-new input.pe,
.calcul-table-new input.g,
.calcul-table-new input.r {
  width: 65px;
  text-align: right;
}

/* =====================
   RESULT CELLS
===================== */

.calcul-table-new span {
  min-width: 45px;
  display: inline-block;
  font-size: 0.9rem;
  font-weight: bold;
}

/* =====================
   LOSS / EPS ≤ 0 TABLE
===================== */

.calcul-table-loss-sirripa {
  margin-top: 30px;
  padding: 10px;
  background-color: #fff;
  border-radius: 10px;
}

.calcul-table-loss-sirripa table {
  width: 95%;
  max-width: 1300px;
  margin: 0 auto;
  font-size: 0.9rem;
  border: 1px solid #444;
}

.calcul-table-loss-sirripa th,
.calcul-table-loss-sirripa td {
  border: 1px solid #444;
  padding: 6px 8px;
  text-align: center;
}

.calcul-table-loss-sirripa thead th {
  background-color: #fff700;
  font-size: 0.95rem;
  font-weight: bold;
}

.calcul-table-loss-sirripa tbody td {
  background-color: #fff;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Loss table inputs */
.calcul-table-loss-sirripa input {
  box-sizing: border-box;
  padding: 3px;
  font-size: 0.85rem;
}

.calcul-table-loss-sirripa input[type="text"] {
  width: 120px;
  text-align: left;
}

.calcul-table-loss-sirripa input[type="number"] {
  width: 65px;
  text-align: right;
}

.calcul-table-loss-sirripa span {
  font-weight: bold;
  font-size: 0.9rem;
  display: inline-block;
  min-width: 55px;
}
