title: How to make p tag fill grid cells it's occupying?
body: <p>This is my first time ever using grid layout, and I'm having trouble having my p tags fill the content of the cell they occupy. So, I do <strong>not</strong> need help <strong>making the grid</strong>. I need help <strong>expanding the text</strong> of the p tag <strong>to fill the cell</strong> of which the p tag occupies.</p>
  <p>Here is the code: <strong>NOTE: The first half consists of Andy Bell's Modern CSS Reset. I modified only parts of it which would've been overwritten later.</strong></p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>*, *::before, *::after {
    box-sizing: border-box;
  }
  
  body, p {
    margin: 0;
  }
  
  html:focus-within {
    scroll-behavior: smooth;
  }
  
  html::-webkit-scrollbar {
    display: none;
  }
  
  html, body {
    width: 100%;
    height: 100%;
  }
  
  body {
    font-size: 1rem;
    height: 100%;
    overflow: hidden;
    min-height: 100vh;
    text-rendering: optimizeSpeed;
    line-height: 1;
  }
  
  a:not([class]) {
    text-decoration-skip-ink: auto;
  }
  
  img,
  picture {
    max-width: 100%;
    display: block;
  }
  
  @media (prefers-reduced-motion: reduce) {
    html:focus-within {
     scroll-behavior: auto;
    }
    
    *,
    *::before,
    *::after {
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
      scroll-behavior: auto !important;
    }
  }
  
  .container {
    width: 100%;
    height: 100%;
  }
  
  .typography-grid {
    width: 100%;
    height: 100%;
    display: grid;
    grid-auto-columns: 1fr;
    grid-auto-rows: 1fr;
    grid-template-areas: 
        'text-section-one text-section-one . . . . .'
        '. . image image image . .'
        'small-text . . . . text-section-two text-section-two';
  }
  
  img {
    grid-area: image;
    aspect-ratio: 1;
    width: 65%;
    margin: 0 auto;
    z-index: 1;
  
    box-shadow: 0px 0px 10px 0px black;
  }
  
  /* p {
    width: 100%;
    font-size: 2rem;
    font-size: 5vw;
  } */
  
  .text--small {
    font-style: italic;
    width: 80%;
    text-align: left;
    grid-area: small-text;
  }
  
  #large1 {
    grid-area: text-section-one;
  }
  
  #large2 {
    letter-spacing: 1rem;
    grid-column: 2 / 7;
    grid-row: 2;
  }
  
  #large3 {
    grid-area: text-section-two;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;!DOCTYPE html&gt;
  &lt;html&gt;
    &lt;head&gt;
      &lt;!-- 
      &lt;script&gt;
        textFit(document.querySelector("p"), 0.5);
        fitText(document.querySelector("p"), 0.5);
        fitty('p');
      &lt;/script&gt;
     --&gt;
    &lt;/head&gt;
    &lt;body&gt;
      &lt;div class="container"&gt;
          &lt;div class="typography-grid"&gt;
              &lt;p class="text text--large" id="large1"&gt;TEXT&lt;/p&gt;
              &lt;p class="text text--large" id="large2"&gt;TEXT&lt;/p&gt;
              &lt;img src="https://andyspizzaandsubs.com/wp-content/uploads/2018/11/blog-ph.jpg" alt="sample image"&gt;
              &lt;p class="text text--small"&gt;SAMPLE TEXT SAMPLE TEXT SAMPLE TEXT SAMPLE TEXT SAMPLE TEXT SAMPLE TEXT SAMPLE TEXT SAMPLE TEXT&lt;/p&gt;
              &lt;p class="text text--large" id="large3"&gt;TEXT&lt;/p&gt;
          &lt;/div&gt;
      &lt;/div&gt;
  &lt;/body&gt;
  &lt;/html&gt;</code></pre>
  </div>
  </div>
  </p>
  <p>I've tried the items commented out under the p tag selector, but there doesn't seem to be a perfect magic number where everything <em>doesn't</em> get pushed out of frame. I've also tried <code>width: fit-content;</code> to see if that would change anything, but nothing did.</p>
  <p>Last thing I tried was following this previous SO post: <a href="https://stackoverflow.com/questions/16056591/font-scaling-based-on-width-of-container">Font scaling based on width of container</a>
  I used script tags in the head of my HTML (which didn't work), and the relative units didn't work for reasons mentioned before.</p>
  <p>Is this possible? I'm aiming for a large-typography-style website, so I need the p tags to fill the grid cells they occupy, or sort of stretch to fill the cells they occupy. Is there a workaround? Any help is appreciated! Thank you.</p>